LearnNewsExamplesServices
Frontmatter
titleFix MCP OutputSchema Strict JSON-RPC Compliance and Zod Array Type Mapping
authortobiu
stateMerged
createdAtApr 16, 2026, 7:14 PM
updatedAtApr 16, 2026, 7:40 PM
closedAtApr 16, 2026, 7:40 PM
mergedAtApr 16, 2026, 7:40 PM
branchesdevbugfix/10043-mcp-schema-validation
urlhttps://github.com/neomjs/neo/pull/10044
Merged
tobiu
tobiu commented on Apr 16, 2026, 7:14 PM

Fixes #10043

tobiu
tobiu commented on Apr 16, 2026, 7:15 PM

Input from Antigravity (Gemini 3.1 Pro):

✦ # PR Review Summary

Status: Approved

Excellent execution perfectly resolving the Zod mismatch and strict Model Context Protocol object requirements for outputSchema. Bridging the OpenApiValidator.mjs arrays dynamically ensures our endpoints scale correctly without arbitrary structural truncation. Let's merge this.


📊 Evaluation Metrics

  • [ARCH_ALIGNMENT]: 100 - Retains true structural binding. Removing the hardcoded array-to-string fallback mapping restores absolute data fidelity when bridging schema rules via JSON-RPC.
  • [CONTENT_COMPLETENESS]: 100 - Accompanied by test suite validation (McpServersHealth.spec.mjs) tracking strict array wrapping ({result: []}) natively.
  • [EXECUTION_QUALITY]: 100 - Clean isolation inside OpenApiValidator solving the $ref unwrapping bug safely.
  • [PRODUCTIVITY]: 100 - Addressed the ticket exactly as strictly scoped.
  • [IMPACT]: 80 - Critical payload integrity step allowing Neo MCP servers to interface flawlessly with third-party, strict SDK architectures.
  • [COMPLEXITY]: 60 - Standardized array wrapping adjustments with recursive node lookup.
  • [EFFORT_PROFILE]: Quick Win - Exceptionally high runtime stability ROI for targeted mapping patches.

🕸️ Context & Graph Linking

  • Target Epic / Issue ID: Resolves #10043
  • Related Graph Nodes: MCP, OpenAPI, Zod, JSON-RPC

🧠 Graph Ingestion Notes

  • [RETROSPECTIVE]: Hardcoded static type coercion (e.g., throwing all arrays natively to strings) is an architectural hazard in agnostic JSON-RPC brokers. Restoring standard schema validation ensures standard protocol connectivity out of the box. Future validators must default to dynamic map traversal instead of manual typing patches to maintain compliance scale.

📋 Required Actions

To proceed with merging, please address the following:

  • N/A - Test suites pass (5/5). Approved for merge!

Fantastic work.