---
title: "Get one playbook run"
---

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

# Get one playbook run

Path: CloudRaker Workspace API › Playbooks

`GET /spaces/{spaceId}/playbook-runs/{runId}`

Fetches one playbook run with full detail: current status, task progress, any pending approval, current activity, result/error, and the immutable snapshot of the playbook (tasks + actions + fileScope) captured at launch. Authorization: `space:read` (org admins bypass); missing → 404; 404 also when the run does not exist in this space. Returns `{ data: PlaybookRunDetail }`.

## Authentication

- `bearerAuth`, http, header `Authorization`

## Path parameters

- `spaceId` (`getPlaybookRun.path.spaceId`; string, required)
- `runId` (`getPlaybookRun.path.runId`; string, required)

## Code samples

### cURL

```bash
curl --request GET \
  --url 'https://api.cloudraker.com/spaces/<spaceId>/playbook-runs/<runId>' \
  --header 'Authorization: Bearer <token>'
```

### TypeScript

```typescript
const url = 'https://api.cloudraker.com/spaces/<spaceId>/playbook-runs/<runId>';
const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};

fetch(url, options)
  .then(res => res.json())
  .then(json => console.log(json))
  .catch(err => console.error(err));
```

### Python

```python
import requests

url = "https://api.cloudraker.com/spaces/<spaceId>/playbook-runs/<runId>"

headers = {"Authorization": "Bearer <token>"}

response = requests.get(url, headers=headers)

print(response.text)
```

## Responses

### 200

The playbook run, with its launch snapshot.

#### Example

```json
{
  "data": {
    "id": "string",
    "spaceId": "string",
    "playbookId": "string",
    "playbookVersion": -9007199254740991,
    "playbookName": "string",
    "status": "running",
    "fileScope": {
      "mode": "space"
    },
    "taskProgress": {
      "total": -9007199254740991,
      "completed": -9007199254740991
    },
    "pendingApproval": {
      "id": "string",
      "kind": "pre",
      "actionName": "string",
      "requestedAt": "2019-08-24T14:15:22Z"
    },
    "result": "string",
    "error": "string",
    "startedBy": "string",
    "createdAt": "2019-08-24T14:15:22Z",
    "updatedAt": "2019-08-24T14:15:22Z",
    "finishedAt": "2019-08-24T14:15:22Z",
    "currentActivity": "string",
    "snapshot": {
      "playbookId": "string",
      "version": -9007199254740991,
      "name": "string",
      "description": "string",
      "tasks": [
        {
          "id": "string",
          "title": "string",
          "instructions": "string",
          "dependsOn": [
            "string"
          ],
          "executor": "agent",
          "assignee": "string",
          "status": "pending",
          "claimedBy": "string",
          "summary": "string",
          "completedBy": "string",
          "note": "string",
          "fileIds": [
            "string"
          ],
          "completedAt": "2019-08-24T14:15:22Z"
        }
      ],
      "actions": [
        {
          "installedActionId": "string",
          "preApproval": true,
          "postApproval": true,
          "dependsOn": [
            "string"
          ],
          "actionSlug": "string",
          "actionName": "string",
          "trigger": "agent",
          "browserSession": {
            "status": "pairing",
            "createdAt": "2019-08-24T14:15:22Z"
          }
        }
      ],
      "fileScope": {
        "mode": "space"
      }
    }
  }
}
```

- `data` (`getPlaybookRun.response.200.data`; object, required)
  - `id` (`getPlaybookRun.response.200.data.id`; string, required)
  - `spaceId` (`getPlaybookRun.response.200.data.spaceId`; string, required)
  - `playbookId` (`getPlaybookRun.response.200.data.playbookId`; string, required)
  - `playbookVersion` (`getPlaybookRun.response.200.data.playbookVersion`; integer, required)
    - min -9007199254740991; max 9007199254740991
  - `playbookName` (`getPlaybookRun.response.200.data.playbookName`; string, required)
  - `status` (`getPlaybookRun.response.200.data.status`; string, required)
    - one of `"running"`, `"waiting_approval"`, `"waiting_action"`, `"waiting_user"`, `"paused"`, `"completed"`, `"failed"`, `"cancelled"`
  - `fileScope` (`getPlaybookRun.response.200.data.fileScope`; PlaybookFileScope, required)
    - one of:
      - `object`
        - `mode` (`getPlaybookRun.response.200.data.fileScope.1.mode`; string, required)
      - `object`
        - `mode` (`getPlaybookRun.response.200.data.fileScope.2.mode`; string, required)
        - `fileIds` (`getPlaybookRun.response.200.data.fileScope.2.fileIds`; array<string>, required)
          - minLength 1
  - `taskProgress` (`getPlaybookRun.response.200.data.taskProgress`; object, required)
    - `total` (`getPlaybookRun.response.200.data.taskProgress.total`; integer, required)
      - min -9007199254740991; max 9007199254740991
    - `completed` (`getPlaybookRun.response.200.data.taskProgress.completed`; integer, required)
      - min -9007199254740991; max 9007199254740991
  - `pendingApproval` (`getPlaybookRun.response.200.data.pendingApproval`; any of, required)
    - any of:
      - `object`
        - `id` (`getPlaybookRun.response.200.data.pendingApproval.1.id`; string, required)
        - `kind` (`getPlaybookRun.response.200.data.pendingApproval.1.kind`; string, required)
          - one of `"pre"`, `"post"`
        - `actionName` (`getPlaybookRun.response.200.data.pendingApproval.1.actionName`; string, required)
        - `requestedAt` (`getPlaybookRun.response.200.data.pendingApproval.1.requestedAt`; string, required)
          - format `date-time`; pattern `^(?:(?:\d\d[2468][048]|\d\d[13579][26]|\d\d0[48]|[02468][048]00|[13579][26]00)-02-29|\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\d|30)|(?:02)-(?:0[1-9]|1\d|2[0-8])))T(?:(?:[01]\d|2[0-3]):[0-5]\d:[0-5]\d(?:\.\d+)?(?:Z))$`
      - `null`
  - `result` (`getPlaybookRun.response.200.data.result`; string | null, required)
  - `error` (`getPlaybookRun.response.200.data.error`; string | null, required)
  - `startedBy` (`getPlaybookRun.response.200.data.startedBy`; string, required)
  - `createdAt` (`getPlaybookRun.response.200.data.createdAt`; string, required)
    - format `date-time`; pattern `^(?:(?:\d\d[2468][048]|\d\d[13579][26]|\d\d0[48]|[02468][048]00|[13579][26]00)-02-29|\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\d|30)|(?:02)-(?:0[1-9]|1\d|2[0-8])))T(?:(?:[01]\d|2[0-3]):[0-5]\d:[0-5]\d(?:\.\d+)?(?:Z))$`
  - `updatedAt` (`getPlaybookRun.response.200.data.updatedAt`; string, required)
    - format `date-time`; pattern `^(?:(?:\d\d[2468][048]|\d\d[13579][26]|\d\d0[48]|[02468][048]00|[13579][26]00)-02-29|\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\d|30)|(?:02)-(?:0[1-9]|1\d|2[0-8])))T(?:(?:[01]\d|2[0-3]):[0-5]\d:[0-5]\d(?:\.\d+)?(?:Z))$`
  - `finishedAt` (`getPlaybookRun.response.200.data.finishedAt`; any of, required)
    - any of: `string`, `null`
  - `currentActivity` (`getPlaybookRun.response.200.data.currentActivity`; string | null, required)
  - `snapshot` (`getPlaybookRun.response.200.data.snapshot`; object, required) — The playbook as captured at launch. Later edits never affect a run.
    - `playbookId` (`getPlaybookRun.response.200.data.snapshot.playbookId`; string, required)
    - `version` (`getPlaybookRun.response.200.data.snapshot.version`; integer, required)
      - min -9007199254740991; max 9007199254740991
    - `name` (`getPlaybookRun.response.200.data.snapshot.name`; string, required)
    - `description` (`getPlaybookRun.response.200.data.snapshot.description`; string, required)
    - `tasks` (`getPlaybookRun.response.200.data.snapshot.tasks`; array<object>, required)
      - `id` (`getPlaybookRun.response.200.data.snapshot.tasks.id`; string, required)
      - `title` (`getPlaybookRun.response.200.data.snapshot.tasks.title`; string, required)
      - `dependsOn` (`getPlaybookRun.response.200.data.snapshot.tasks.dependsOn`; array<string>, required)
      - `status` (`getPlaybookRun.response.200.data.snapshot.tasks.status`; string, required)
        - one of `"pending"`, `"ready"`, `"in_progress"`, `"completed"`, `"skipped"`
      - `summary` (`getPlaybookRun.response.200.data.snapshot.tasks.summary`; string | null, required)
      - `completedAt` (`getPlaybookRun.response.200.data.snapshot.tasks.completedAt`; any of, required)
        - any of: `string`, `null`
      - `instructions` (`getPlaybookRun.response.200.data.snapshot.tasks.instructions`; string | null, optional)
      - `executor` (`getPlaybookRun.response.200.data.snapshot.tasks.executor`; string, optional)
        - one of `"agent"`, `"human"`
      - `assignee` (`getPlaybookRun.response.200.data.snapshot.tasks.assignee`; string | null, optional)
      - `claimedBy` (`getPlaybookRun.response.200.data.snapshot.tasks.claimedBy`; string | null, optional)
      - `completedBy` (`getPlaybookRun.response.200.data.snapshot.tasks.completedBy`; string | null, optional)
      - `note` (`getPlaybookRun.response.200.data.snapshot.tasks.note`; string | null, optional)
      - `fileIds` (`getPlaybookRun.response.200.data.snapshot.tasks.fileIds`; array<string>, optional)
    - `actions` (`getPlaybookRun.response.200.data.snapshot.actions`; array<object>, required)
      - `installedActionId` (`getPlaybookRun.response.200.data.snapshot.actions.installedActionId`; string, required)
      - `preApproval` (`getPlaybookRun.response.200.data.snapshot.actions.preApproval`; boolean, required)
      - `postApproval` (`getPlaybookRun.response.200.data.snapshot.actions.postApproval`; boolean, required)
      - `dependsOn` (`getPlaybookRun.response.200.data.snapshot.actions.dependsOn`; array<string>, required)
      - `actionSlug` (`getPlaybookRun.response.200.data.snapshot.actions.actionSlug`; string, required)
      - `actionName` (`getPlaybookRun.response.200.data.snapshot.actions.actionName`; string, required)
      - `trigger` (`getPlaybookRun.response.200.data.snapshot.actions.trigger`; string, required)
        - one of `"agent"`, `"user"`
      - `browserSession` (`getPlaybookRun.response.200.data.snapshot.actions.browserSession`; any of, required)
        - any of:
          - `object`
            - `status` (`getPlaybookRun.response.200.data.snapshot.actions.browserSession.1.status`; string, required)
              - one of `"pairing"`, `"live"`, `"ended"`, `"expired"`
            - `createdAt` (`getPlaybookRun.response.200.data.snapshot.actions.browserSession.1.createdAt`; string, required)
              - format `date-time`; pattern `^(?:(?:\d\d[2468][048]|\d\d[13579][26]|\d\d0[48]|[02468][048]00|[13579][26]00)-02-29|\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\d|30)|(?:02)-(?:0[1-9]|1\d|2[0-8])))T(?:(?:[01]\d|2[0-3]):[0-5]\d:[0-5]\d(?:\.\d+)?(?:Z))$`
          - `null`
    - `fileScope` (`getPlaybookRun.response.200.data.snapshot.fileScope`; PlaybookFileScope, required)
      - one of:
        - `object`
          - `mode` (`getPlaybookRun.response.200.data.snapshot.fileScope.1.mode`; string, required)
        - `object`
          - `mode` (`getPlaybookRun.response.200.data.snapshot.fileScope.2.mode`; string, required)
          - `fileIds` (`getPlaybookRun.response.200.data.snapshot.fileScope.2.fileIds`; array<string>, required)
            - minLength 1

### 404

Run not found, or caller lacks space:read


Source: https://docs.cloudraker.com/workspace/api/playbooks/get-playbook-run/index.md
