---
type: api
title: Get a workflow execution
description: **Spaces method and path for this operation:**
url: https://www.elastic.co/elastic/docs-builder/docs/4371/api/doc/kibana-serverless/operation/operation-get-workflows-executions-executionid
resource: https://www.elastic.co/elastic/docs-builder/docs/4371/api/doc/kibana-serverless/operation/operation-get-workflows-executions-executionid
products:
  - Kibana
---

# Get a workflow execution

Availability:

- Server: `https://{kibana_url}`

## Paths

- `GET` `/api/workflows/executions/{executionId}`
- `GET` `/s/{space_id}/api/workflows/executions/{executionId}`

- [Api key auth](/elastic/docs-builder/docs/4371/api/doc/kibana-serverless/authentication#apikeyauth)

#### Path Parameters

- `executionId` (string · max: 255)
  Workflow execution ID

## Description

Refer to [Spaces](https://www.elastic.co/docs/deploy-manage/manage-spaces) for more information.

Retrieve details of a single workflow execution by its ID.<br/><br/>[Required authorization] Route required privileges: workflowsManagement:read AND workflowsManagement:readExecution. Extended privileges (optional, expand functionality when granted): workflowsManagement:managed:readExecution.

## Query String Parameters

- `includeInput` (boolean · default: false)
  Include execution input data.
- `includeOutput` (boolean · default: false)
  Include execution output data.
- `omitStepExecutions` (boolean · default: false)
  When `true`, omit the embedded `stepExecutions` array. Defaults to `false`. When this is `false`, the embed is capped at 5000 steps.

## Response

Indicates a successful response

## Code Examples

#### Console

```console
GET kbn://api/workflows/executions/{executionId}?includeInput=true&includeOutput=true
```

#### curl

```curl
curl \
  -X GET "${KIBANA_URL}/api/workflows/executions/{executionId}?includeInput=true&includeOutput=true" \
  -H "Authorization: ApiKey ${API_KEY}"
```

## Response Examples

#### Get execution response

Example response returning a workflow execution with step details

```json
{
  "duration": 3000,
  "executedBy": "elastic",
  "finishedAt": "2025-11-20T12:00:03.000Z",
  "id": "exec-a1b2c3d4-e5f6-7890",
  "input": {
    "message": "hello world"
  },
  "isTestRun": false,
  "output": "hello world",
  "spaceId": "default",
  "startedAt": "2025-11-20T12:00:00.000Z",
  "status": "completed",
  "stepExecutions": [
    {
      "executionTimeMs": 1000,
      "finishedAt": "2025-11-20T12:00:02.000Z",
      "globalExecutionIndex": 0,
      "id": "step-exec-001",
      "isTestRun": false,
      "scopeStack": [],
      "spaceId": "default",
      "startedAt": "2025-11-20T12:00:01.000Z",
      "status": "completed",
      "stepExecutionIndex": 0,
      "stepId": "hello_world_step",
      "stepType": "console",
      "topologicalIndex": 0,
      "workflowId": "workflow-a1b2c3d4-e5f6-7890-abcd-ef1234567890",
      "workflowRunId": "exec-a1b2c3d4-e5f6-7890"
    }
  ],
  "triggeredBy": "manual",
  "workflowDefinition": {
    "description": "This is a workflow example",
    "enabled": true,
    "inputs": [
      {
        "default": "hello world",
        "name": "message",
        "type": "string"
      }
    ],
    "name": "Example definition",
    "steps": [
      {
        "name": "hello_world_step",
        "type": "console",
        "with": {
          "message": "{{ inputs.message }}"
        }
      }
    ],
    "triggers": [
      {
        "type": "manual"
      }
    ]
  },
  "workflowId": "workflow-a1b2c3d4-e5f6-7890-abcd-ef1234567890",
  "yaml": "name: Example definition\nenabled: true\ndescription: This is a workflow example\ntriggers:\n  - type: manual\ninputs:\n  - name: message\n    type: string\n    default: \u0022hello world\u0022\nsteps:\n  - name: hello_world_step\n    type: console\n    with:\n      message: \u0022{{ inputs.message }}\u0022\n"
}
```

