GET
/
v1
/
workflow-runs
/
{run_id}
curl "https://agents-api.prod.dng.ai/api/v1/workflow-runs/$WORKFLOW_RUN_ID" \
          --header "x-api-key: $YOUR_API_KEY" \
          --header "content-Type: application/json"
{
  "success": true,
  "data": {
    "run_id": "0cf35172-859e-4b26-8ce9-6c2588a77b40",
    "workflow_id": "ab44401b-6947-46bc-8248-47aa2dacf856",
    "inputs": {
      "Text_0": {
        "value": "Hello world",
        "type": "text"
      }
    },
    "state": "DONE",
    "error": null,
    "started_at": "2025-02-17T13:33:45.575000",
    "ended_at": "2025-02-17T13:36:17.194000",
    "completed_steps": [
      {
        "step_id": "ee7d2258-8ff5-4176-8498-110f8dc8d264",
        "node_id": "LLM_0",
        "state": "DONE",
        "downloadable_output": true,
        "output": "Example output",
        "started_at": "2025-02-17T13:33:45.575000",
        "ended_at": "2025-02-17T13:34:17.194000"
      },
      {
        "step_id": "d5c913ab-0970-49f3-955a-eee4b2447276",
        "node_id": "LLM_1",
        "state": "DONE",
        "downloadable_output": false,
        "output":null,
        "started_at": "2025-02-17T13:35:45.575000",
        "ended_at": "2025-02-17T13:36:17.194000"
      }
    ],
    "failed_steps": []
  }
}

The Workflow Runs API allows you to get the details of a run.

Headers

x-api-key
string
required

Your unique API key for authentication.

This key is required in the header of all API requests, to authenticate your account and access Draft & Goal’s services. Get your API key from the Draft & Goal Dashboard.

Path Parameters

run_id
string
required

The ID of the workflow run you want to get.

Query Parameters

all_completed_steps
boolean
default:"false"

Whether to include all completed steps in the response.

Default is false.

During the workflow run

If the workflow run is still running, you will receive a 250 HTTP status code. Please wait a few minutes and poll the endpoint again.

Response

success
boolean
required

Whether the workflow run was successful.

data
object
required

The data returned by the workflow run.

{
  "success": true,
  "data": {
    "run_id": "0cf35172-859e-4b26-8ce9-6c2588a77b40",
    "workflow_id": "ab44401b-6947-46bc-8248-47aa2dacf856",
    "inputs": {
      "Text_0": {
        "value": "Hello world",
        "type": "text"
      }
    },
    "state": "DONE",
    "error": null,
    "started_at": "2025-02-17T13:33:45.575000",
    "ended_at": "2025-02-17T13:36:17.194000",
    "completed_steps": [
      {
        "step_id": "ee7d2258-8ff5-4176-8498-110f8dc8d264",
        "node_id": "LLM_0",
        "state": "DONE",
        "downloadable_output": true,
        "output": "Example output",
        "started_at": "2025-02-17T13:33:45.575000",
        "ended_at": "2025-02-17T13:34:17.194000"
      },
      {
        "step_id": "d5c913ab-0970-49f3-955a-eee4b2447276",
        "node_id": "LLM_1",
        "state": "DONE",
        "downloadable_output": false,
        "output":null,
        "started_at": "2025-02-17T13:35:45.575000",
        "ended_at": "2025-02-17T13:36:17.194000"
      }
    ],
    "failed_steps": []
  }
}
curl "https://agents-api.prod.dng.ai/api/v1/workflow-runs/$WORKFLOW_RUN_ID" \
          --header "x-api-key: $YOUR_API_KEY" \
          --header "content-Type: application/json"