diazmelgarejo/orama-system/codex-mcp-debugging
Claude Code and agent skill by diazmelgarejo/orama-system
- community
Checking that the SKILL.md file is still in the repository.
Use when debugging Codex CLI MCP config.toml errors — invalid transport, GitHub MCP, bearer_token_env_var confusion, stdio vs HTTP transport, Exa wrapper setup, or codex mcp list failures. Activates when MCP transport shape or auth field family is wrong.
Install
npx vskill@latest install diazmelgarejo/orama-system/codex-mcp-debuggingSKILL.md
The same SKILL.md was published earlier as diazmelgarejo/orama-system/codex-mcp-debugging.
Codex MCP Debugging
Purpose
Diagnose Codex CLI MCP config.toml transport and auth field mismatches before editing servers.
When to Use
codex mcp listfails withinvalid transportor schema errors- GitHub MCP shows bearer-token fields on a stdio subprocess
- Exa or custom wrappers need stdio verification on OpenClaw machines
Use this before editing ~/.codex/config.toml MCP blocks.
Core Rule
Classify transport before touching auth.
- stdio server: local process; requires
command, optionalargs, and env under
[mcp_servers.<name>.env].
- HTTP server: remote URL; requires
url;bearer_token_env_varbelongs here.
If the error says invalid transport, assume schema mismatch first, not missing credentials.
GitHub MCP Pattern
For the local npm GitHub MCP server, use stdio:
The shell should export CODEX_GITHUB_PERSONAL_ACCESS_TOKEN, preferably from ~/.zshenv for non-interactive shells.
GitHub also documents a remote Streamable HTTP Codex setup at https://api.githubcopilot.com/mcp/. For that remote transport, bearer_token_env_var is valid. Do not mix the two shapes.
Exa MCP Pattern
For OpenClaw machines, Exa is intentionally configured as a stdio wrapper, not the bare remote URL. The wrapper resolves EXA_API_KEY from OpenClaw config or macOS Keychain and multiplexes Claude, orama-system, Perpetua-Tools, and Codex through one local daemon.
Preferred setup:
Expected codex mcp get exa shape:
Smoke-test the wrapper itself when debugging:
Success exposes web_search_exa and web_fetch_exa. A current Codex session may need restart before newly added MCP tools appear in the tool surface.
Antipattern
Do not apply this as the whole fix:
That treats the local npm GitHub server as HTTP bearer-token config, but this GitHub server is a stdio subprocess.
Verification
Run:
Success criteria:
- Config loads without
invalid transport. githubshows commandnpxand args containing@modelcontextprotocol/server-github.- Env shows
GITHUB_PERSONAL_ACCESS_TOKEN=*****. Auth: Unsupportedis acceptable for stdio; it means Codex OAuth is not being used.
Reasoning Checklist
- Read the actual config block before editing.
- Compare fields against the transport schema.
- Move credentials into the correct field family for that transport.
- Validate with the Codex parser and launcher, not by visual inspection.
- Preserve secrets; never paste token values into notes, logs, or skills.
Failure Lesson To Reuse
If a user says Claude fixed a Codex MCP issue that Codex could not, treat that as a signal to run a transport/schema postmortem. The specific failure was reading a GitHub warning as "missing PAT env var" when the real blocker was an invalid MCP transport shape.
Good response pattern:
- Acknowledge the wrong mental model directly.
- Search/check docs for transport-specific fields.
- Mention the remote GitHub HTTP exception where
bearer_token_env_varis valid. - Save the pattern and antipattern.
- Re-run
codex mcp get githuborcodex mcp listbefore declaring success.
References
- `../openclaw-skills/references/openrouter-defaults.md` - model routing source of truth
- `../openclaw-skills/references/universal-skill-protocol.md` - invocation envelope standard
- `../openclaw-skills/references/pt-orama-weave.md` - how PT + orama-system cooperate
Boundaries
Always Do
- Classify transport (stdio vs HTTP) before touching auth fields.
- Validate with
codex mcp listandcodex mcp get <name>after edits. - Preserve secrets; reference env var names only, never token values.
Ask First
- Switching GitHub MCP from stdio npm server to remote HTTP Copilot endpoint.
- Adding new MCP servers that duplicate existing OpenClaw wrapper coverage.
Never Do
- Apply
bearer_token_env_varto stdio subprocess servers. - Paste PATs, API keys, or bearer tokens into skills, logs, or commit messages.
- Declare success without re-running the Codex MCP parser.
Security
- Security scanPassed, 90 of 100Pattern checks on the skill's files.
- Model reviewPassed
Quality evaluation
- Task evaluationNot runNo evaluation yet. Run one in Skill Studio.
Source
- SKILL.md in the repositoryCheckingbin/orama-system/skills/codex-mcp-debugging/SKILL.md
Popularity
- 7-day trend score
- 0
Not refreshed yet.
Works with
Any agent vskill installs to: 56 targets in all. These 39 have a page on this site.
- Claude Code
- Cursor
- GitHub Copilot
- Windsurf
- Codex
- Gemini CLI
- Cline
- Amp
- Roo Code
- Goose
- Continue
- Kilo Code
- Junie
- Trae
- OpenHands
- Qwen Code
- AI Agent
- Tabnine Chat
- Sourcegraph Cody
- Amazon Q
- Firebase Genkit
- Sweep
- Devin
- Phind
- Mentat
- Claude Desktop
- Aider
- GPT Pilot
- Plandex
- bolt.new
- v0
- Replit Agent
- Anse
- TypingMind
- BetterChatGPT
- LibreChat
- Warp AI
- Pieces
- Fig AI
Embed badge
[](https://verified-skill.com/skills/diazmelgarejo/orama-system/codex-mcp-debugging)