# Errors

> What each error code means and how to fix it.

Source: https://sndr.sh/docs/errors

Errors use standard HTTP status codes and the same JSON shape:

```json
{
  "error": {
    "code": "domain_not_verified",
    "message": "Domain mail.acme.com is not verified.",
    "request_id": "req_8a91lk2"
  }
}
```

- `code` (string, required): Stable, machine-readable reason. Branch on this, not on `message`.
- `message` (string, required): Human-readable explanation.
- `request_id` (string): Include it when you contact support.
- `field` (string): The request field that caused the error, when there is one.
- `fields` (object): Per-field messages for `validation_failed`.
- `retry_after_seconds` (integer): How long to wait before retrying a `429`.

## Codes

| Code | HTTP | Meaning |
| --- | --- | --- |
| invalid_request | 400 | The body or a parameter is invalid. `message` says what to fix. |
| suppressed | 400 | Every `to` address is on your suppression list. |
| unauthenticated | 401 | The API key is missing, wrong or revoked. |
| quota_exceeded | 402 | Your monthly email quota is used up. Upgrade or wait for the reset. |
| plan_limit_reached | 402 | Your plan’s limit for this resource (domains, webhooks…) is reached. |
| insufficient_scope | 403 | The API key lacks the scope this endpoint needs (`read` or `send`). |
| domain_not_linked | 403 | The `from` domain hasn’t been added to this workspace. |
| domain_not_verified | 403 | The `from` domain is added but not verified yet, or its required DNS records have stayed missing for about 12 hours. See [Domains](https://sndr.sh/docs/domains). |
| quarantine_active | 403 | Sending is paused for this workspace. Contact support. |
| workspace_suspended | 403 | SNDR has suspended this workspace. Every API request is refused and `message` gives the reason. Contact support; don’t retry. |
| workspace_limit_reached | 403 | Your account already owns as many workspaces as it can (3 by default). Contact support to raise the limit. |
| forbidden | 403 | This key or workspace isn’t allowed to do that. |
| not_found | 404 | The resource doesn’t exist in this workspace. |
| conflict | 409 | The resource already exists or changed. |
| payload_too_large | 413 | The request body is over 16 MiB. |
| validation_failed | 422 | One or more fields are invalid. See `fields`. |
| rate_limited | 429 | Too many requests. Retry after `retry_after_seconds`. |
| send_velocity | 429 | You’re sending faster than allowed. Back off and retry. |
| server_error | 500 | Something failed on our side. Retry with backoff. |
| internal | 500 | Same as `server_error`. |
| sends_frozen | 503 | Sending is paused for maintenance. Check the status page and retry. |

> **Tip:** Retry `429` and `5xx` responses with exponential backoff. Don’t retry `4xx` errors until you’ve fixed the request.
