---
title: "Cancel a contact's automation runs"
description: "Stop one contact's live runs in every automation, or only in automation_ids: someone asked you to stop, got a refund, or opened a support case. `POST /api/v1/contacts/{id}/automation-runs/cancel`"
url: https://www.unitpost.com/docs/automations/post-contacts-id-automation-runs-cancel
section: "Automations API reference"
updated: 2026-12-01
---
# Cancel a contact's automation runs

`POST /api/v1/contacts/{id}/automation-runs/cancel`

Stop one contact's live runs in every automation, or only in `automation_ids`: someone asked you to stop, got a refund, or opened a support case. Their timers are cancelled and nothing more is sent to them by those runs; the automations stay live for everyone else (a later trigger can start them again, so add an exit rule or update the contact when that must not happen). `{id}` is the contact's id or email. The runs it stops are the ones [List a contact's automation runs](https://www.unitpost.com/docs/automations/get-contacts-id-automation-runs) shows in progress. Also needs `contacts:read` (it names a contact). Requires the `automations:write` capability.

## Parameters

| Name | In | Type | Required | Description |
| --- | --- | --- | --- | --- |
| `id` | path | string | yes | The contact's id (`con_…`) or email. |

## Request body

| Field | Type | Required | Description |
| --- | --- | --- | --- |
| `automation_ids` | string[] | no | Only these automations (`atm_…`, up to 100). Leave it out to stop the contact's runs in every automation. |
| `status` | enum | no | Which live runs to cancel: all (`live`, default), only `active` or only `waiting`. One of: `live`, `active`, `waiting`. |

## Response fields (200)

| Field | Type | Required | Description |
| --- | --- | --- | --- |
| `object` | string | yes | — |
| `contact_id` | string | yes | — |
| `canceled` | integer | yes | Runs canceled, across every automation. |
| `automations` | object[] | yes | Each automation it stopped runs in, most runs first. Empty when nothing was live. |

## Responses

| Status | Description |
| --- | --- |
| 200 | How many runs were canceled, per automation. |
| 400 | A body that isn't JSON. Nothing was canceled. |
| 401 | Missing or invalid API key. |
| 403 | Insufficient scope. |
| 404 | Contact, or one of `automation_ids`, not found. |
| 422 | A bad `status`, more than 100 `automation_ids`, an unknown key, or a body that isn't a JSON object. Send no body to stop every live run. |

## Example request

```bash
curl -X POST 'https://www.unitpost.com/api/v1/contacts/con_123/automation-runs/cancel' \
  -H 'Authorization: Bearer YOUR_API_KEY' \
  -H 'User-Agent: my-app/1.0' \
  -H 'Content-Type: application/json' \
  -d '{
    "automation_ids": [
      "atm_123"
    ]
  }'
```

## Example response (200)

```json
{
  "object": "contact_automation_runs_cancel",
  "contact_id": "contact_123",
  "canceled": 0,
  "automations": [
    {
      "automation_id": "automation_123",
      "canceled": 0
    }
  ]
}
```

## Links

- HTML reference (with Node.js, Python, Ruby, PHP, Laravel, Go, Java, Rust, .NET and CLI examples): https://www.unitpost.com/docs/automations/post-contacts-id-automation-runs-cancel
- OpenAPI 3.1 (full schemas): https://www.unitpost.com/api/v1/openapi.json
