Error Handling

Adi Heymann -

In case of an error, the API server returns a JSON object when possible. For example:

{

"status": "error",

"message": "The error message"

}

The response always includes the relevant headers (described in the table below).

Code

Text

Used when...

200

OK

Success.

304

Not Modified

Cached response.

400

Bad Request

Invalid Request, along with a JSON error message  that provides more details.

401

Unauthorized

The request didn’t follow the authorization flow and does not have a valid Authorization header.

403

Forbidden

The request is valid, but access is denied. This can happen when a request is outside the scope of the authorized API.

404

Not Found

The requested URI is invalid or the requested resource doesn’t exist (for example, an unknown player ID, or vast ID).

410

Gone

The requested version is no longer supported.

429

Too Many Requests

The client has reached its request limits.

500

Internal Server Error

An unknown server error has occurred; contact support.

502

Bad Gateway

The API server is down for maintenance.

503

Service Unavailable

The API server is up, but under too much stress. Try again later.

Have more questions? Submit a request

0 Comments

Article is closed for comments.