2XX
range indicate success, codes in the 4XX
and 5XX
range indicate failure.
HTTP status codes that can be returned by the Procuros API:
HTTP Status Code | Meaning |
---|---|
400 - Bad Request | There was an issue with the request sent, such as a duplicate payload was sent. |
401 - Unauthorized | The API token is missing or invalid. |
403 - Forbidden | The API token doesn’t have permission to perform this action. |
404 - Not Found | The requested entity (e.g. Transaction) could not be found. |
422 - Validation Failed | The request data is invalid. Responses contain errors that show what field failed validation and why. |
429 - Too Many Requests | You are calling the API too much. Check if you can use our bulk endpoints, otherwise contact support to get your rate limit increased. (won’t happen to >99% of customers) |
500, 502, 503, 504 - Server Error | An error occurred on Procuros side (rare cases) |
Property | Type | Description |
---|---|---|
message | string | Short error descriptions |
errors | object | (Only on 422 “Validation Failed” Errors) Map of fields that failed validation including the corresponding validation error |
4xx
range responses will always include the message
property. For example in the case of a 400
, the message
property will give you the reason why in English.
422
), responses include an additional property errors
, which list all request fields that failed validation and why.
Example:
errorType
to: DATA
.errorReason
to: The GTIN/EAN :gtin couldn't be found
and set up the gtin variable accordingly