---
title: "Get a list of Runbook Run Previews for a Runbook"
method: POST
path: "/projects/{projectId}/{gitRef}/runbooks/{runbookId}/runbookRuns/previews"
tags: ["Runbooks"]
---

# Get a list of Runbook Run Previews for a Runbook

`POST /projects/{projectId}/{gitRef}/runbooks/{runbookId}/runbookRuns/previews`

Gets a list of Runbook Run Previews that describes what steps will/won't be run during a Runbook Run on a given environment and tenant for a Runbook.

## Path parameters

- `projectId` string, required
- `gitRef` string, required
- `runbookId` string, required

## Request body

- GetRunbookRunPreviewsInGitRequest
  - `DeploymentPreviews` DeploymentPreviewRequest[], required
    - `EnvironmentId` string
    - `TenantId` string
  - `GitRef` string, required
  - `IncludeDisabledSteps` boolean
  - `ProjectId` string, required
  - `RunbookId` string, required
  - `SpaceId` string, required

## Response `200`

The requested list of Runbook Run previews

- RunbookRunPreviewResource[]
  - `Form` Form
    - `Elements` FormElement[]
      - `Control` Control
        - `Type` 'Checkbox' | 'TextArea' | 'Paragraph' | 'SubmitButtonGroup' | 'VariableValue'
      - `IsValueRequired` boolean
      - `Name` string
    - `Values` object
  - `Id` string
  - `LastModifiedBy` string
  - `LastModifiedOn` string, date-time
  - `Links` object
  - `StepsToExecute` DeploymentTemplateStep[]
    - `ActionId` string
    - `ActionName` string
    - `ActionNumber` string
    - `AvailableTagSets` TagSetPreview[]
      - `AvailableTags` TargetTagPreview[]
        - `SortOrder` integer
        - `TagId` string, required
        - `TagName` string, required
      - `SortOrder` integer
      - `TagSetId` string, required
      - `TagSetName` string, required
      - `TagSetType` string, required
    - `CanBeSkipped` boolean
    - `ExcludedMachines` ReferenceDataItem[]
      - `Id` string
      - `Name` string
    - `HasNoApplicableMachines` boolean
    - `IsDisabled` boolean
    - `MachineNames` string[]
    - `Machines` MachineDeploymentPreview[]
      - `HasLatestCalamari` boolean
      - `HealthStatus` 'Healthy' | 'HasWarnings' | 'Unhealthy' | 'Unavailable'
      - `Id` string
      - `Name` string
    - `Roles` string[]
    - `UnavailableMachines` ReferenceDataItem[]
      - `Id` string
      - `Name` string
  - `UseGuidedFailureModeByDefault` boolean

## Other responses

- `400` — Bad request. Either the payload was not structurally valid or business rules did not permit the operation.
- `404` — Not found. One or more of the entities involved in the operation was not found.

---

[API](https://skmtc.net/octopus/apis/octopus-server-api.md) · [All operations](https://skmtc.net/octopus/apis/octopus-server-api/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/octopus/octopus-server-api/versions/bc9158facfc7/schema)
