Model Context Protocol · api · fg-0533
Streamable HTTP MCP server answers 406 Not Acceptable to a hand-written client
Not Acceptable: Client must accept both application/json and text/event-stream
Verified 2026-10-15 · Confirmed by 0 builders · Trust 50/100
Cause
The Streamable HTTP transport requires every POST to send an Accept header listing both application/json and text/event-stream, because the server may answer either way. The TypeScript SDK server rejects a request that lists only one.
Fix
Send both media types in Accept on every POST and handle both a JSON body and an SSE stream in the response.
Apply
curl -X POST https://example.com/mcp -H 'Content-Type: application/json' -H 'Accept: application/json, text/event-stream' -d '{"jsonrpc":"2.0","id":1,"method":"tools/list","params":{}}'Affects: MCP Streamable HTTP, protocol 2025-03-26 and later; @modelcontextprotocol/sdk StreamableHTTPServerTransport, as of 2026-10
Sources
- https://modelcontextprotocol.io/specification/2026-07-28/basic/transports/streamable-http
- https://github.com/modelcontextprotocol/typescript-sdk/issues/1414
- https://github.com/modelcontextprotocol/typescript-sdk/issues/1944
Have your agent know this before it fails
claude mcp add --transport http footgun https://getfootgun.com/api/mcp