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

# Use in Codex

> Integrate AnyFast AI models with Codex — the AI coding agent in your terminal.

## 1. Install Codex

Install Codex from the [Codex CLI GitHub](https://github.com/openai/codex).

## 2. Configure AnyFast

In your shell profile (`.bashrc`, `.zshrc`, or `.profile`):

```bash theme={null}
export OPENAI_API_KEY="sk-your-api-key-here"
export OPENAI_BASE_URL="https://www.anyfast.ai/v1"
```

## 3. Apply Configuration

```bash theme={null}
# bash users
source ~/.bashrc

# zsh users
source ~/.zshrc
```

## 4. Start Codex

```bash theme={null}
codex
```

Specify a model via CLI:

```bash theme={null}
codex --model gpt-4o
```

You are now ready to use AnyFast models in Codex.<script src="/feedback.js" />
