Error response format
Most errors return anerror field with a human-readable message:
details and issues fields with field-level validation information:
Missing credentials
A request with no credentials returns402 Payment Required, not 401. Every paid route also accepts x402 wallet authentication, so the response is a payment challenge: it includes a PAYMENT-REQUIRED header and a body describing both ways to authenticate.
Authorization: Bearer header is set. A key that is present but invalid returns 401.
Request format errors
These errors come from reading the request body, before any endpoint-specific validation runs.
A wrong
Content-Type returns 400, not 415. Size-limit 413 responses also include a code field: