Skip to main content

Errors and status codes

When an API request fails, the response carries a standard HTTP status code plus a machine-readable body that explains what went wrong. Use the status code to decide how to react (retry, fix, or stop) and the body to decide what to fix. Error bodies typically include an error code, a human-readable message, and — for validation failures — the specific fields at fault. (Confirm the exact field names in your account.)

Reference

StatusMeaningTypical causeRecommended action
200 / 201SuccessRequest accepted or resource createdContinue; read the body for IDs.
400 Bad RequestMalformed requestInvalid JSON, missing required field, bad token valueFix the request; do not retry unchanged.
401 UnauthorizedNot authenticatedMissing, expired, or revoked API key/tokenRefresh credentials, then retry.
403 ForbiddenNot permittedKey lacks scope for this endpoint or resourceAdjust key permissions; do not retry unchanged.
404 Not FoundNo such resourceWrong ID, deleted Edition, or wrong pathVerify the identifier; do not retry unchanged.
409 ConflictState conflictDuplicate send, already-processed requestReconcile state; safe to skip retry.
422 UnprocessableValidation failedField-level errors (e.g. invalid subscriber address)Read the errors list; fix and resend.
429 Too Many RequestsRate limitedSending requests faster than your quotaBack off and retry per Retry-After.
5xx Server ErrorTransient failureTemporary service issueRetry with exponential backoff.

Example error body (shape is representative; confirm exact keys in your account):

{
"error": {
"code": "validation_error",
"message": "One or more fields are invalid.",
"fields": { "recipient": "not a valid subscriber address" }
}
}

Notes

  • Retry only when it can succeed. 429 and 5xx are retryable; use exponential backoff with jitter and honor the Retry-After header when present. 4xx errors (except 429) indicate a client-side problem — retrying the same request will fail again.
  • Make writes idempotent. For send and create operations, pass a unique idempotency key (confirm the exact header in your account) so a retried request does not produce a duplicate Broadcast.
  • Read the code, not the message. Match on the machine-readable code; the human-readable message text may change over time.
  • Log the request ID. Responses generally include a correlation/request identifier — capture it so support can trace a specific failure.

Canonical terms: Author, Edition, Folder (Project Folder), Broadcast. See the Glossary.