orbitra.flows.client
Functions
get_flows_client
environment: The environment to get the API URL from. Defaults to “prod”.
- An authenticated OrbitraFlowsClient instance.
Classes
OrbitraFlowsClient
A wrapper around SyncPrefectClient for interacting with Orbitra Flows.
Methods:
api_url
run_deployment_by_name
deployment_name: The name of the deployment to run in the format <FLOW_NAME>/<DEPLOYMENT_NAME>.parameters: Parameters to pass to the flow run. Defaults to None.
- The ID of the created flow run.
sync_prefect_client
wait_for_flow_run
flow_run_id: The ID of the flow run to wait for.poll_interval: Seconds between polling attempts. Defaults to 5.0.timeout: Maximum seconds to wait before raising an error. Defaults to None (wait forever).raise_on_flow_failure: If True, raise FlowsError on flow failure. If False, return the FlowRun instead. Defaults to True.
- The completed flow run object.
FlowsError: If the flow run fails, crashes, or is cancelled (only when raise_on_flow_failure=True).