data,
errors, or both. Always inspect the errors array, even when the HTTP status
is 200.
Error shape
extensions. Branch on code, not on
message.
Common cases
A record that does not exist is returned as
null, not as an error.
Authentication failures are deliberately uniform. A bad header, an unknown
token, a nonexistent store, and a token that belongs to another store all
return
{ "errors": [{ "message": "Unauthorized" }] }, so they cannot be told
apart.Handling throttling
When you receive aTHROTTLED error, wait the number of seconds given in the
Retry-After header before retrying, and consider lowering query cost by
requesting smaller pages or fewer fields. See
Rate limiting.