Skip to main content

Get run status

GET /projects/:projectid/workflows/:workflowid/run/:invocationId

Poll a queued run.

Returns the current state of a queued run. Once state is completed the workflow's result is included as output; if it is failed, failedReason explains why.

Authentication

  • Project API key: The credential for everything external. Created in Project Settings, bound to one project, and limited to the scopes it was granted. Format: proj.<keyId>.<secret>.
  • Required permission: workflows.read on :workflowid.

Path parameters

NameTypeRequiredDefaultDescription
projectidstringYes-The project id.
workflowidstringYes-The workflow that was run.
invocationIdstringYes-The id returned when the run was queued.

Example request

curl -X GET \
-H "Authorization: proj.KEY_ID.SECRET" \
{{BASE_URL}}/projects/{{PROJECT_ID}}/workflows/YOUR_WORKFLOW_ID/run/INVOCATION_ID

Responses

200

Still running.

{
"success": true,
"invocationId": "a3f9c1e28b74",
"projectId": "{{PROJECT_ID}}",
"workflowId": "wf_8fK2p",
"state": "active",
"statusCode": 200
}

200

Finished.

{
"success": true,
"invocationId": "a3f9c1e28b74",
"projectId": "{{PROJECT_ID}}",
"workflowId": "wf_8fK2p",
"state": "completed",
"statusCode": 200,
"output": {
"success": true,
"statusCode": 200,
"result": {
"outputs": {
"greeting": "Hello Ada"
}
}
}
}

404

No such invocation, or it belongs to a different workflow.

Notes

  • state is one of waiting, active, completed, failed, delayed or unknown.
  • Completed runs are retained briefly — read the result promptly rather than polling hours later.