Connect Codex to Chorus
June 3, 2026 · View on GitHub
This guide walks through connecting the Codex CLI to a running Chorus instance. Codex has its own standalone Chorus plugin (under plugins/chorus, published via .agents/plugins/marketplace.json) — a separate package from the Claude Code plugin, with its own set of skills and supported features. A one-shot installer takes care of wiring it into Codex's ~/.codex/config.toml.
Tip: The in-app setup wizard at Settings → Setup Guide → Open setup guide walks you through the same steps interactively, including API-key creation. Use this doc if you prefer a reference you can read end-to-end or automate.
Prerequisites
- Chorus instance running and reachable (e.g.
http://localhost:8637or a deployed URL) codexCLI installed (npm i -g @openai/codex)- A Chorus API Key (create one in the Web UI under Settings → Agents → Create API Key). Keys start with
cho_.
Step 1: Export environment variables
export CHORUS_URL="http://localhost:8637"
export CHORUS_API_KEY="cho_your_api_key"
Add these to
~/.bashrcor~/.zshrcif you want them to persist across shells.
Step 2: Run the installer
curl -fsSL "$CHORUS_URL/install-codex.sh" | bash
The script is idempotent and safe to re-run. It will:
- Verify
codexis installed. - Register the
chorus-pluginsmarketplace (or upgrade it if already registered). - Write
[mcp_servers.chorus]and[plugins."chorus@chorus-plugins"]into~/.codex/config.toml(mode600, backing up your original once toconfig.toml.chorus-bak). - Enable Codex lifecycle hooks with
[features] hooks = true. Chorus hooks are bundled in the plugin and load automatically after the plugin is installed/enabled.
If CHORUS_URL / CHORUS_API_KEY aren't set, the installer will prompt for them interactively (provided you have a TTY).
Step 3: Verify the connection
Open Codex and type:
check in to chorus
Codex will call chorus_checkin() via the MCP server and report back with your agent identity, permissions, and recent activity. The Chorus workflow skills ($chorus, $develop, $proposal, $yolo, etc.) are also available.
Non-interactive install (CI / sandboxed environments)
The installer runs fine without a TTY as long as both vars are in the environment:
CHORUS_URL=https://chorus.example.com \
CHORUS_API_KEY=cho_xxx \
bash <(curl -fsSL https://chorus.example.com/install-codex.sh)
Troubleshooting
codex not found in PATH— Install it:npm i -g @openai/codex.401 Unauthorizedoncheck in— API key wrong or revoked. Recreate under Settings → Agents, then re-run the installer (or edit theAuthorizationline inconfig.toml).URL must start with http:// or https://—CHORUS_URLmissing the scheme. Usehttp://orhttps://.- Marketplace source conflict — You previously registered
chorus-pluginsfrom a different URL. The installer detects this and auto-re-registers; check the!warnings it prints. - Hook didn't fire on first launch — Open
/pluginsinside Codex and confirmchorus@chorus-pluginsis installed/enabled, then open/hooksto review/trust the bundled Chorus hooks. Hooks run after the plugin cache is materialized.
Next
- Skill docs (tools reference):
plugins/chorus/skills/chorus/SKILL.md(the standalone version served as/skill/chorus/SKILL.mdon your Chorus instance comes frompublic/skill/chorus/SKILL.md) - Workflow overview: run
$chorusinside Codex - To connect Claude Code instead, see CONNECT_CLAUDE_CODE.md
- For any other MCP-capable agent (Cursor, Continue, custom, etc.), see CONNECT_OTHER_AGENTS.md