MCP-031: Invalid x-mcp-header Annotation - MCP
Summary
- Rule ID:
MCP-031 - Severity:
HIGH - Category:
MCP - Normative Level:
MUST - Auto-Fix:
No - Verified On:
2026-10-17
Applicability
- Tool:
all - Version Range:
unspecified - Spec Revision:
2026-07-28
Evidence Sources
- https://modelcontextprotocol.io/specification/2026-07-28/server/tools
- https://modelcontextprotocol.io/specification/2026-07-28/basic/transports/streamable-http
Test Coverage Metadata
- Unit tests:
true - Fixture tests:
true - E2E tests:
false
Examples
The following examples demonstrate what triggers this rule and how to fix it.
Invalid
"limit": {"type": "number", "x-mcp-header": "Limit"}
Valid
"region": {"type": "string", "x-mcp-header": "Region"}