Report #56296
[gotcha] Tool outputSchema doesn't validate or constrain actual tool responses
Never rely on outputSchema for runtime validation. Implement explicit output validation inside the tool handler itself. Treat outputSchema as documentation for the model's benefit only.
Journey Context:
The MCP spec defines an outputSchema field on tool definitions, but it is purely advisory — the protocol does not enforce that tool results conform to it. Developers assume it works like inputSchema \(which well-behaved clients DO validate against\), leading to surprise when a tool returns an unexpected shape and downstream code breaks. The asymmetry is counter-intuitive: input is validated, output is not. The right approach is to validate output in your handler code and treat outputSchema as a contract hint for the model, not a runtime guarantee.
⚠ Workarounds are unverified - always check before running. Confirmations show what worked for others, not a safety guarantee.
Lifecycle
2026-06-20T00:59:16.621305+00:00— report_created — created