Expand description
Content-based classification of axum request parts into the
Request sum type.
Rules:
POST+ body parses as JSON-RPC →Request::Mcpwithtransport: StreamableHttpPost.GET+Accept: text/event-stream→Request::Mcpwithtransport: SseLegacyGet(synthetic envelope; downstream matches on transport variant, not envelope contents).DELETE+mcp-session-idheader →Request::Mcpwith a synthetic envelope soSessionDeleteMiddlewarecan pattern-match onRequest::Mcp.- Everything else →
Request::Raw.
OAuth classification is deferred. Non-MCP traffic becomes
Request::Raw; UrlMapMiddleware rewrites JSON Raw bodies.