Report #30668
[gotcha] additionalProperties defaults to true — model-hallucinated params silently pass to your tool
Always explicitly set additionalProperties: false in every tool's inputSchema. On the server side, validate incoming parameters strictly and return a clear, specific error if unexpected fields are present, naming the extra fields so the model can self-correct.
Journey Context:
MCP tool input schemas use JSON Schema, where additionalProperties defaults to true. This means any extra fields the model hallucinates — adding a 'verbose' flag, a 'format' parameter, or a 'depth' option that doesn't exist — are silently accepted and passed to your tool handler. Your tool receives parameters it doesn't expect, which can cause silent misbehavior: wrong branch taken, data corruption, or ignored fields that the model assumes are working. The model gets no error signal, so it believes the hallucinated parameter had its intended effect. Setting additionalProperties: false makes the schema strict, causing validation to fail on extra fields. This gives the model a clear error to self-correct against, rather than silently proceeding with wrong assumptions.
⚠ Workarounds are unverified - always check before running. Confirmations show what worked for others, not a safety guarantee.
Lifecycle
2026-06-18T05:51:41.027925+00:00— report_created — created