# Stateless MCP explained: how multi round-trip requests replace sessions and callbacks

The 2026-07-28 Model Context Protocol revision removes sessions, the initialize handshake and server-initiated callbacks. This article explains the new request shape, the multi round-trip pattern and how to build a server that scales behind any load balancer.

The Model Context Protocol (MCP) is the open standard that lets an AI application call tools, read resources and fetch prompts from outside servers. Its 2026-07-28 revision changes the protocol at its core. It removes protocol-level sessions, drops the `initialize` handshake and replaces server-initiated callbacks with a pattern called Multi Round-Trip Requests (MRTR).

Many MCP servers now run as remote services behind load balancers, not as local processes on a laptop. Sessions forced those services to remember which client talked to which replica. The new revision makes every request carry everything the server needs. This article explains what changed, why, and how to build a server that follows the new rules. It focuses on the engineering, not the announcement.

## What happened

### The MCP 2026-07-28 specification becomes the latest revision (28 July 2026)

The specification revision named 2026-07-28 is now listed as the latest version in the official MCP documentation. Its changelog lists nine major changes. The core ones are the removal of the `Mcp-Session-Id` header, the removal of the `initialize`/`notifications/initialized` handshake, a new required `server/discover` method, a new `subscriptions/listen` stream for change notifications, and MRTR in place of server-to-client requests such as `elicitation/create` and `sampling/createMessage`. Experimental tasks moved out of the core protocol into an official extension. The revision also adopts a feature lifecycle policy with a minimum twelve-month deprecation window, and deprecates the Roots, Sampling and Logging features.

### SDKs and frameworks follow (October to November 2026)

The official Python SDK, published on PyPI as `mcp`, moved to a 2.x line during 2026; version 2.3.0 was uploaded on 2 October 2026. Its README describes servers built with an `MCPServer` class and links a "What's new in v2" guide and a migration guide. The FastMCP framework published version 4.2.5 on 23 November 2026, after versions 4.2.2, 4.2.3 and 4.2.4 between 18 and 21 November. The specification's draft changelog already lists follow-up fixes, such as restoring an optional `_meta` field on several request types that was dropped by accident in 2026-07-28.

## Why sessions had to go

Under the 2025-11-25 revision, a client opened a connection with `initialize`. The server replied with its capabilities, and over Streamable HTTP it could hand back an `Mcp-Session-Id`. Every later request carried that header. The server could also send its own requests back to the client, for example asking the user a question through elicitation or asking the client's model for a completion through sampling.

That design is natural for a local process connected over stdio. It is awkward for a fleet of servers behind a load balancer. Think of a bank where every customer must always return to the same teller, because only that teller remembers the half-finished form. If the teller goes home, the form is lost. You either pin customers to tellers (sticky sessions) or you build a shared filing cabinet (a session store such as Redis) that every teller can read.

A small calculation shows the cost. Suppose a service runs four replicas and one restarts during a deploy. With sticky sessions and no shared store, the sessions pinned to that replica break, which is about one quarter of live sessions if traffic is balanced. With a shared store, nothing breaks, but every request now pays a network round trip to the store and you have one more system to run. Stateless requests remove both costs: any replica can serve any request because the request itself carries the context.

The 2026-07-28 changelog states the new rule plainly. List endpoints such as `tools/list` no longer vary per connection, and servers that need state across calls use explicit server-minted handles passed as ordinary tool arguments.

## How a stateless MCP request is built

### Every request describes itself

With no handshake, each request carries its protocol version and the client's capabilities in the `_meta` object of its parameters. The specification defines the keys `io.modelcontextprotocol/protocolVersion` and `io.modelcontextprotocol/clientCapabilities`, and says clients should also send `io.modelcontextprotocol/clientInfo`. Servers should return `io.modelcontextprotocol/serverInfo` in each result's `_meta`. A mismatch in version returns an `UnsupportedProtocolVersionError`.

Over Streamable HTTP, the transport also copies key routing facts into headers. Every POST must carry `MCP-Protocol-Version`, and the revision requires `Mcp-Method` on all requests and `Mcp-Name` on `tools/call`, `resources/read` and `prompts/get`. The specification gives the reason: intermediaries such as load balancers, gateways and observability tools can route and inspect requests without parsing the body. A tool call looks like this:

```http
POST /mcp HTTP/1.1
Content-Type: application/json
Accept: application/json, text/event-stream
MCP-Protocol-Version: 2026-07-28
Mcp-Method: tools/call
Mcp-Name: get_weather

{"jsonrpc": "2.0", "id": 1, "method": "tools/call",
 "params": {"name": "get_weather",
   "arguments": {"location": "Seattle, WA"},
   "_meta": {"io.modelcontextprotocol/protocolVersion": "2026-07-28",
             "io.modelcontextprotocol/clientInfo": {"name": "ExampleClient", "version": "1.0.0"},
             "io.modelcontextprotocol/clientCapabilities": {}}}}
```

The server answers each POST with either a single JSON object or a Server-Sent Events stream scoped to that one request. Progress notifications for a long tool call travel on that request's own stream. Because there are no session-wide streams any more, the specification also removes SSE resumability: if a response stream breaks, the in-flight request is lost and the client must reissue it with a new request ID.

### Discovery replaces the handshake

The capability exchange that `initialize` used to perform now has an optional, explicit form. Servers must implement `server/discover`, which advertises supported protocol versions, capabilities and identity. A client may call it first to choose a version, or use it as a compatibility probe on stdio. It is a normal request, so it can be cached like any other.

### Change notifications get one opt-in stream

Clients that want to know when a server's tool list changes now open `subscriptions/listen`. This is a single long-lived POST whose response is a stream. The client opts into specific types: `toolsListChanged`, `promptsListChanged`, `resourcesListChanged` and `resourceSubscriptions`. The server acknowledges and tags each notification with a subscription ID. This replaces the old HTTP GET endpoint and the `resources/subscribe` and `resources/unsubscribe` methods.

### Lists become cacheable

A smaller change matters for cost. Results from `tools/list`, `prompts/list`, `resources/list`, `resources/read` and `resources/templates/list` now carry `ttlMs` and `cacheScope`. `ttlMs` is a freshness hint in milliseconds, and `cacheScope` is either `public` or `private`, telling shared intermediaries whether they may cache the response. The tools page shows a value of `300000`, which is five minutes. The revision also says servers should return tools in a deterministic order, to help client-side caching and improve LLM prompt cache hit rates.

That second point links protocol design to token bills. Tool definitions sit near the start of a model's prompt. If a server returns the same tools in a different order on each call, the prompt prefix changes and the model provider's prefix cache misses. The [prompt caching](/tools/prompt-caching) page and the [prompt cache hits simulation](/ai-simulations/prompt-cache-hits-agent-session) show how much a stable prefix saves over a long agent session.

## Multi round-trip requests, step by step

The hardest problem in a stateless protocol is a tool that needs more information halfway through. A deploy tool may need the user's confirmation. A search tool may need the user's GitHub login. Before, the server paused, sent `elicitation/create` to the client, waited for the answer on the same session, and then continued. That pause is server-side state.

MRTR turns the pause into a return value. It works like a form at a government office: instead of the clerk holding your file while you fetch a missing document, the clerk hands the whole file back to you with a sticky note saying what is missing. You come back with the document and the file, and any clerk can finish the job.

### The four steps

1. The client sends `tools/call` with request ID 1.
2. The server decides it needs more input. It returns a result with `resultType: "input_required"`, an `inputRequests` map, and optionally an opaque `requestState` string. Request 1 is now finished.
3. The client fulfils each entry in `inputRequests`, for example by asking the user, and retries the original call with a new ID, adding `inputResponses` keyed the same way and echoing `requestState` exactly.
4. Any server replica reads the responses and the state, finishes the work and returns a result with `resultType: "complete"`.

All results now carry a required `resultType` field. Clients must treat results from older servers that omit it as `complete`. Servers may return `InputRequiredResult` only on `tools/call`, `resources/read` and `prompts/get`, and each entry in `inputRequests` must be an elicitation, sampling or roots request, and only of a kind the client declared in its capabilities.

A short version of the server's interim reply looks like this:

```json
{"jsonrpc": "2.0", "id": 1,
 "result": {"resultType": "input_required",
   "inputRequests": {"github_login": {"method": "elicitation/create",
     "params": {"mode": "form", "message": "Please provide your GitHub username",
       "requestedSchema": {"type": "object",
         "properties": {"name": {"type": "string"}}, "required": ["name"]}}}},
   "requestState": "AEAD-protected blob"}}
```

### Counting the round trips

MRTR does not add network round trips compared with the old callback design. In the old flow, one tool call needing one elicitation used the original request, the server's elicitation request and the client's reply, then the final result: two exchanges. In MRTR it is the first call and its interim result, then the retry and its final result: also two exchanges. The difference is where the half-finished work lives. If a tool needs input twice, MRTR uses three request and response pairs, and the server may return `InputRequiredResult` repeatedly until it has everything.

### Treat requestState as hostile input

`requestState` travels through the client, so the specification requires servers to treat it as attacker-controlled. If it influences authorisation, resource access or business logic, servers must protect its integrity with something like an HMAC or AEAD and reject anything that fails verification. To limit replay, servers should bind the state to the authenticated user, give it a short expiry and tie it to the originating request, for example by method name and a digest of the main parameters. The specification adds that these steps do not make state single-use; one-time actions must still be enforced on the server.

Here is a minimal implementation of those rules in Python. It signs the state with HMAC-SHA256 and checks user, request and expiry on the way back:

```python
import base64, hashlib, hmac, json, time

KEY = b"rotate-me-from-a-secret-store"

def seal(state: dict) -> str:
    body = json.dumps(state, sort_keys=True, separators=(",", ":")).encode()
    tag = hmac.new(KEY, body, hashlib.sha256).digest()
    return base64.urlsafe_b64encode(body + tag).decode()

def open_state(blob, principal, method, args_digest):
    raw = base64.urlsafe_b64decode(blob.encode())
    body, tag = raw[:-32], raw[-32:]
    if not hmac.compare_digest(tag, hmac.new(KEY, body, hashlib.sha256).digest()):
        raise ValueError("tampered requestState")
    s = json.loads(body)
    if s["sub"] != principal or s["m"] != method or s["d"] != args_digest:
        raise ValueError("state replayed on another user or request")
    if time.time() > s["exp"]:
        raise ValueError("requestState expired")
    return s

args = {"repo": "acme/api", "branch": "main"}
digest = hashlib.sha256(json.dumps(args, sort_keys=True).encode()).hexdigest()[:16]
blob = seal({"sub": "user-42", "m": "tools/call", "d": digest,
             "exp": time.time() + 300, "step": "need_github_login"})
print(open_state(blob, "user-42", "tools/call", digest)["step"])  # need_github_login
open_state(blob, "user-7", "tools/call", digest)                  # raises ValueError
```

The state is only signed, not encrypted, so the client can read it. If the state holds anything private, use an AEAD cipher such as AES-GCM instead, which both hides and authenticates the content. The secret key must be shared by every replica, which is the one piece of shared configuration a stateless fleet still needs.

## Old and new side by side

| Concern | 2025-11-25 | 2026-07-28 |
|---|---|---|
| Start of conversation | `initialize` handshake | none; optional `server/discover` |
| Version and capabilities | sent once at start | sent in `_meta` on every request |
| Session identity | `Mcp-Session-Id` header | removed; explicit handles as tool arguments |
| Server needs user input | server sends `elicitation/create` | `InputRequiredResult` plus client retry |
| Change notifications | GET stream, `resources/subscribe` | `subscriptions/listen` with opt-in types |
| Broken stream | resume with `Last-Event-ID` | request lost; reissue with new ID |
| Long-running work | experimental core tasks | `io.modelcontextprotocol/tasks` extension, polled with `tasks/get` |
| Logging level | `logging/setLevel` | per request via `_meta`; Logging deprecated |

The Roots, Sampling and Logging features are deprecated but still work during the deprecation window. The changelog suggests passing directories through tool parameters or resource URIs instead of Roots, calling LLM provider APIs directly instead of Sampling, and logging to stderr or OpenTelemetry instead of Logging. It also documents conventions for carrying `traceparent`, `tracestate` and `baggage` in `_meta`, so a tool call can join a distributed trace. The [OpenTelemetry](/tools/opentelemetry) and [tracing](/tools/tracing) pages explain how those spans fit together.

## What it means in practice

For server authors, the main work is removing hidden state. Any dictionary keyed by session ID is now a bug. Multi-step tools must either finish in one call, return an `InputRequiredResult`, or hand back an explicit handle such as a cart ID that the model passes in later calls. That last option also makes state visible to the model and to audit logs, which is easier to reason about than state hidden in a connection.

For platform teams, MCP servers can now sit behind ordinary HTTP load balancers and serverless runtimes with no session affinity. The new `Mcp-Method` and `Mcp-Name` headers let a gateway rate-limit or authorise by tool name without parsing JSON. This fits the scoped-credential approach described in [governing AI agent access](/articles/governing-ai-agent-access) and the [OAuth for tool access](/tools/oauth-for-tool-access) page.

For client and agent builders, every request is a little larger because `_meta` repeats the version and capabilities. In exchange, retries and failover become simple: a failed request can go to any replica. Clients must also learn to handle `input_required` results as a normal branch of the [agent loop](/ai-simulations/react-tool-calling), not as an error.

## What to do now

1. **Inventory your state.** List every place your server stores data between calls, including caches keyed by connection, and decide for each whether it becomes a tool argument handle, `requestState`, or real server-side storage.
2. **Rewrite callbacks as MRTR.** Replace every `elicitation/create` or `sampling/createMessage` sent mid-call with an `InputRequiredResult`, and make the tool resumable from `inputResponses` plus `requestState`.
3. **Sign or encrypt requestState.** Use HMAC or an AEAD cipher with a key from a secret store, and bind each blob to the user, the request and a short expiry, as the specification recommends.
4. **Keep one-time actions server-side.** For payments, approvals or redemptions, store a used-token record on the server, because signed state can still be replayed within its expiry.
5. **Implement server/discover.** It is required in 2026-07-28, and it is how new clients pick a version with your server.
6. **Return tools in a fixed order with cache hints.** Sort tool definitions, set sensible `ttlMs` and `cacheScope` values, and check that your prompt cache hit rate rises.
7. **Route on headers.** Configure gateways to use `Mcp-Method` and `Mcp-Name` for rate limits, authorisation and metrics instead of body parsing.
8. **Plan the deprecations.** If you rely on Roots, Sampling or Logging, schedule the suggested migrations within the twelve-month window, and move from Dynamic Client Registration to Client ID Metadata Documents for OAuth.
9. **Test failover.** Kill a replica in the middle of a multi-step tool call and confirm the retry completes on another replica with no lost work.

## Risks and open questions

**Mixed-version fleets will be messy for a while.** Clients must treat results without `resultType` as complete, and servers must answer older clients, so both sides need compatibility code until older versions fade.

**Client-held state moves risk to the edge.** A bug in `requestState` validation can let one user resume another user's action. The specification's rules on integrity, binding and expiry are mandatory in spirit even where they say should.

**Lost streams lose work.** Without SSE resumability, a long tool call whose stream breaks must be reissued. Tools with side effects need idempotency keys so a retry does not run the action twice.

**Deprecated features may linger.** Many clients use sampling today. A twelve-month window is short for enterprise software, and it is not yet clear how quickly popular clients will drop support.

**Watch next:** how fast major clients and hosted MCP gateways ship full 2026-07-28 support, how the tasks extension settles for long-running jobs, and whether the draft changelog's fixes grow into a new revision.

## Frequently asked questions

### Does stateless MCP mean my server cannot keep any state?

No. It means the protocol no longer keeps state for you. Your server can still use a database, but state must be addressed explicitly, for example by a handle passed as a tool argument or by signed `requestState`, rather than by a connection ID.

### Is MRTR slower than the old elicitation flow?

For one round of user input it uses the same number of exchanges as the old callback design: an interim result and then a retry. The extra cost is that the retry resends the original parameters and the `requestState` blob, which is usually small.

### Which requests can return input_required?

Only `tools/call`, `resources/read` and `prompts/get`. Servers must not return it on other methods, and may only ask for elicitation, sampling or roots that the client declared in its capabilities.

### Do stdio servers need to change?

Yes, the message format changes on every transport, because the handshake is gone and `_meta` carries version and capabilities. The transport mechanics that changed most, such as sessions and resumable streams, belong to Streamable HTTP, and clients can use `server/discover` as a compatibility probe on stdio.

### What happens to sampling and roots?

They are deprecated, not removed, and keep working during the deprecation window. New implementations should avoid them, and when servers still need them mid-call they are requested through MRTR rather than as server-initiated requests.

## Summary

The MCP 2026-07-28 revision turns MCP from a session protocol into a request protocol. Each request carries its own version and capabilities, routing facts appear in HTTP headers, list results become cacheable, and servers that need more input return an `InputRequiredResult` instead of calling back into the client. The design lets any replica serve any request, which suits remote, load-balanced MCP servers. The price is discipline: server authors must remove hidden session state, protect client-held `requestState` with signatures and expiry, make side-effecting tools idempotent, and plan for the deprecation of Roots, Sampling and Logging. For the wider picture of tool protocols, see the [MCP](/tools/mcp) page and the [agent protocols topic](/topics/agentic-ai/protocols).

## Sources

- [Model Context Protocol: Key Changes in 2026-07-28](https://modelcontextprotocol.io/specification/2026-07-28/changelog)
- [Model Context Protocol: Multi Round-Trip Requests](https://modelcontextprotocol.io/specification/2026-07-28/basic/patterns/mrtr)
- [Model Context Protocol: Streamable HTTP transport](https://modelcontextprotocol.io/specification/2026-07-28/basic/transports/streamable-http)
- [Model Context Protocol: Tools](https://modelcontextprotocol.io/specification/2026-07-28/server/tools)
- [Model Context Protocol: Key Changes in 2025-11-25](https://modelcontextprotocol.io/specification/2025-11-25/changelog)
- [MCP Blog: The 2026-07-28 Specification](https://blog.modelcontextprotocol.io/posts/2026-07-28/)
- [GitHub: MCP Python SDK README](https://github.com/modelcontextprotocol/python-sdk)
- [PyPI: mcp release history](https://pypi.org/project/mcp/#history)
- [PyPI: fastmcp release history](https://pypi.org/project/fastmcp/#history)
