Skip to content

Cancel Playbook Run ​

POST /external/v1/playbook-runs/:id/cancel

Cancels a run that is in progress. Steps not done yet become cancelled and leave everyone's task lists; completed steps stay as they are. A cancelled run cannot be resumed: start the playbook again if needed.

Authentication ​

Requires playbooks:run permission.

Path Parameters ​

ParameterTypeRequiredDescription
idstringYesRun identifier (UUID)

Request Body ​

FieldTypeRequiredDescription
reasonstringNoWhy the run was cancelled (max 1000 characters)

Request ​

bash
curl --request POST \
  --url "https://app.getraze.com/external/v1/playbook-runs/3ef8c1c3-c081-4187-a6aa-657fbf1a813b/cancel" \
  --header "Content-Type: application/json" \
  --header "X-API-Key: YOUR_API_KEY" \
  --data '{ "reason": "Deal lost" }'
javascript
const axios = require('axios');

const runId = '3ef8c1c3-c081-4187-a6aa-657fbf1a813b';

const response = await axios.post(
  `https://app.getraze.com/external/v1/playbook-runs/${runId}/cancel`,
  { reason: 'Deal lost' },
  { headers: { 'X-API-Key': 'YOUR_API_KEY' } }
);

console.log(response.data);
python
import requests

run_id = '3ef8c1c3-c081-4187-a6aa-657fbf1a813b'

response = requests.post(
    f'https://app.getraze.com/external/v1/playbook-runs/{run_id}/cancel',
    headers={'X-API-Key': 'YOUR_API_KEY'},
    json={'reason': 'Deal lost'}
)

print(response.json())

Response ​

The run, in the format of Get Playbook Run, with status: cancelled, cancelled_at and cancelled_reason.

Errors ​

StatusCodeDescription
404NOT_FOUNDRun not found in this account
409CONFLICTThe run is not in progress (already completed or cancelled)

GetRaze - AI-Powered Lead Generation