Where to find it
Each response carries anX-Request-Id response header. On error responses, the same value is
mirrored in the body as error.request_id, so you can capture it even when you only have the
parsed JSON.
Present on every response (success and error). Opaque, prefixed with
req_.On error responses, the request ID is also included in the body so you can log it alongside the
error
type, code, and message.Error response
The value in
error.request_id is always identical to the X-Request-Id response header for that
request. Capture either one — they refer to the same call.Echoing your own request ID
If you generate your own correlation ID, send it in thex-request-id request header. Chataigne
echoes that value back in the X-Request-Id response header instead of generating a new one, so a
single ID flows through your logs and ours.
Optional. A correlation ID of your choosing. When supplied, it is returned verbatim as the
X-Request-Id response header. Keep it unique per request so it stays useful for tracing.Capturing it in your client
Read the header on every response and log it next to your own request metadata. The example below captures the request ID on both success and failure.Node.js
Using request IDs for support
Contacting support
Include the request ID with any report. It lets us locate the exact request — including timing,
the surface (
/v1 or /admin/v1), the key used, and the error returned — without round trips for
more detail.- The request ID (
X-Request-Idorerror.request_id). - The HTTP status and error
type/code(see Errors). - The approximate timestamp of the request.