# Workflow Execution Steps API

**Description:** Retrieves details about each step executed in a specific workflow run. A step is defined as a node within the workflow. A run is a single execution of a workflow.

### **Request Syntax:**

```
GET workflows/{workflow_id}/runs/{run_id}/steps
Authentication: Bearer <Your API key>
```

{% hint style="info" %}
You can get the {run\_id} of an executed workflow from the output of an Execute Workflow API call.&#x20;
{% endhint %}

### **Response Syntax:**

```
[
    {
        "id": "",
        "user_id": "",
        "organization_id": "",
        "node_id": "",
        "status": "",
        "start_time": "",
        "end_time": "",
        "elapsed_time": int,
        "error": "",
        "outputs": { ... },
        "inputs": { ... },
        "step_metadata": null,
        "tokens": 0
    },
    { ... }
]
```

<details>

<summary>Execution Steps Response Example</summary>

This example includes the output for a workflow which took in a prompt, generated a response with a model node and then emailed the response.

```
[
    {
        "id": "b2acc986-af06-418a-bf71-c730d5ghaf0b",
        "user_id": "2*****************1",
        "organization_id": "2*****************7",
        "node_id": "model",
        "status": "completed",
        "start_time": "2025-03-13T02:41:15.144470Z",
        "end_time": "2025-03-13T02:41:17.382162Z",
        "elapsed_time": 2,
        "error": null,
        "outputs": {
            "id": "chatcmpl-a9fd051615c7405e8d299c797ee16223",
            "object": "chat.completion",
            "created": 1741833676,
            "model": "virtuoso-medium",
            "choices": [
                {
                    "index": 0,
                    "message": {
                        "role": "assistant",
                        "reasoning_content": null,
                        "content": "Why was the weather forecast sad?\n\nBecause it had a lot of problems and was feeling a little \"forecast-ticular.\" \n\n(Note: \"Forecast-ticular\" is a play on words, combining \"forecast\" and \"particular.\")",
                        "tool_calls": []
                    },
                    "logprobs": null,
                    "finish_reason": "stop",
                    "stop_reason": null
                }
            ],
            "usage": {
                "prompt_tokens": 36,
                "total_tokens": 84,
                "completion_tokens": 48,
                "prompt_tokens_details": null
            },
            "prompt_logprobs": null,
            "confidence_info": {
                "error": "No logprobs available - model/provider may not support confidence calculation",
                "confidence_score": null,
                "mean_entropy": null,
                "total_entropy": null
            }
        },
        "inputs": {
            "model": "virtuoso-medium",
            "stream": false,
            "max_tokens": 8192,
            "temperature": 0.7,
            "top_p": 1,
            "top_k": 50,
            "repetition_penalty": 0,
            "messages": [
                {
                    "role": "user",
                    "content": "Tell me a joke about the weather"
                }
            ],
            "run_id": "5b69669f-975a-49af-a33a-61ff9ae5a20f",
            "input_data": {
                "prompt": "Tell me a joke about the weather"
            }
        },
        "step_metadata": null,
        "tokens": 0
    },
    {
        "id": "ad6edfea-bf1c-4639-9d9f-b53c9ad60bgg",
        "user_id": "2*****************1",
        "organization_id": "2*****************7",
        "node_id": "slack_integration",
        "status": "completed",
        "start_time": "2025-03-13T02:41:17.403879Z",
        "end_time": "2025-03-13T02:41:19.179523Z",
        "elapsed_time": 1,
        "error": null,
        "outputs": {
            "result": {
                "data": {
                    "ok": true,
                    "channel": "C0257V9FS09",
                    "ts": "1741833679.099979",
                    "warning": "missing_charset",
                    "response_metadata": {
                        "warnings": [
                            "missing_charset"
                        ]
                    }
                },
                "error": null,
                "successfull": true,
                "successful": true
            }
        },
        "inputs": {
            "app_name": "slack",
            "action": "SLACK_SHARE_A_ME_MESSAGE_IN_A_CHANNEL",
            "entity_id": "a***********m",
            "workspace_type": "local",
            "input_mapping": {
                "channel": "orchestra-demo",
                "text": "Why was the weather forecast sad?\n\nBecause it had a lot of problems and was feeling a little \"forecast-ticular.\" \n\n(Note: \"Forecast-ticular\" is a play on words, combining \"forecast\" and \"particular.\")"
            },
            "tool_config": {
                "tool_type": "slack"
            },
            "run_id": "5b69669f-975a-49af-a33a-61ff9ae5a20f",
            "input_data": {
                "prompt": "Tell me a joke about the weather",
                "model": "Why was the weather forecast sad?\n\nBecause it had a lot of problems and was feeling a little \"forecast-ticular.\" \n\n(Note: \"Forecast-ticular\" is a play on words, combining \"forecast\" and \"particular.\")"
            }
        },
        "step_metadata": null,
        "tokens": 0
    }
]
```

</details>

### **Response Syntax Variables**

For each node in the workflow, there will be the following output:

* id: ID associated with the specific step in the workflow
* User id: ID associated with the user who executed the workflow
* Organization id: ID of the organization where the workflow is stored
* Node id: ID for the specific node which is executed during this step
* Status: status of the workflow step
* **Start time**: date-time when the step began execution
* **End time**: date-time when the step finished execution
* **Elapsed time**: Amount of seconds the step took to complete
* **Error**: Any errors which occurred during step execution
* **Outputs**: The output of the step
  * Output data will vary based on the specific node which is executed
* **Inputs**: The input to the step
  * Input data will vary based on the specific node which is executed
* **Step Metadata**: Metadata associated with the specific step
* **Tokens**: number of tokens utilized in the step
  * Currently this is always set to 0


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.arcee.ai/arcee-orchestra/workflows/api-invocation/workflow-execution-steps-api.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
