Skip to main content

Status Codes

All API endpoints may return a Success, Redirect, or Error status code.

Success

All API endpoints may return the following codes indicating a successful request.

info

A JSON response body may be provided for 2xx level codes. Always verify that the Content-Type HTTP header is application/json before parsing a response as JSON.

StatusNameDescription
200OKThe request succeeded and content is returned.
201CreatedThe request succeeded and a resource has been created.
204No ContentThe request succeeded and there is no content to return.

Redirect

All API endpoints may return the following codes indicating a new endpoint is to be used for the request.

info

A redirect response will not include a response body. Use the URL provided in the HTTP Location header to retry your request.

StatusNameDescription
301Moved PermanentlyThis endpoint has changed permanently - please use the new URL given for all future requests.
302FoundThis endpoint has changed temporarily - please use the new URL given for this request.

Error

All API endpoints may throw the following errors. It is your responsibility to handle these errors appropriately, including retrying requests when needed until they succeed.

info

A JSON response body may be provided for 4xx level codes. A JSON or an HTML response body may be provided for 5xx level codes. Always verify that the Content-Type HTTP header is application/json before parsing a response as JSON.

StatusNameDescriptionResolution
400Bad RequestThe server could not understand the request.Check all body and query parameters and ensure the request is valid.
401UnauthorizedThe request is unauthenticated.Ensure your JWT is valid.
403ForbiddenThe client does not have access rights to this content.Ensure your Partner ID, endpoint, and method are correct.
404Not FoundThe resource was not found.Ensure your Partner ID, endpoint, and method are correct.
405Not AllowedThe request method is not allowed.Ensure your method is correct.
409ConflictThe request conflicts with the current state of the server.Ensure your Partner ID, endpoint, and method are correct. Some resources cannot be modified.
429Too Many RequestsThe users has sent too many requests in the given amount of time (rate limiting).Wait and retry your request.
500Internal Server ErrorThe server has encountered an unexpected error.Wait and retry your request. Contact engineering@abswarranty.net if the issue persists.
502Bad GatewayThe server was unable to communicate with another service.Wait and retry your request. Contact engineering@abswarranty.net if the issue persists.
503Service UnavailableThe server is not ready to handle the request.Wait and retry your request. Contact engineering@abswarranty.net if the issue persists.
504Gateway TimeoutThe server was not able to complete your request in time.Wait and retry your request. Contact engineering@abswarranty.net if the issue persists.

Error Response Body

Some error responses may provide a JSON response body with additional error details. This response may include:

  • error – the name of the error
  • statusCode – the corresponding HTTP status code of the error
  • message – additional information about the error
  • sentryId – a unique ID corresponding to this error event
tip

If the error body includes sentryId please reach out to engineering@abswarranty.net and provide us with this ID. This will help us trace the root cause of the issue and resolve it more efficiently.

warning

Do not rely on the statusCode provided in the response body when handling errors. A JSON response body may not be provided. Instead, use the status code sent in the HTTP response header.

Example Error Responses

{
"error": "unauthorized",
"statusCode": 401,
"message": "Invalid partner token: \"iat\" must be greater than or equal to \"2024-09-18T13:00:21.024Z\""
}
{
"error": "internal server error",
"statusCode": 500,
"sentryId": "d2181cbb8da442adb34ef5e6bb0327ea"
}
<html>
<head><title>502 Bad Gateway</title></head>
<body>
<center><h1>502 Bad Gateway</h1></center>
</body>
</html>