Edgee CLI setup (recommended)
The fastest way to connect Codex to Edgee is through the CLI, no config files to edit manually.1
Install the Edgee CLI
- macOS / Linux
- Homebrew (macOS)
- Windows (PowerShell)
2
Launch Codex through Edgee
Choose how you want to launch. Both options route requests through Edgee.If you are not signed in, Edgee starts sign-in automatically at launch. Follow the prompts and select your organization when asked.The CLI authenticates, writes the Codex config, and starts Codex, all in one command. Token compression is enabled automatically.
- With aliases (recommended)
- Without aliases
With aliases installed in the previous step, use your usual command:The alias runs
edgee launch for you, so requests go through Edgee.Manual setup (advanced)
Get your coding-agent key
Manual setup uses the key of your enrolled Codex agent, not a standard API key created for LLM Router applications.- Open the Edgee Console and select your organization.
- In the header, click Set up coding agent or +, select Codex, and click Enroll. If your agent is already enrolled, use its existing icon.
- Click the agent’s icon, then Advanced settings → Advanced.
- Under Edgee API key (for manual setup), click Reveal key, then the copy icon.
<YOUR_CODING_AGENT_KEY>.
Configure Codex
If you prefer to configure Codex without the CLI, update your Codex configuration file at~/.codex/config.toml:
Replace
<YOUR_CODING_AGENT_KEY> with the coding-agent key copied above.
Manage token compression from the Codex icon in the console header.Usage
Keep launching through Edgee so the request uses your configured gateway:codex command routes through Edgee only if you have installed an alias.