For AI agents: the complete documentation index is available at https://docs.dataplatform.ovh.net/llms.txt, the full documentation bundle is available at https://docs.dataplatform.ovh.net/llms-full.txt, and this page is available as Markdown at https://docs.dataplatform.ovh.net/landing-page-developers-python-sdk.md.
  • 🇬🇧 English
  • Custom Actions SDK

    Read and write project data from the code that runs inside it.

    What the SDK is for

    The Custom Actions SDK is the Python library used to interact with a project from inside the project's own compute. It is available in Custom actions, Custom PySpark actions and the integrated Jupyter notebooks, so code can be written and tested in a notebook and then pasted into an action unchanged. Where a function is not available in one of those contexts, its own page says so.

    Quick starts

    Four short walkthroughs, one per target: read a dataset, read a bucket, read a registered source, and the PySpark variants of the same reads. Each is a complete action you can paste in and run, and the natural first stop if you have not used the SDK before.

    Connect to project data

    Its entry point is connect(), which takes a connection string and returns a connector for whatever that string names: a dataset, a table, a bucket, or a registered source. The object returned differs by target, which is why the connector guides cover each one separately. bulk_insert() is the counterpart for writing, taking a pandas dataframe into a destination table in batches.

    PySpark is handled through Spark-compatible methods on the same connector object, so a PySpark action reads tables as Spark dataframes rather than pandas ones. The SDK reference lists every signature.

    Advanced

    These guides cover what makes an action production-ready: environment variables instead of hardcoded values, segmentation so one action becomes parallel tasks, overriding a Load action, importing custom Python modules from Git, and emitting lineage events.

    Info

    Code samples still import from forepaas.*. Those module names are unchanged on the platform today, and the samples are updated when the SDK rename ships.

    Go further

    If you need training or technical assistance to implement our solutions, contact your sales representative or click on this link to get a quote and ask our Professional Services experts for a custom analysis of your project.

    Ask questions, give your feedback and interact directly with the team building the Data Platform on the dedicated Discord channel.

    If you need support with your OVHcloud services, create a request in our Help Centre.

    Join our community of users.