Skip to content

Workflows API

Workflow endpoints manage automation definitions and versioned step logic.

Common endpoints

  • GET /api/workflows list workflows in the current organization
  • POST /api/workflows create a workflow
  • GET /api/workflows/{id} load workflow details
  • POST /api/workflows/{id}/save persist script or step updates
  • POST /api/workflows/upload create from uploaded recording artifacts

Request design

  • Use JSON payloads with explicit field names.
  • Keep workflow IDs UUID-based.
  • Separate mutable metadata from executable step definitions.

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

{
"name": "Eligibility Check",
"description": "Payer portal eligibility verification",
"variables": ["member_id", "date_of_birth", "payer_name"]
}

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" }
]
}
  • Jobs API for execution
  • Agents API for runtime control
  • Functions API for reusable helper methods