Client
View as MarkdownThis page lists the Python SDK names for the Client. The doc comment of each API gives its parameters, defaults, and errors. Read them in the Python SDK API reference.
API names
| Task | Python API | Dex behavior |
|---|---|---|
| Create a Client | Client for blocking calls, or AsyncClient for asyncio, with ClientOptions | Client requests |
| Start a Flow | start_flow, with StartFlowOptions | Start a Flow |
| Invoke an RPC | invoke_rpc | Invoke an RPC |
| Read Attributes | get_attributes | Read Attributes |
| Wait for a Flow to close | wait_for_flow | Wait for a Flow |
| Wait for a Step execution to complete | wait_for_step_completion, with WaitForStepCompletionOptions | Wait for a Step |
| Wait until an Attribute matches | wait_for_attribute_match, with WaitForAttributeOptions | Wait for an Attribute match |
| Describe a Flow | describe_flow | Describe a Flow |
| Search Flows | search_flows | Search Flows |
| Stop a Flow | stop_flow, with StopFlowOptions | Stop a Flow |
| Skip a Timer | skip_timer | Skip a Timer |
| Update FlowConfig | update_flow_config | Update FlowConfig |
| Write and read a Stream | write_stream, read_stream, and list_stream_messages | Stream |
| Time travel a Flow | time_travel, with TimeTravelOptions | Time travel |
| Upload Flow definitions | upload_flow_definitions, with FlowDefinitionDocument. Since 1.45 | Flow definitions |
| Handle a failed request | DexServiceError, with ErrorSubStatus | Client requests |
AsyncClient has the same methods as Client. Each one is a coroutine.
Example
Example: examples/python/dex_examples/primitives/client-apis/controller.py