API Reference

Status codes

Like all RESTful APIs, we use HTTP status codes to indicate the success or failure of each request made. The codes we use are the standard ones, as documented on for example httpstatus.es.

Here’s a quick reference of some of the more important codes you might see.

C o d e Description
2 0 0 Success. Request completed. The response body will in many cases contain the updated resource.
2 0 1 Success. A new resource was created. The response body will in many cases contain the created resource.
2 0 4 Success. No content to return.
4 0 0 Bad Request. The request could not be parsed or had contradictory or invalid data.
4 0 1 Unauthorized. User is not logged in or not allowed to access resource or affect the resource.
4 0 4 Not Found. Resource doesn’t exist.
4 0 9 Conflict. Resource already exists.
4 2 9 Rate limit exceeded. Try again later.
5 0 0 Server error.

Content type

We both accept and respond with JSON for all calls made to the API (except shipping documents, which uses multipart/form-data requests for file uploading).