Errors
Learn how to handle PandaScore REST API errors.
PandaScore uses HTTP response status codes to indicate the failure or success of your requests. When a request fails, PandaScore returns an appropriate error code.
The status codes fall under three categories:
200success — the request worked as expected4xxerror — the request failed because of the provided parameters5xxerror — the request failed because of an error on PandaScore' servers
Client errors
Status codes within the 4xx range refer to client errors. They occur when something is wrong with the request. Consequently, most of these errors should only happen to you during development phase.
| HTTP Status | Definition |
|---|---|
| 400 — Bad Request | Malformed request. Most likely a syntax error with the query parameters. |
| 401 — Unauthorized | Missing token. See Authentication. |
| 403 — Forbidden | Requested URL is not available with your plan. See Coverage. |
| 404 — Not Found | Resource does not exist. |
| 429 — Too Many Requests | You've reached your plan's rate limit. |
In case of client errors, PandaScore sends a JSON response that provides information on the error. It contains the following attributes:
error: is a unique identifier for the errormessage: is a human-readable message that can be displayed to your users or output to your logs
Example
HTTP Status: 404
{
"error": "Not Found",
"message": "The resource does not exist."
}If you receive a 403 Forbidden error, it means the endpoint or field you are trying to access is not included in your current plan. Each endpoint in our API Reference indicates the minimum plan required. Some individual fields within an endpoint response may only be populated on higher plans. For example, weapon_kills in CS2 player statistics is only available on the Pro Live plan. Check the field descriptions in the API Reference for plan requirements.
Server errors
Status codes within the 5xx range refer to server errors. These only happen because of issues on PandaScore's servers and should be rare.
If a request fails with a 5xx status, you should give it another go. API downtimes are often short, so there is a good chance that the request succeeds the next time. If the problem persists, check our status page or contact our support.
Updated 20 days ago
