Skip to content

Error Handling

HTTP Status Codes and JSON Fields

All of Manheim's modern APIs return standard HTTP status codes and, as appropriate, JSON objects with additional information in fields such as message and developerMessage.

The following table lists some of the more common HTTP codes that may be returned, along with the standard description that applies beyond the context of Manheim's APIs.

CodeDescription
2XXSUCCESS
200OK
201Created
202Accepted
204No Content
--
4XXCLIENT ERROR
400Bad Request
401Unauthorized
403Forbidden
404Not Found
406Not Acceptable
415Unsupported Media Type
--
5XXSERVER ERROR
500Internal Server Error

The detailed meaning of each return code will vary depending on the specific method being called.

Details on return codes for a specific API and its endpoints can be found in the API Reference page for that API.

Examples

Suppose an API consumer attempted to retrieve an inventory unit using an ID that did not correspond to any unit currently in the system. The system would return the following 404 NOT FOUND error and JSON object.

404
X-Manheim-Media-Type: manheim.v1
{
  "errors": [
    {
      "property": "",
      "message": "Unit not found.",
      "developerMessage": "Resource Unit not found."
    }
  ]
}

If an API consumer attempted to update an inventory unit by changing a field that cannot be updated, the system would return the following 400 BAD REQUEST error and JSON object. The property field in the returned JSON object indicates which field in the original JSON object caused the error.

400
X-Manheim-Media-Type: manheim.v1; format=json
{
  "errors": [
    {
      "property": "Type",
      "message": "Can not update Type field for Unit",
      "developerMessage": "Can not update Type field for Unit"
    }
  ]
}

Manheim is the world's largest provider of vehicle remarketing services