HTTP Status Codes
What is an HTTP status code?
HTTP status codes are a set of standardised codes that are returned by the Peddler API in response to a request. Depending on the response code, the client can determine the success or failure of the request. Peddler API uses the standard HTTP status codes.
Table of HTTP status codes
https://alphadev-api.peddler.com/
Status Code | Response | Description |
---|---|---|
200 | OK | The request has succeeded. |
400 | BAD_REQUEST | The request is invalid, contains missing/invalid parameters. |
401 | UNAUTHORIZED | The request is unauthorised with your current credentials/accessToken. You are using an invalid or non-existent access token. Create a new one. |
403 | FORBIDDEN | The request is forbidden. You do not have permission to access the requested resource. You do not have permission to access the endpoint |
404 | NOT FOUND | The requested resource (instance) is not found. |
422 | UNPROCESSABLE_ENTITY | The request contains validation errors. Details with the errors are available in the response body. |
429 | TOO_MANY_REQUESTS | You have exceeded the rate limit, further requests should back off until the credit pool is replenished. |
498 | TOKEN_EXPIRED | The accessToken has expired you should generate a new one. |
500 | INTERNAL_SERVER_ERROR | No error code assigned, something went wrong, our team has been notified. |
5xx | GATEWAY ERROR or SERVER ERROR | Something went wrong our team has been notified. |
Most common codes experienced by clients
- 200 : The request is successful.
- 401 & 498: You need to renew or refresh your token.
- 422: The parameters/json data contains validation errors
Rate limiting
Peddler API rate limits at 2000 requests per minute (this can be applied/omitted per client by special request to the Peddler team). Should you exceed this rate you will receive a 429 HTTP STATUS.
We recommend throttling your requests, or batching multiple deliveries for any particular store in one order depending on your volume. Once you receive a 429 response you must withold for at least 5 minutes.