Integrations

Codex CLI

Add a custom provider in config.toml.

Edit ~/.codex/config.toml (on Windows: %USERPROFILE%\.codex\config.toml):

config.toml
model = "deepseek-v4.1-flash-heretic"
model_provider = "relay"

[model_providers.relay]
name = "GeniusRelay"
base_url = "https://api.geniusrelaygpt.com/v1"
env_key = "RELAY_API_KEY"
wire_api = "chat"

Then set the environment variable and start Codex:

shell
export RELAY_API_KEY=sk-your-key
codex

In Windows PowerShell use $env:RELAY_API_KEY="sk-your-key".