Skip to main content

One shape

There is no {"error": {...}} wrapper anywhere in v2. Branch on code; show message to a person. A message never carries a stack trace or a source path.

Details keys

Keys that mean the same thing on every error:

Codes

Sending limits, plan allowances and reviews are the same as on v1. See Sending limits.

Retrying a 409

Every 409 is a settled answer: retrying the same request cannot change it. It carries the header x-should-retry: false, on v1 and v2 alike, and the SDKs honour it, so they raise the 409 as a ConflictError at once instead of retrying it. A repeated idempotencyKey is the case to handle on purpose: the original is in the error’s body, and that is how a retry learns the first attempt landed.

Wrong method

A path under /v2/messages, /v2/conversations, /v2/contacts, /v2/channels, /v2/templates, /v2/campaigns, /v2/agents, /v2/webhook or /v2/email-domains called with a method it does not take answers 405, not 404:
An unknown path is 404.