Codex CLI
Codex speaks the OpenAI Responses API, which Inert serves at https://api.inert.lol/v1/responses. A custom provider entry and one env var are enough, with no proxy in between.
Config
In ~/.codex/config.toml:
model = "fable-5"
model_provider = "inert"
[model_providers.inert]
name = "inert"
base_url = "https://api.inert.lol/v1"
wire_api = "responses"
env_key = "INERT_API_KEY"Then set INERT_API_KEY in your environment. Models are fable-5 and opus-5, the same IDs GET /v1/models returns.
Startup warning
Every session prints one warning at startup:
Model metadata for 'fable-5' not found. Defaulting to fallback metadataHarmless. Codex ships a built-in catalog of OpenAI model IDs and does not know Inert's aliases, so it falls back to generic metadata. Nothing needs fixing.
Tools
Regular function tools all work: shell, plan, apply-patch and the rest. Codex also sends its built-in web_search and multi-agent (namespace) tools unconditionally; the gateway accepts the request and skips those definitions, so the model never sees them.
Non-interactive runs
codex exec blocks reading stdin outside a TTY, so redirect it in scripts and CI:
codex exec "summarize this repo" < /dev/nullStatelessness
Inert stores nothing between requests, so previous_response_id is rejected. Codex already resends the full conversation on every turn against a custom provider, so multi-turn sessions work unchanged. Prompt caching still applies, so cached_tokens shows up in the usage of a repeated prefix.
Next steps
- Claude CodeThe flagship, and a native Anthropic client.