Skip to main content
Codex is OpenAI’s terminal agent. Custom providers live in ~/.codex/config.toml, so Triw is a normal provider block with a base URL and an env key.

Requirements

Install

Configure Triw

~/.codex/config.toml
Two details matter:
  • base_url ends with /v1. Codex appends /chat/completions or /responses.
  • env_key names the environment variable; the key itself never lives in the file.
If you only need to redirect the built-in OpenAI provider (no second provider id), Codex also accepts openai_base_url = "https://router.triw.io/v1" at the top level. The explicit provider block above is clearer when you keep both.

Pick a model

Use the exact id in model =. Coding ids usually come from the gpt-5*, codex, or claude-* families, depending on what the operator connected.

Verify

Interactive mode: codex, then /status to confirm provider and model. Cross-check with Logs in the Triw console.

Troubleshooting