OpenAI Codex · tool · fg-0499

Codex fails to load its config when a model provider still sets wire_api = "chat"

If you see failed to load Codex config, and codex doctor reports config could not be loaded, the cause and the fix for OpenAI Codex are below, last verified 2026-10-15.

Verified Oct 2026trust 50/100
Symptom
failed to load Codex config, and codex doctor reports config could not be loadedA Chat Completions-only proxy that worked before stops working after a Codex upgradeThe failure happens even when the provider entry is unused
Cause
Current Codex releases support only Responses API endpoints for custom providers; wire_api chat and Chat Completions-only gateways are no longer accepted.
Fix
Point the provider at a Responses-compatible endpoint with wire_api responses, put a Responses-compatible gateway in front of the old one, or delete the stale provider entry.
Apply
[model_providers.proxy] name = "Company proxy" base_url = "https://proxy.example.com/v1" wire_api = "responses"
Affected
Codex CLI 0.59 and later dropped chat for most uses; config load failure reported on 0.151.0; as of 2026-10
Sources

Last verified 2026-10-15 · Confirmed by 0 builders

Related traps

Have your agent know this before it fails

$ /plugin marketplace add getfootgun/footgun
$ /plugin install footgun@footgun