Skip to main content

Workflows

Create, manage, deploy, and execute automation workflows. Workflows are composed of interconnected nodes that define data processing pipelines.

All endpoints require authentication via X-API-Key header and the appropriate scope.


Workflow Object

{
"id": "wf_abc123",
"name": "Daily ETL Pipeline",
"description": "Extracts data from MySQL, transforms, and loads to S3",
"status": "active",
"version": 3,
"nodes": [
{
"id": "node_1",
"nodeId": "mysql-source",
"label": "Extract Orders",
"position": { "x": 100, "y": 200 },
"config": {}
}
],
"connections": [
{
"sourceNodeId": "node_1",
"sourcePort": "output",
"targetNodeId": "node_2",
"targetPort": "input"
}
],
"config": {},
"settings": {
"timeout": 3600,
"retryOnFailure": true,
"maxRetries": 3
},
"tags": ["etl", "production"],
"organizationId": "org_xyz",
"ownerId": "user_456",
"sharedWith": ["user_789"],
"isPublic": false,
"isTemplate": false,
"createdAt": "2025-01-15T10:30:00Z",
"updatedAt": "2025-02-01T14:22:00Z"
}

GET /api/v1/workflows

List all workflows accessible to the authenticated user.

Scope: workflows:read

Query Parameters

ParameterTypeRequiredDescription
statusstringNoFilter by status: draft, active, paused, archived
tagstringNoFilter by tag
searchstringNoSearch by name or description
limitintegerNoNumber of results to return (default: 20)
offsetintegerNoNumber of results to skip (default: 0)
sortstringNoSort field and direction, e.g. createdAt:desc

Response 200 OK

{
"count": 42,
"limit": 20,
"offset": 0,
"workflows": [
{
"id": "wf_abc123",
"name": "Daily ETL Pipeline",
"description": "Extracts data from MySQL, transforms, and loads to S3",
"status": "active",
"version": 3,
"tags": ["etl", "production"],
"organizationId": "org_xyz",
"ownerId": "user_456",
"isPublic": false,
"isTemplate": false,
"createdAt": "2025-01-15T10:30:00Z",
"updatedAt": "2025-02-01T14:22:00Z"
}
]
}

POST /api/v1/workflows

Create a new workflow.

Scope: workflows:write

Request Body

{
"name": "Daily ETL Pipeline",
"description": "Extracts data from MySQL, transforms, and loads to S3",
"status": "draft",
"nodes": [],
"connections": [],
"tags": ["etl"],
"settings": {
"timeout": 3600,
"retryOnFailure": true,
"maxRetries": 3
}
}
FieldTypeRequiredDescription
namestringYesWorkflow name
descriptionstringNoWorkflow description
statusstringNoInitial status (default: draft)
nodesarrayNoArray of node objects
connectionsarrayNoArray of connection objects
tagsarrayNoArray of tag strings
settingsobjectNoWorkflow settings (timeout, retry, etc.)

Response 201 Created

{
"workflowId": "wf_abc123"
}

GET /api/v1/workflows/:id

Get a single workflow by ID.

Scope: workflows:read

Path Parameters

ParameterTypeRequiredDescription
idstringYesWorkflow ID

Response 200 OK

Returns the full Workflow object.


PUT /api/v1/workflows/:id

Update an existing workflow.

Scope: workflows:write

Path Parameters

ParameterTypeRequiredDescription
idstringYesWorkflow ID

Request Body

{
"name": "Updated ETL Pipeline",
"description": "Updated description",
"nodes": [],
"connections": [],
"tags": ["etl", "v2"],
"settings": {
"timeout": 7200
}
}
FieldTypeRequiredDescription
namestringNoWorkflow name
descriptionstringNoWorkflow description
nodesarrayNoArray of node objects
connectionsarrayNoArray of connection objects
tagsarrayNoArray of tag strings
settingsobjectNoWorkflow settings

Response 200 OK

Returns the updated Workflow object.


DELETE /api/v1/workflows/:id

Delete a workflow. This action is irreversible.

Scope: workflows:write

Path Parameters

ParameterTypeRequiredDescription
idstringYesWorkflow ID

Response 204 No Content


POST /api/v1/workflows/:id/duplicate

Duplicate an existing workflow. Creates a copy with a new ID and draft status.

Scope: workflows:write

Path Parameters

ParameterTypeRequiredDescription
idstringYesWorkflow ID to duplicate

Response 201 Created

{
"workflowId": "wf_def456"
}

POST /api/v1/workflows/:id/execute

Execute a workflow. Submits the workflow for execution and returns an execution ID.

Scope: workflows:execute

Path Parameters

ParameterTypeRequiredDescription
idstringYesWorkflow ID

Request Body

{
"definition": {
"nodes": [],
"connections": []
},
"triggerInputs": {
"key": "value"
}
}
FieldTypeRequiredDescription
definitionobjectNoOverride workflow definition for this execution
triggerInputsobjectNoInput data to pass to the trigger node

Response 201 Created

{
"executionId": "exec_xyz789"
}

POST /api/v1/workflows/:id/deploy

Deploy a workflow. Provisions the required infrastructure and makes the workflow ready for execution.

Scope: workflows:write

Path Parameters

ParameterTypeRequiredDescription
idstringYesWorkflow ID

Response 200 OK

{
"message": "Workflow deployed successfully",
"workflowId": "wf_abc123",
"status": "active"
}

POST /api/v1/workflows/:id/undeploy

Undeploy a workflow. Tears down the provisioned infrastructure.

Scope: workflows:write

Path Parameters

ParameterTypeRequiredDescription
idstringYesWorkflow ID

Response 200 OK

{
"message": "Workflow undeployed successfully",
"workflowId": "wf_abc123",
"status": "draft"
}

PUT /api/v1/workflows/:id/status

Update the status of a workflow.

Scope: workflows:write

Path Parameters

ParameterTypeRequiredDescription
idstringYesWorkflow ID

Request Body

{
"status": "active"
}
FieldTypeRequiredDescription
statusstringYesNew status. Must be one of: draft, active, paused, archived

Response 200 OK

Returns the updated Workflow object.


GET /api/v1/workflows/:id/versions

List all versions of a workflow.

Scope: workflows:read

Path Parameters

ParameterTypeRequiredDescription
idstringYesWorkflow ID

Response 200 OK

{
"workflowId": "wf_abc123",
"currentVersion": 3,
"versions": [
{
"version": 1,
"versionTag": "v1.0.0",
"description": "Initial version",
"createdBy": "user_456",
"createdAt": "2025-01-15T10:30:00Z"
},
{
"version": 2,
"versionTag": "v1.1.0",
"description": "Added error handling",
"createdBy": "user_456",
"createdAt": "2025-01-20T08:15:00Z"
},
{
"version": 3,
"versionTag": "v2.0.0",
"description": "Refactored pipeline",
"createdBy": "user_456",
"createdAt": "2025-02-01T14:22:00Z"
}
]
}

POST /api/v1/workflows/:id/versions

Create a new version snapshot of the workflow.

Scope: workflows:write

Path Parameters

ParameterTypeRequiredDescription
idstringYesWorkflow ID

Request Body

{
"versionTag": "v2.1.0",
"description": "Added retry logic to S3 upload node"
}
FieldTypeRequiredDescription
versionTagstringYesVersion tag label
descriptionstringNoDescription of changes in this version

Response 201 Created

{
"workflowId": "wf_abc123",
"version": 4,
"versionTag": "v2.1.0"
}

GET /api/v1/workflows/:id/share

List users the workflow is shared with.

Scope: workflows:read

Path Parameters

ParameterTypeRequiredDescription
idstringYesWorkflow ID

Response 200 OK

{
"workflowId": "wf_abc123",
"sharedWith": [
{
"userId": "user_789",
"sharedAt": "2025-01-18T12:00:00Z"
}
]
}

POST /api/v1/workflows/:id/share

Share a workflow with another user in the organization.

Scope: workflows:write

Path Parameters

ParameterTypeRequiredDescription
idstringYesWorkflow ID

Request Body

{
"userId": "user_789"
}
FieldTypeRequiredDescription
userIdstringYesID of the user to share with

Response 200 OK

{
"message": "Workflow shared successfully",
"workflowId": "wf_abc123",
"userId": "user_789"
}

DELETE /api/v1/workflows/:id/share/:userId

Remove sharing access for a user.

Scope: workflows:write

Path Parameters

ParameterTypeRequiredDescription
idstringYesWorkflow ID
userIdstringYesUser ID to remove

Response 204 No Content


GET /api/v1/workflows/templates

List available workflow templates.

Scope: workflows:read

Response 200 OK

{
"count": 5,
"templates": [
{
"id": "wf_tmpl_001",
"name": "Basic ETL Pipeline",
"description": "A starter template for extract-transform-load workflows",
"tags": ["etl", "starter"],
"nodes": [],
"connections": [],
"createdAt": "2025-01-01T00:00:00Z"
}
]
}

GET /api/v1/workflows/stats

Get aggregate statistics for workflows in the organization.

Scope: workflows:read

Response 200 OK

{
"total": 42,
"active": 18,
"paused": 5,
"draft": 15,
"archived": 4
}