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

# Get Workflow Request History

> Retrieves cursor-based paginated execution history for a workflow.

Retrieves cursor-based paginated execution history for a workflow.

## Usage

<CodeGroup>
  ```bash cURL theme={null}
  curl -H "Authorization: Bearer YOUR_TOKEN" \
    "https://app.splox.io/api/v1/workflow-requests/{workflow_request_id}/history?limit=10"
  ```

  ```python Python theme={null}
  from splox import SploxClient

  client = SploxClient(api_key="YOUR_API_KEY")
  result = client.workflows.get_history("WORKFLOW_REQUEST_ID", limit=10)
  for req in result.data:
      print(f"[{req.status}] {req.id} — {req.created_at}")
  ```

  ```typescript Node.js theme={null}
  import Splox from "splox";

  const client = new Splox("YOUR_API_KEY");
  const result = await client.workflows.getHistory("WORKFLOW_REQUEST_ID", { limit: 10 });
  for (const req of result.data) {
    console.log(`[${req.status}] ${req.id} — ${req.created_at}`);
  }
  ```

  ```go Go theme={null}
  client := splox.NewClient("YOUR_API_KEY")
  result, err := client.Workflows.GetHistory(ctx, "WORKFLOW_REQUEST_ID", &splox.HistoryParams{
      Limit: 10,
  })
  for _, req := range result.Data {
      fmt.Printf("[%s] %s — %s\n", req.Status, req.ID, req.CreatedAt)
  }
  ```
</CodeGroup>

## Query Parameters

| Parameter | Type    | Default | Description                                 |
| --------- | ------- | ------- | ------------------------------------------- |
| `limit`   | integer | 10      | Items per page (max: 100)                   |
| `cursor`  | uuid    | —       | Cursor from previous response for next page |
| `search`  | string  | —       | Search string to filter results             |

## Response

```json theme={null}
{
  "data": [
    {
      "id": "0199f123-d60e-7ffd-9131-4cc5ab040ee8",
      "workflow_version_id": "0199e001-a23b-7c8d-1234-567890abcdef",
      "entry_node_ids": ["0199e002-b34c-8d9e-2345-678901bcdef0"],
      "status": "completed",
      "payload": { "text": "Hello", "chat_id": "..." },
      "started_at": "2025-10-22T12:15:32Z",
      "completed_at": "2025-10-22T12:15:47Z",
      "created_at": "2025-10-22T12:15:30Z"
    }
  ],
  "pagination": {
    "limit": 10,
    "next_cursor": "0199f122-c50d-6eec-8020-3bb4a9f30dd7"
  }
}
```

**Pagination:** If `next_cursor` is present, pass it as `?cursor=<value>` to get the next page. If `next_cursor` is absent, there are no more results.

## Notes

<Info>
  **Authentication required:** Include Bearer token in Authorization header.
</Info>


## OpenAPI

````yaml GET /workflow-requests/{id}/history
openapi: 3.1.0
info:
  title: Splox API
  description: >-
    Run workflows, manage chats, receive events, and monitor execution via the
    Splox API
  version: 1.0.0
  contact:
    name: Splox Support
    email: support@splox.io
    url: https://community.splox.io
servers:
  - url: https://app.splox.io/api/v1
    description: Production API
security: []
tags:
  - name: MCP
    description: Discover MCP servers, manage connections, and execute MCP tools
  - name: Workflows
    description: List, get, and inspect workflows, versions, and nodes
  - name: Workflow Requests
    description: Run workflows, monitor execution, and retrieve results
  - name: Events
    description: Receive external events via Event Hub webhooks
  - name: Chats
    description: Manage chat sessions for workflow interactions
paths:
  /workflow-requests/{id}/history:
    get:
      tags:
        - Workflow Requests
      summary: Get Workflow Request History
      description: Retrieves cursor-based paginated execution history for a workflow.
      operationId: getWorkflowHistory
      parameters:
        - name: id
          in: path
          required: true
          description: Workflow request ID
          schema:
            type: string
            format: uuid
        - name: limit
          in: query
          description: 'Items per page (default: 10, max: 100)'
          schema:
            type: integer
            default: 10
            maximum: 100
        - name: cursor
          in: query
          description: Cursor for pagination (UUID of last item from previous page)
          schema:
            type: string
            format: uuid
        - name: search
          in: query
          description: Search string to filter results
          schema:
            type: string
      responses:
        '200':
          description: History retrieved successfully
          content:
            application/json:
              schema:
                type: object
                properties:
                  data:
                    type: array
                    items:
                      $ref: '#/components/schemas/WorkflowRequest'
                  pagination:
                    type: object
                    properties:
                      limit:
                        type: integer
                      next_cursor:
                        type: string
                        format: uuid
                        nullable: true
                        description: Cursor for next page. Null if no more results.
      security:
        - bearerAuth: []
components:
  schemas:
    WorkflowRequest:
      type: object
      description: Represents a workflow execution request
      properties:
        id:
          type: string
          format: uuid
          description: Unique workflow request identifier
        workflow_version_id:
          type: string
          format: uuid
          description: ID of the workflow version being executed
        entry_node_ids:
          type: array
          items:
            type: string
            format: uuid
          description: IDs of the entry nodes execution began at
        user_id:
          type: string
          format: uuid
          description: ID of the user who owns the workflow
        billing_user_id:
          type: string
          format: uuid
          nullable: true
          description: ID of the user being billed for this execution
        parent_node_execution_id:
          type: string
          format: uuid
          nullable: true
          description: ID of parent node execution (for child agent invocations)
        parent_workflow_request_id:
          type: string
          format: uuid
          description: ID of parent workflow request (same as id for root requests)
        chat_id:
          type: string
          nullable: true
          description: Chat session ID associated with this execution
        status:
          type: string
          enum:
            - pending
            - in_progress
            - waiting
            - completed
            - failed
            - stopped
          description: Current execution status
        payload:
          type: object
          additionalProperties: true
          description: Input payload passed to the entry node
        metadata:
          type: object
          nullable: true
          additionalProperties: true
          description: Additional metadata
        started_at:
          type: string
          format: date-time
          nullable: true
          description: When execution started
        completed_at:
          type: string
          format: date-time
          nullable: true
          description: When execution completed
        created_at:
          type: string
          format: date-time
          description: When the request was created
      required:
        - id
        - workflow_version_id
        - entry_node_ids
        - status
        - created_at
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer
      description: >-
        API token generated from your Splox account settings. Create tokens at
        https://app.splox.io/account?tab=settings

````