Splendor uses conventional HTTP status codes and returns a consistent error envelope. The 2xx range means success, 4xx means the request was rejected, and 5xx means a server-side or upstream problem.
The error envelope
Every error response has a detail field. For most errors it is a human-readable string; for validation and capacity errors it is a structured object with a stable code and a message.
Request validation errors (422) use the standard schema-validation shape, with a detail array describing each invalid field.
Status codes
Machine-readable codes
Structured errors carry a code you can branch on. The most common:
Retrying
Capacity errors (503) are transient. They include a Retry-After header indicating how long to wait before retrying. Back off and retry rather than failing the request outright.
Branch on the code for structured errors and on the HTTP status otherwise. Treat 5xx as retryable with backoff (honoring Retry-After on 503); treat 4xx as something to fix in the request.