Codex 0.20.0 fails to convert several MCP tools (JSON Schema parsing): integer unsupported, union types rejected, and missing type — Obsidian MCP server
What version of Codex is running?
codex-cli 0.20.0
Which model were you using?
GPT-5
What platform is your computer?
- Windows 11 • PowerShell 7 (x64) - WSL2 (Debian 2) • bash
What steps can reproduce the bug?
Summary
On Codex 0.20.0, MCP tool discovery fails for 3 tools exposed by the cyanheads/obsidian-mcp-server. The exact same server lists 8/8 tools and works in other clients (e.g., Gemini CLI). Codex logs show schema-conversion errors during tools/list and hides those tools.
Environment
- Client: Codex CLI
codex-cli 0.20.0 - Node/npm:
v22.13.1/11.5.2 - MCP server:
cyanheads/obsidian-mcp-server(Docker) - OS / shells tested (same result)
- Windows 11 • PowerShell 5.1
- Windows 11 • PowerShell 7 (x64)
- WSL2 (Ubuntu) • bash
- Config: standard
~/.codex/config.tomlwith a[mcp_servers.obsidian]entry invoking the Docker image (same invocation used by Gemini CLI)
Expected
All 8 tools from the Obsidian MCP server are visible and callable from Codex (including obsidian_global_search, obsidian_list_notes, obsidian_manage_frontmatter).
Actual
Codex hides 3 tools and logs conversion errors on startup:
2025-08-11T23:51:01.117396Z ERROR Failed to convert "obsidian__obsidian_global_search" MCP tool to OpenAI tool: Error("unknown variant `integer`, expected one of `boolean`, `string`, `number`, `array`, `object`", line: 0, column: 0)
2025-08-11T23:51:01.117515Z ERROR Failed to convert "obsidian__obsidian_list_notes" MCP tool to OpenAI tool: Error("invalid type: sequence, expected variant identifier", line: 0, column: 0)
2025-08-11T23:51:01.117598Z ERROR Failed to convert "obsidian__obsidian_manage_frontmatter" MCP tool to OpenAI tool: Error("missing field `type`", line: 0, column: 0)
Repro steps
- Install Codex
0.20.0. - Configure
~/.codex/config.tomlwith an MCP server entry, e.g.:
``toml``
[mcp_servers.obsidian]
command = "docker"
args = ["run","--rm","-i","--env-file","PATH_TO_.env","obsidian-mcp-server-fixed"]
- Launch
codex, trigger MCP discovery (/mcp list), then check~/.codex/log/codex-tui.log. - Observe the 3 conversion errors above and the missing tools.
Cross-checks
- With Gemini CLI against the exact same Docker command, all 8 tools are listed and callable.
- Reproduced identically on PowerShell 5.1, PowerShell 7 (x64), and WSL2 (Ubuntu).
Notes / Hypothesis
- Errors suggest the converter currently rejects JSON Schema inputs such as:
type: "integer"(accepted by JSON Schema, but seemingly unsupported here — onlynumberworks)- Union/nullable forms (e.g.,
type: ["string","null"]) - Missing explicit
type: "object"at schema roots - Request: clarify the supported subset of JSON Schema for MCP tools, or consider relaxing the converter to accept common patterns above.
Ask
- Confirm whether
integerand union-types are intentionally unsupported or if this is a regression. - If unsupported by design, please document the required JSON-Schema subset.
- If regression, please fix so Codex loads the full toolset from community MCP servers like
cyanheads/obsidian-mcp-server.
Labels suggested: bug, mcp, schema-conversion
What is the expected behavior?
_No response_
What do you see instead?
_No response_
Additional information
_No response_
This issue has 3 comments on GitHub. Read the full discussion on GitHub ↗