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

# Authentication

> Authenticate OmniaKey API requests with one prepaid API key across OpenAI, Anthropic, and Gemini protocols.

Every OmniaKey API request uses an API key from the
[API Keys dashboard](https://omniakey.com/dashboard/tokens).

## Bearer token

The universal form is an Authorization header:

```bash theme={null}
Authorization: Bearer your-omniakey-api-key
```

Use this form for cURL, OpenAI-compatible clients, and most custom integrations.

## SDK conventions

Official SDKs use different auth conventions. OmniaKey accepts the common forms
for the protocol being called.

| SDK or protocol | Auth form                                              |
| --------------- | ------------------------------------------------------ |
| OpenAI SDK      | `api_key` / `Authorization: Bearer`                    |
| Anthropic SDK   | `api_key` / `x-api-key`                                |
| Gemini SDK      | `api_key` / `x-goog-api-key` / `?key=` query parameter |

For custom integrations, prefer `Authorization: Bearer`. It works consistently
across all documented endpoints.

## Keep keys scoped

Create separate keys for local development, CI, and shared team workflows. This
makes it easier to rotate a compromised key and set per-key spending caps.

## Common auth errors

| Status | Meaning                               | Fix                                       |
| ------ | ------------------------------------- | ----------------------------------------- |
| `401`  | Missing, inactive, or invalid key     | Create or rotate the key in the dashboard |
| `403`  | Key cap or account balance is too low | Raise the key cap or top up balance       |
