reason_code as the machine-readable identifier and retain detail
for diagnostics.
Error response structure
All error responses share this shape:string
required
Identifies the error category.
string
required
A short, human-readable summary of the error.
integer
required
The HTTP status code for this response (e.g.,
400, 401, 404).string
required
A detailed description of what went wrong in this specific request. Use this field for debugging and logging.
string
Identifies the request associated with this occurrence when available.
string
required
A machine-readable code identifying the failure cause. Use this for programmatic error handling and branching logic.
object
Optional error-specific data. Its properties vary by error.
HTTP status codes
Status codes by operation
This matrix lists all non-success responses declared by each published operation. Authentication and rate-limiting guidance above is maintained separately and does not add undeclared responses to an operation.Reason codes
Example error responses
The values below illustrate the shared response shape. A specificdetail, reason_code, or
context value is not guaranteed unless the endpoint contract declares it.
Handling errors in production
Use
reason_code rather than detail or title for programmatic handling. Human-readable
fields may change.500 Internal Server Error- retry with exponential backoff. Check status.smartretry.com if errors persist beyond a few minutes.429 Too Many Requests- wait for the number of seconds in theRetry-Afterresponse header before retrying. Do not retry immediately.503 Service Unavailable- if the reason code isROUTING/RESOURCE_LOCKED, retry the same POST request shortly with the sameIdempotency-Key.
400 Bad Request- fix the request before retrying. Check thecontext.fieldvalue to identify which field is invalid.401 Unauthorized- verify your API key is correct and present in thex-api-keyheader.403 Forbidden- the key is valid but not authorized for this terminal. Check you are using the rightterminal_friendly_id.409 Conflict- if the reason code isROUTING/IDEMPOTENCY_CONFLICT, do not retry with the same key and a different body. Generate a newIdempotency-Keyfor a new operation.