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

# Authentication

> Authenticate to the Icelake API with Bearer API keys.

The Icelake API uses **Bearer API keys**. Create and revoke keys in the app under **Settings → API keys**.

```bash theme={null}
Authorization: Bearer ICELAKE_API_KEY
```

<Warning>
  Keep keys secret. Do not embed them in client-side web apps or public repositories. Prefer server-side usage and environment variables.
</Warning>

## Base URL

```text theme={null}
https://chat.icelake.io/api/v1
```

The multi-zone front door also works:

```text theme={null}
https://icelake.io/api/v1
```

## Scopes

Keys may include:

| Scope    | Access            |
| -------- | ----------------- |
| `chat`   | Chat completions  |
| `images` | Image generations |
| `models` | List models       |

## Managing keys

| Action                   | How                                                                 |
| ------------------------ | ------------------------------------------------------------------- |
| Create / list / revoke   | Signed-in user in **Settings → API keys**                           |
| Programmatic create/list | `GET/POST /api/v1/api-keys` with a **session JWT** (not an API key) |

API keys cannot manage other keys — that requires a logged-in session.

## Errors

Invalid or missing keys return an OpenAI-style error:

```json theme={null}
{
  "error": {
    "message": "Invalid API key",
    "type": "authentication_error",
    "code": "invalid_api_key",
    "param": null
  }
}
```
