One error shape, a code on every error, and a request id on every response
Errors from POST /v1/send, the Public API (/api/public/v1) and the Developer Sandbox API now share one shape, and there is a page listing every code: Errors.
- A
codeon every error. Some errors used to carry only a sentence inerror. They now also carry a stablecode: the specific one where the route has it, otherwise one derived from the HTTP status (for examplenot_found). Branch oncode. X-Request-Idon every response, success or error, and the same value asrequestIdin every error body. Quote it to support and we can find the exact call. You can send your ownX-Request-Idto tie our logs to your trace.- Nothing you rely on changed. Every field and every code an error had before is still there, spelled the same way, including the older upper-case codes such as
VALIDATION_ERROR. New codes are lower snake_case. - OpenAPI: every error response now references one
Errorschema and theX-Request-Idheader, andx-motorical-error-codeslists every code (openapi.json, version 1.5.0).
Documentation changed