# Cancel all scheduled sends for a mailbox

Cancels all pending scheduled sends for this mailbox, optionally scoped to a specific creator credential.

## `POST /api/v1/mailboxes/{mailboxId}/scheduled/cancel`

### Path parameters

- `mailboxId` (string, required) — Mailbox ULID identifier

### Query parameters

- `actorId` (string) — Filter cancellation to schedules created by this specific credential or API key ID

### Responses

**200** — Count of canceled scheduled sends

`application/json` → object

- `canceled` (integer, required) — Number of scheduled sends canceled

**401** — unauthorized: the bearer credential is missing, malformed, expired, or revoked. Carries a `WWW-Authenticate: Bearer` challenge

`application/json` → ErrorBody

**404** — Mailbox not found or not accessible

`application/json` → ErrorBody

**503** — temporary_failure: the platform's storage could not answer just now; retry after the Retry-After window. Any operation can answer this. A write that got it may have been applied, so retry it with the same idempotency key where it takes one, or read the state back first (see Transient failures in the API description)

`application/json` → ErrorBody

### Example request

```bash
curl -X POST 'https://api.open.email/api/v1/mailboxes/{mailboxId}/scheduled/cancel' \
  -H 'Authorization: Bearer oek_…'
```

## TypeScript SDK

[`openemail.scheduled.cancelAll`](/docs/sdks/typescript/scheduled/cancel-all)

```ts
const result = await openemail.scheduled.cancelAll(mailboxId)
```
