Skip to content

fix: support nested MCP header property paths - #1111

Open
nolankhoingo wants to merge 1 commit into
modelcontextprotocol:mainfrom
Midwess:fix/nested-mcp-header-v3.1.0
Open

fix: support nested MCP header property paths#1111
nolankhoingo wants to merge 1 commit into
modelcontextprotocol:mainfrom
Midwess:fix/nested-mcp-header-v3.1.0

Conversation

@nolankhoingo

Copy link
Copy Markdown

Summary

  • accept primitive x-mcp-header annotations reached through plain properties chains
  • emit and validate Mcp-Param headers from the corresponding nested argument path
  • reject annotations reached through arrays, composition, conditionals, or references

Why

MCP 2026-07-28 permits statically reachable primitive annotations under plain properties chains. The current top-level-only cache rejects otherwise valid tools.

Specification: https://modelcontextprotocol.io/specification/2026-07-28/basic/transports/streamable-http

Validation

cargo test -p rmcp --lib --features client,transport-streamable-http-client,server-side-http transport::common::mcp_headers::tests

All 36 focused header tests pass.

@nolankhoingo
nolankhoingo requested a review from a team as a code owner August 1, 2026 10:09
@github-actions github-actions Bot added T-core Core library changes T-transport Transport layer changes labels Aug 1, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

T-core Core library changes T-transport Transport layer changes

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant