API error · HTTP 401
invalid_token
Access token is invalid
| HTTP status | 401 Unauthorized |
|---|---|
code | invalid_token |
title | Access token is invalid |
| Retry? | Refresh the token once |
What it means
The Authorization: Bearer … token is missing, malformed, unknown or revoked.
What to do
Get a new token once and retry the call once. If it fails again, stop and alert: the credential may have been revoked (§12.4).
Example response
Branch on code, never on title or detail. detail varies; quote request_id to support.
HTTP/1.1 401 Unauthorized
Content-Type: application/problem+json
{
"type": "https://www.underwritinguk.ai/developers/errors/invalid_token",
"title": "Access token is invalid",
"status": 401,
"code": "invalid_token",
"detail": "Access token is invalid.",
"request_id": "7b0b1e5c-2f7e-4a52-9a43-5b0d0f0e9d11"
}All error codes · Error catalogue in the integration guide (§15) · Error handling and retries (§12.4)