> ## 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.

# Coding Agents

> Point Claude Code, Cursor, Cline, aider, and Codex at OmniaKey

Each tool keeps the protocol it already speaks — you only change the base URL and
key. Get a key from the [Dashboard](https://omniakey.com/dashboard/tokens) first. Pick
any model id from [Models](/en/models).

## Claude Code

Claude Code uses the Anthropic protocol, so its base URL is the bare host
`https://api.omniakey.com`.

<CodeGroup>
  ```bash macOS / Linux theme={null}
  export ANTHROPIC_BASE_URL="https://api.omniakey.com"
  export ANTHROPIC_AUTH_TOKEN="your-omniakey-api-key"
  claude
  ```

  ```powershell Windows (PowerShell) theme={null}
  $env:ANTHROPIC_BASE_URL = "https://api.omniakey.com"
  $env:ANTHROPIC_AUTH_TOKEN = "your-omniakey-api-key"
  claude
  ```
</CodeGroup>

Switch models inside Claude Code with `/model` (e.g. `claude-opus-4-8`).

## Codex

Codex uses OpenAI-compatible Responses traffic. Add a provider in
`~/.codex/config.toml`:

```toml theme={null}
model = "gpt-5.5"
model_provider = "omniakey"

[model_providers.omniakey]
name = "OmniaKey"
wire_api = "responses"
requires_openai_auth = true
base_url = "https://api.omniakey.com/v1"
```

```bash theme={null}
export OPENAI_API_KEY="your-omniakey-api-key"
codex
```

## Cursor

In **Settings → Models → API Keys**, enable **OpenAI API Key**, paste your key,
and set **Override Base URL** to `https://api.omniakey.com/v1`. Add model ids such
as `claude-opus-4-8` or `gpt-5.5`.

## Cline

Choose the **OpenAI Compatible** provider:

* **Base URL:** `https://api.omniakey.com/v1`
* **API Key:** your OmniaKey key
* **Model ID:** e.g. `claude-opus-4-8`

## aider

```bash theme={null}
export OPENAI_API_BASE="https://api.omniakey.com/v1"
export OPENAI_API_KEY="your-omniakey-api-key"

aider --model openai/claude-opus-4-8
```

## Gemini CLI

Gemini CLI authenticates through your Google account and **doesn't expose a
setting to point at a third-party base URL** — the request to add one was
[closed as not planned](https://github.com/google-gemini/gemini-cli/issues/1679).
You can't route Gemini CLI itself through OmniaKey today.

To use **Gemini models through OmniaKey**, reach them over the OpenAI-compatible
endpoint from any tool or SDK above — only the model id changes:

```bash theme={null}
export OPENAI_API_BASE="https://api.omniakey.com/v1"
export OPENAI_API_KEY="your-omniakey-api-key"

aider --model openai/gemini-3.1-pro-preview
```

The same holds for Cursor, Cline, Codex, and the OpenAI SDK: keep the `/v1` base
URL and set the model to `gemini-3.1-pro-preview` or `gemini-3-flash-preview`.
See [Models](/en/models) for the full Gemini lineup.

## Troubleshooting

* **401 / auth errors** — confirm the key is active in the [Dashboard](https://omniakey.com/dashboard/tokens).
* **Wrong base URL** — match the protocol your tool speaks: bare host `https://api.omniakey.com` for Claude Code (Anthropic), `https://api.omniakey.com/v1` for OpenAI-compatible tools, `https://api.omniakey.com/v1beta` for the Gemini-native SDK. A `404` on a path like `/v1/messages` usually means the suffix is wrong for the protocol.
* **Unknown model** — copy the exact id from [Models](/en/models); ids are case-sensitive.
* **Requests rejected** — check the key's spending cap and your balance in the [Dashboard](https://omniakey.com/dashboard).
