@h0wzy/mcp-server-codex
v1.0.7
Published
OpenAI Codex MCP Server connecting any MCP client to OpenAI Codex (GPT-6)
Maintainers
Readme
🤖 @h0wzy/mcp-server-codex
High-performance OpenAI Codex MCP Server connecting any Model Context Protocol client (such as Claude Code, Google Antigravity, or custom agents) to OpenAI's GPT-6 models (default gpt-6-astra).
Part of the H0wZy/mcp multi-agent ecosystem.
🔌 Available Tools
| Tool Name | Parameters | Description |
| :--- | :--- | :--- |
| configure_codex | action (get | set | reset | list), tier, model, effort (all optional) | Inspect or change the session's model and reasoning effort; tiers light / balanced / deep. |
| ask_codex | prompt (string), paths, model, effort (optional) | Independent second opinion or general question for OpenAI Codex. Runs in the read-only sandbox. |
| review_codex | prompt (string), paths, model, effort (optional) | Structured code review with your focus areas. |
| brainstorm_codex | prompt (string), paths, model, effort (optional) | Architectural alternatives, trade-offs and a recommendation. |
| plan_codex | prompt (string), paths, model, effort (optional) | Dependency-ordered implementation plan with file paths and test steps. |
| delegate_codex | prompt (string), cwd (string), paths (string[], optional), model, effort (optional), timeout_minutes (number, 1-60, default 30) | Edits files inside cwd (workspace-write sandbox). Hand a self-contained implementation task to Codex and get its final report. Review the diff afterwards. |
delegate_codexwrites to disk and never commits. Review the diff (git diff) before keeping its changes.
Loop guard (spec 006). Every task tool goes through the shared loop guard before the agent starts. Each reply ends with a trace line such as
[chain claude→codex · depth 1/2 · calls 1/8 · run a1b2c3d4], and calls that would loop are refused with⛔ [Loop guard: …].hmcp installadds--host <agent>to the launch arguments so the guard knows which agent is calling.
🚀 Installation & Usage
1. Automated Setup via hmcp CLI (Recommended)
The easiest way to install and register this bridge into Claude Code or Google Antigravity:
# Install globally or per-project
hmcp install claude-codex --scope user2. Standalone Execution via npx
You can run the server directly with zero prior setup:
npx @h0wzy/mcp-server-codex3. Manual Configuration
In Claude Code (~/.claude.json):
{
"mcpServers": {
"codex": {
"command": "npx",
"args": ["-y", "@h0wzy/mcp-server-codex"]
}
}
}Or using local source:
{
"mcpServers": {
"codex": {
"command": "node",
"args": ["<path-to-mcp>/servers/codex/bin/cli.js"]
}
}
}🛡️ Requirements & Resilience
- OpenAI Codex CLI (
codex): Must be installed and authenticated on your system. - Cross-Platform: Automatically locates
codex.cmd(Windows) orcodex(macOS/Linux) via native PATH resolution. - Rate Limit & Quota Resilience: Gracefully traps HTTP 429 and rate-limit errors, returning structured fallback responses rather than crashing the client session.
- Privacy & Security: Built-in credential redaction proactively masks API keys, OpenAI tokens (
sk-...), and authorization headers from error messages. - Lean sessions: the Codex it starts loads only the H0wZy/mcp bridges from your
config.toml. Every other MCP server is switched off for that run (-c mcp_servers.<name>.enabled=false), which cut a one-line answer from 37 s to 13 s on a real setup.H0WZY_MCP_USER_SERVERS=1keeps your servers.
📄 License
Created by Marcos (H0wZy) under the MIT License.
Full documentation and repository: 👉 H0wZy/mcp
