v1

latestOpenAPI 3.1.02026-07-263644911022.4 KB
Workflows API

Create a Workflow

Use this endpoint to create a new workflow definition. New workflows are created in draft status.

post/v1/workflows

Request body

descriptionstring

Optional human-readable description of the workflow's purpose.

metadataobject

Custom key-value pairs for tagging or categorizing the workflow.

namestring required

Unique name for the workflow.

Example request

{
  "name": "Payment Notification Flow",
  "description": "Receives a webhook trigger and logs the payment event.",
  "nodes": [
    {
      "id": "trigger-1",
      "type": "trigger",
      "name": "Webhook Trigger",
      "position": {
        "x": 0,
        "y": 0
      },
      "data": {
        "triggerId": "webhook"
      }
    },
    {
      "id": "log-event",
      "type": "action",
      "name": "Log Payment Event",
      "position": {
        "x": 200,
        "y": 0
      },
      "data": {
        "action": "log"
      }
    }
  ],
  "edges": [
    {
      "id": "e1",
      "source": "trigger-1",
      "target": "log-event"
    }
  ],
  "metadata": {
    "team": "payments",
    "environment": "sandbox"
  }
}

Response

Indicates that the resource was successfully created and the operation was completed as expected.

createdAtstring date-time

Timestamp when the workflow was created.

statusstring

Initial status of the workflow (always draft on creation).

versionstring

Version of the workflow definition.

workflowIdstring uuid

Unique identifier of the created workflow.

Example response

{
  "createdAt": "2026-03-17T14:30:00Z",
  "status": "draft",
  "version": "1.0.0",
  "workflowId": "a1b2c3d4-e5f6-7890-abcd-ef1234567890"
}