Before you begin
Create a key on the API Keys page, confirm the model ID on the Models page, and export the key in the shell where you start Codex or its local proxy.wire_api = "chat" is rejected at startup, and
responses is the only accepted value, so Codex reaches LithosAI through a proxy that
accepts Responses API requests.
1
Install LiteLLM
LiteLLM bridges the Responses API to Chat Completions.
2
Configure the proxy
Give the model the
openai/ prefix and set use_chat_completions_api, which bridges
incoming /v1/responses requests to LithosAI’s /v1/chat/completions.codex.litellm.yaml
drop_params discards parameters a model does not accept rather than failing the
request. additional_drop_params removes reasoning_effort: Codex asks for a reasoning
summary, LiteLLM forwards that request in this field in a form LithosAI rejects, and
Codex works without it. master_key is the token Codex sends to the proxy, not your
LithosAI key.3
Start the proxy
127.0.0.1 and do not expose it to a network.4
Point Codex at it
~/.codex/config.toml
env_key names the variable holding the proxy’s master_key, so export that too.Troubleshooting
Issues common to every agent are listed under Common issues.