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

# Authentication

> Workspace API keys, sent as a Bearer token.

Send your key on every request:

```
Authorization: Bearer <key>
```

The key decides the workspace. There is no workspace header.

## Keys

* Create and revoke keys in **Settings → API keys**. Only owners and admins can.
* A key acts with admin reach across the workspace. It can read every conversation, send replies and start operations that spend credits.
* A workspace can hold several keys. To rotate one: create a new key, deploy it, then revoke the old one.
* Expiry is optional. A revoked or expired key stops working on its next request.
* The workspace needs an active subscription or trial. Without one, requests return `402 subscription_required`.

## Keep keys on the server

The API is for server-to-server use. It sends no CORS headers, so a browser cannot call it. Never ship a key in a web page or a mobile app.

## Failures

| Status | Code | Meaning |
| - | - | - |
| 401 | `unauthorized` | The key is missing, wrong, revoked or expired. |
| 402 | `subscription_required` | The workspace has no active subscription. |
| 503 | `service_unavailable` | We could not check the key. Your key is fine: retry after the `Retry-After` delay. |


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