Codex
Codex CLI lets you register a custom OpenAI-compatible provider in ~/.codex/config.toml. Add Routeplane as that provider and Codex routes through the whole registry instead of only OpenAI.
Prerequisites
Section titled “Prerequisites”-
Routeplane running — local proxy at
http://127.0.0.1:4356. Routeplane Cloud is on the Phase D roadmap and not yet shipping; for now, self-host with your own provider keys. -
Codex installed:
Terminal window npm install -g @openai/codex
Point Codex at Routeplane
Section titled “Point Codex at Routeplane”Add a provider block to ~/.codex/config.toml. The base_url includes /v1 — Codex appends the route (/chat/completions) itself.
model = "openai/gpt-4o"model_provider = "routeplane"
[model_providers.routeplane]name = "Routeplane"base_url = "http://127.0.0.1:4356/v1"wire_api = "chat" # Chat Completions; use "responses" to target /v1/responsescodexPick a model
Section titled “Pick a model”The model field takes any registry id in provider/model form — openai/gpt-4o, anthropic/claude-sonnet-4-6, google/gemini-2.5-pro — optionally with a :cost or :latency variant. Override per run with codex --model <id>. See Models.
Verify
Section titled “Verify”Run codex and issue a prompt; check the routeplane-served-by response header to see which provider answered.