Workflows API
Workflow endpoints manage automation definitions and versioned step logic.
Common endpoints
Section titled “Common endpoints”GET /api/workflowslist workflows in the current organizationPOST /api/workflowscreate a workflowGET /api/workflows/{id}load workflow detailsPOST /api/workflows/{id}/savepersist script or step updatesPOST /api/workflows/uploadcreate from uploaded recording artifacts
Request design
Section titled “Request design”- Use JSON payloads with explicit field names.
- Keep workflow IDs UUID-based.
- Separate mutable metadata from executable step definitions.
Validation and safety
Section titled “Validation and safety”- Validate request bodies with Zod.
- Reject missing required fields with 400.
- Enforce organization ownership on all workflow reads/writes.
Example create request
Section titled “Example create request”{ "name": "Eligibility Check", "description": "Payer portal eligibility verification", "variables": ["member_id", "date_of_birth", "payer_name"]}Example save request
Section titled “Example save request”{ "script": "// generated or edited workflow script", "steps": [ { "id": "step_1", "type": "navigate", "url": "https://example-portal" }, { "id": "step_2", "type": "type", "field": "member_id" } ]}Related APIs
Section titled “Related APIs”- Jobs API for execution
- Agents API for runtime control
- Functions API for reusable helper methods