# Error Handling

All successful requests to the API return an HTTP 200 or 201. In case of errors, the API returns a JSON response containing the error code and details about the error:

```json
{
  "errors": [
    {
      "error-description": "Price Group cannot be null or empty",
      "error": "Price group must contain an id"
    }
  ]
}
```

The format of the error description varies between error codes.

The following combinations of error codes are returned from the API:

<table><thead><tr><th width="112">HTTP</th><th>Description</th><th>Handling</th></tr></thead><tbody><tr><td>400</td><td>Invalid input provided. See details.</td><td>Check that the input sent is correct.</td></tr><tr><td>401</td><td>Incorrect Client ID and/or Client Secret in HTTP header or Access Token invalid.</td><td></td></tr><tr><td>403</td><td>The authentication token does not have access to this endpoint.</td><td></td></tr><tr><td>404</td><td>A resource with the supplied ID was not found in the current store.</td><td>Try with an existing resource.</td></tr><tr><td>500</td><td>Unknown error.</td><td>Not retryable.</td></tr><tr><td>504</td><td>Gateway time out.</td><td>Call can be retried.</td></tr></tbody></table>
