Connect Codex
Connect Codex
Section titled “Connect Codex”Codex supports two native sign-in modes: OpenAI API (api) and ChatGPT (chatgpt). Sign in through Codex first. CMX leaves its native credentials with Codex.
codex logincmx setup --ask-connect-readycmx providers codex listIf you declined the setup prompt, choose the mode that matches your Codex sign-in:
cmx providers codex connect api# or, for a ChatGPT sign-in:cmx providers codex connect chatgptUse one mode at a time. CMX updates Codex’s config.toml (normally ~/.codex/config.toml; CODEX_HOME is supported) and starts the gateway if needed. Restart Codex, send a request, and check cmx stats. cmx harness verify checks whether Codex points at a running gateway.
Return to Codex directly
Section titled “Return to Codex directly”cmx providers codex disconnect api# Substitute chatgpt if that was the connected mode.You can also run cmx harness disable codex. Restart Codex afterward. cmx stop restores direct settings while stopping the gateway; a later cmx start can reconnect previously selected routes. An explicit disconnect or disable is the way to stay direct.
If cmx providers codex list says credentials are missing, complete Codex’s native sign-in. For API-key mode, use Codex’s supported key input or an environment variable; never paste keys into CMX config or support messages. See Troubleshooting.
