Skip to main content
POST
/
api
/
workflows
/
{id}
/
execute
Manually execute a workflow
curl --request POST \
  --url https://your-instance.example.com/api/workflows/{id}/execute \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '
{
  "contactId": "64b2c3d4e5f60012345678aa",
  "conversationId": "64d2f9c5e8a1d4e001a0b1c2"
}
'
{
  "success": true,
  "message": "Workflow execution queued",
  "queued": true
}

Authorizations

Authorization
string
header
required

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

Path Parameters

id
string
required

Body

application/json

Optional scoping for a manual run. Forwarded to the queued job as trigger.contactId / trigger.conversationId so workflow nodes can reference an existing contact/conversation.

contactId
string

Optional Contact _id to bind the run to — workflow nodes can read this from the trigger context.

conversationId
string

Optional Conversation _id to bind the run to — workflow nodes can read this from the trigger context.

Response

Workflow execution queued (runs asynchronously on the workflow-runner service)

Returned by POST /api/workflows/{id}/execute. The handler enqueues a BullMQ job; actual execution happens asynchronously on the workflow-runner service. Inspect the WorkflowExecution collection by workflowId to follow the run.

success
enum<boolean>
required
Available options:
true
message
string
required
queued
enum<boolean>
required
Available options:
true