> ## Documentation Index
> Fetch the complete documentation index at: https://velt.dev/docs/llms.txt
> Use this file to discover all available pages before exploring further.

# Get Execution

Use this API to fetch a workflow execution. Returns an `ExecutionView` with the current state plus the view-model of every step.

# Endpoint

`POST https://api.velt.dev/v2/workflow/executions/get`

# Headers

**x-velt-api-key** `string` *required*

Your API key.

**x-velt-auth-token** `string` *required*

Your [Auth Token](https://velt.dev/docs/security/auth-tokens.md).

# Body

#### Params

**data** `object` *required*

**properties**

**executionId** `string` *required*

The execution to fetch.

## **Example Requests**

#### Get an execution

```JSON theme={null}
{
  "data": {
    "executionId": "exec_1777374504255_xzy43k9q"
  }
}
```

# Response

#### Success Response

```JSON theme={null}
{
  "result": {
    "executionId": "exec_1777374504255_xzy43k9q",
    "status": "completed",
    "startedAt": 1777374504364,
    "completedAt": 1777374842347,
    "cancelledAt": null,
    "definitionId": "marketing-copy-approval",
    "definitionVersion": 1,
    "correlationId": "corr_campaign_42",
    "idempotencyKey": "campaign-42-dispatch",
    "documentId": "campaign-42-landing-page",
    "organizationId": "acme-marketing",
    "failureReason": null,
    "steps": [
      {
        "stepId": "group_parallel-review__to__agent-publish",
        "nodeId": "agent-publish",
        "nodeType": "agent",
        "status": "completed",
        "groupId": null,
        "startedAt": 1777374841756,
        "completedAt": 1777374841986,
        "output": {
          "agentId": "publish-agent-v1",
          "summary": "...",
          "generatedAt": 1777374841939
        },
        "error": null
      }
    ]
  }
}
```

`documentId` and `organizationId` are the ids passed to [Dispatch Execution](https://velt.dev/docs/api-reference/rest-apis/v2/approval-engine/executions/dispatch-execution.md). Both are optional: each key is omitted when the execution was dispatched without it.

#### Failure Response

```JSON theme={null}
{
  "error": {
    "message": "ERROR_MESSAGE",
    "status": "NOT_FOUND"
  }
}
```

**Errors:** `NOT_FOUND` / `INVALID_ARGUMENT`.

```js theme={null}
{
  "result": {
    "executionId": "exec_1777374504255_xzy43k9q",
    "status": "completed",
    "startedAt": 1777374504364,
    "completedAt": 1777374842347,
    "cancelledAt": null,
    "definitionId": "marketing-copy-approval",
    "definitionVersion": 1,
    "correlationId": "corr_campaign_42",
    "idempotencyKey": "campaign-42-dispatch",
    "documentId": "campaign-42-landing-page",
    "organizationId": "acme-marketing",
    "failureReason": null,
    "steps": []
  }
}
```


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.