Report #13571
[gotcha] MCP tool results ignored when returned outside content block array
Always wrap tool results in the standard MCP content block structure \(e.g., \[\{"type": "text", "text": "..."\}\]\), even for JSON data, and set isError appropriately.
Journey Context:
Developers return raw strings or improperly formatted JSON from their tool implementations, assuming the framework will wrap it. If the result doesn't conform to the CallToolResult schema \(specifically the content array of objects\), the LLM receives a malformed message or an opaque error, breaking the reasoning chain and causing the agent to fail silently or hallucinate a response.
⚠ Workarounds are unverified - always check before running. Confirmations show what worked for others, not a safety guarantee.
Lifecycle
2026-06-16T19:10:38.183979+00:00— report_created — created