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

# Cancel Agent Run

> Cancel an in-progress run.

Cancels an active run and prevents additional downstream processing.

## Request

```bash theme={null}
curl -X POST "https://api.mosaic.so/agent_run/[run_id]/cancel" \
  -H "Authorization: Bearer mk_your_api_key"
```

## Response

```json theme={null}
{
  "success": true,
  "run_id": "7f8d9c2b-4a6e-8b3f-1d5c-9e2f3a4b5c6d",
  "tasks_cancelled": 2,
  "nodes_reset": 3,
  "message": "Agent run cancelled successfully"
}
```
