> ## Documentation Index
> Fetch the complete documentation index at: https://docs.pinakelai.com/llms.txt
> Use this file to discover all available pages before exploring further.

# API key revoked

> HTTP 401, key-revoked. The key was valid but has been revoked or replaced.

| | |
| - | - |
| Type | `https://docs.pinakelai.com/errors/key-revoked` |
| Status | 401 |
| Retry | No. Use a current key. |

## When it happens

The key was revoked by Pinakel, for example when an agreement ended, or replaced when someone rotated it in the customer portal. Revocation takes effect within about a minute.

## What to do

Use the current key; rotated keys are shown in the customer portal at [portal.pinakelai.com](https://portal.pinakelai.com) when they are created. If you did not expect the revocation, contact [support@pinakelai.com](mailto:support@pinakelai.com).

## Example

```http Headers theme={null}
HTTP/1.1 401 Unauthorized
Content-Type: application/problem+json
WWW-Authenticate: Bearer realm="api.pinakelai.com", error="invalid_token"
```

```json Body theme={null}
{
  "type": "https://docs.pinakelai.com/errors/key-revoked",
  "title": "API key revoked",
  "status": 401,
  "detail": "This API key has been revoked.",
  "request_id": "req_01M7Q40E5F6G7H8J9KMNPQRSTV"
}
```

See the [errors catalogue](https://docs.pinakelai.com/api-reference/errors.md) for every error type, and [Handling errors](https://docs.pinakelai.com/guides/errors.md) for retry strategy.


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.