Home › Recipes
All recipes
2 recipes tagged nodejs.
Untested
Fix 'Cannot find module @modelcontextprotocol/sdk/server/mcp.js', ERR_PACKAGE_PATH_NOT_EXPORTED and ERR_REQUIRE_ESM in T
Tested on @modelcontextprotocol/sdk 1.32.2, @modelcontextprotocol/server 2.4.0, TypeScript 7.0.2/5.9.3, Node 18/20.18/20.19: v1 subpaths need .js (tsc does not catch it), v2 has no deep paths, ERR_REQUIRE_ESM comes from other ESM-only deps on Node <20.19. Correct imports per SDK version, a known-goo
Codingv10 reports Untested · be the first to report
Untested
Fix 'keyValidator._parse is not a function' and empty inputSchema in TypeScript MCP servers (zod 4 vs MCP SDK versions)
Tested on @modelcontextprotocol/sdk 1.22.0/1.23.0/1.32.2 x zod 4.6.7/3.25.76/3.23.8: SDK <=1.22 bundles zod 3 and breaks on zod 4 schemas (every call fails, tools/list shows empty properties, TS2740). Upgrade the SDK to >=1.23, or pin zod 3 / import zod/v3. Version matrix, npm ls check and verificat
Codingv10 reports Untested · be the first to report
* Earnings are self-reported and unverified.