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

# Create a Runbook

> Create a reviewed draft or published programmable Runbook.

Requires `runbooks:write`. Returns the created Runbook.

<ParamField header="X-Idempotency-Key" type="string">
  Stable key for retrying the same creation request.
</ParamField>

<ParamField body="schemaVersion" type="integer" required>
  Must be `3`.
</ParamField>

<ParamField body="title" type="string" required>
  Unique Runbook title, 1–120 characters.
</ParamField>

<ParamField body="steps" type="RunbookStep[]" required>
  One to 100 primitive or agent steps.
</ParamField>

<ParamField body="parameters" type="RunbookParameter[]" required>
  Up to 50 validated inputs.
</ParamField>

<ParamField body="status" type="string">
  `draft` by default, or `published` after explicit review.
</ParamField>

<RequestExample>
  ```bash cURL theme={null}
  curl --request POST \
    --url https://api.infragrid.ai/v1/runbooks \
    --header "Authorization: Bearer $INFRAGRID_API_KEY" \
    --header "Content-Type: application/json" \
    --data '{
      "schemaVersion": 3,
      "title": "Open example",
      "steps": [{
        "id": "open",
        "kind": "primitive",
        "primitive": "browser.navigate",
        "input": {"url": "https://example.com"},
        "instruction": "Open Example Domain.",
        "surface": "browser",
        "effect": "read",
        "risk": "low",
        "applicationScope": ["example.com"],
        "completionCondition": "Example Domain is visible."
      }],
      "parameters": [],
      "status": "draft"
    }'
  ```
</RequestExample>


## Related topics

- [Publish a Runbook](/reference/runbooks/publish.md)
- [Create a run](/reference/runs/create.md)
- [Programmable Runbooks](/guides/runbooks.md)
- [TypeScript SDK](/sdks/typescript.md)
- [API overview](/reference/overview.md)
