MCP 2026-07-28 stateless compatibility
Research date: 2026-08-09.Contract and primary sources
MCP revision2026-07-28 changes Streamable HTTP from a protocol-session
model to a per-request model. Modern clients do not call initialize or
notifications/initialized, and the server does not mint Mcp-Session-Id.
Every JSON-RPC message uses a separate HTTP POST and carries protocol version,
client identity, and capabilities in request metadata.
Primary sources:
- MCP 2026-07-28 changelog
- Streamable HTTP specification
- SEP-2575: Make MCP Stateless
- OpenAI Codex support commit
- Official OpenAI MCP documentation
MCP-Protocol-Version: 2026-07-28Mcp-Method: <json-rpc-method>Mcp-Name: <tool-name>fortools/call- matching
params._meta["io.modelcontextprotocol/protocolVersion"] - per-request client capabilities and, preferably, client information
McpServer instance and hold no process-local
protocol state. Requests classified as the 2025 era continue through the
existing sessionful transport, preserving initialize,
notifications/initialized, and Mcp-Session-Id behavior.
This dual-era split matters: treating a sessionful 2025-06-18 exchange as
“stateless” because its POSTs use separate TCP connections does not implement
the 2026-07-28 contract.
Automated verification
From the repository root:tests/api/mcp-stateless.test.ts verifies:
- repeated
tools/listcalls on independent requests without session IDs; - concurrent read-only
tools/callrequests with bearer propagation; - rejection of missing per-request metadata;
- an effectful
update_task_statusrequest; - separation of modern traffic from legacy
initializetraffic.
Codex configuration and manual verification
Codex CLI0.147.0 contains mcp_2026_07_28, but the feature is under
development and disabled by default. Confirm the installed build before
testing:
config.toml. Then start a new Codex
session, inspect /mcp, list Kaneo tools, call whoami, and perform one
explicitly approved effectful call on test data. Capture traffic only with
authorization values redacted. Modern traffic must show server/discover
followed by self-contained calls, no initialize, and no Mcp-Session-Id.
With the feature disabled, Codex uses its legacy MCP lifecycle. Kaneo should
still complete initialize, return a session ID, accept
notifications/initialized, and serve tools on later requests carrying that
ID.
Limitations
- OpenAI documentation confirms Streamable HTTP, bearer tokens, and OAuth, but does not publish a Codex-release-to-MCP-revision matrix.
- Modern Codex support remains experimental in
0.147.0; dual-era serving is required until deployed clients are confirmed. - The modern handler is request-local. Kaneo tools currently need no server-to-client request channel or cross-request protocol state.
- No production image or NAS stack is changed by the repository tests.
Rollback
Code rollback removes the modern route and@modelcontextprotocol/server v2,
leaving the existing v1 sessionful branch unchanged. Client rollback disables
features.mcp_2026_07_28 and starts a new Codex session. No database migration
is involved.
Production rollback must happen by deploying the previous Kaneo image through
the normal operator-controlled stack workflow. Do not restart the host and do
not remove persistent volumes.