Error format
typeis the broad category.codenames the specific problem where there is one, otherwise it isnull.messageis a human-readable description. Do not parse it; branch ontypeandcode.
Common errors
Retrying
Retry5xx responses with exponential backoff. Do not retry 400 or 401 unchanged: they fail the same way until the request or key is fixed. A 429 with budget_exceeded succeeds again only after credit is added.