Simple setup scripts to configure Codex CLI with a patched codex-mcp-server
until upstream PR tuannvm/codex-mcp-server#94 merges.
- Codex CLI installed and in your PATH
- Your Codex API configuration set up (run
codexonce to configure) - Git + Node.js (only required while the PR is unmerged)
git clone https://github.com/Flewrider/codex-multiagent-setup.git
cd codex-multiagent-setupWindows (CMD/PowerShell):
setup.cmdmacOS/Linux/Git Bash/WSL:
chmod +x setup.sh
./setup.shJust run:
codexYour Codex instance will pick up the MCP server from ~/.codex/config.toml.
The setup script configures Codex to use a patched MCP server while PR
tuannvm/codex-mcp-server#94 is unmerged. It checks the PR status and:
- If merged, configures the upstream package via
npx -y codex-mcp-server - If not merged, clones
Flewrider/codex-mcp-serverto~/.codex/codex-mcp-serverand uses the localdist/index.jsbuild
The resulting MCP config values look like:
[mcp_servers.codex_worker]
command = "npx"
args = ["-y", "codex-mcp-server"]
startup_timeout_sec = 30
tool_timeout_sec = 300When using the forked build, the command is node with a local dist/index.js
path instead.
Make sure Codex CLI is installed and in your PATH:
npm install -g @openai/codex
# or
codex --versionCheck that the tuannvm MCP server runs:
npx -y codex-mcp-server --helpIf this errors, update Node.js/npm and ensure Codex CLI is installed.
If MCP servers still don't show up on Windows, ensure CODEX_HOME is set:
setx CODEX_HOME "%USERPROFILE%\.codex"Then restart your terminal and retry codex mcp list.
MIT