StuMason/coolify-mcp
TypeScript
Issue Resolved
Issue #109 closed: tried using the MCP, got a keyValidator._parse is not a function error
What happened?
All MCP tools with parameters fail with the error:
MCP error -32603: keyValidator._parse is not a function
Only 3 parameterless tools work (get_version, get_mcp_version, get_infrastructure_overview). The remaining 46 tools that accept parameters are broken.
Steps to reproduce
- Install the package: npx -y @masonator/coolify-mcp
- Configure with valid COOLIFY_ACCESS_TOKEN and COOLIFY_BASE_URL
- Call any tool with parameters, e.g., list_servers, projects, diagnose_app
- Observe error: keyValidator._parse is not a function
Expected behaviour
All tools should execute successfully and return data from the Coolify API.
Additional context
Tried to run this with Claude Code to fix, here's the result. Claude did apply the fix locally on my laptop and the MCP started to work.
Root cause: Dependency version mismatch causing Zod v3/v4 incompatibility.
- package.json declares "zod": "^4.3.5" but npm resolves to Zod 3.25.x due to peer dependency conflicts
- @modelcontextprotocol/sdk: ^1.6.1 resolves to SDK ~1.20.x which lacks the Zod v3/v4 compatibility layer (added in SDK 1.25.0)
- When tools are called, the SDK tries to use Zod v3's ._parse() method which doesn't exist on the installed schemas
Fix: Update dependencies in package.json:
"dependencies": {
- "@modelcontextprotocol/sdk": "^1.6.1",
- "zod": "^4.3.5"
- "@modelcontextprotocol/sdk": "^1.25.0",
- "zod": "^3.25.0"
}
Verified: All 230 tests pass, full MCP flow tested with all tools working.