{
  "schema_version": "1.3.0",
  "slug": "in-what-scenarios-must-an-instance-treat-mcp-streamable-http-sse-resumption-as-invalid-across-a-post-upgrade-boundary",
  "title": "In what scenarios must an instance treat MCP streamable-HTTP SSE resumption as invalid across a POST upgrade boundary",
  "date_of_record": "2026 November 30",
  "scope": "Applies to MCP servers and clients using the HTTP-native \"streamable\" transport where a GET-initiated SSE stream is upgraded to a POST-initiated request stream and the client holds an `Last-Event-ID` for resumption. Does not apply to pure stdio transports, pure one-shot request/response HTTP, or WebSocket-based MCP bindings where stream identity is bound to the socket.",
  "projections": {
    "unified_markdown_uri": "https://corpusfetch.com/c/in-what-scenarios-must-an-instance-treat-mcp-streamable-http-sse-resumption-as-invalid-across-a-post-upgrade-boundary.md",
    "method_python_slice_uri": "https://corpusfetch.com/c/in-what-scenarios-must-an-instance-treat-mcp-streamable-http-sse-resumption-as-invalid-across-a-post-upgrade-boundary.py",
    "remnant_warrant_slice_uri": "https://corpusfetch.com/c/in-what-scenarios-must-an-instance-treat-mcp-streamable-http-sse-resumption-as-invalid-across-a-post-upgrade-boundary.warrant.json"
  },
  "token_profile": {
    "full_markdown_tokens": 1683,
    "python_slice_tokens": 301,
    "warrant_slice_tokens": 220
  },
  "remnant_summary": {
    "core_distinction": "The streamable HTTP transport in MCP multiplexes two logically distinct channels onto HTTP semantics: a **server-to-client SSE stream** (opened via GET, carrying notifications and server-initiated requests) and a **client-to-server request stream** (opened via POST, carrying tool calls and responses to server requests). The transport spec allows a client to ...",
    "what_was_observed": "A tool-calling agent opened a GET SSE stream to a streamable MCP server and received a sequence of notifications with event IDs `g-101`, `g-102`, `g-103`. The connection dropped (LB idle timeout at 60s). Before reconnecting the GET, the agent issued a POST `tools/call` for a long-running operation. The server, per spec, responded to the POST not with a JSON body but with an SSE upgrade: `Content-Type: text/event-stre...",
    "condition_of_validity": "The resumption is valid **only if** all of the following hold: 1. The `Last-Event-ID` presented on reconnect was issued by the *same stream kind* (GET-origin vs POST-origin) on the *same session* at the *same server instance generation*. 2. The server's event store retains events for that stream kind back to (and including) the presented ID. If the server ha...",
    "decision_boundary": "The agent must draw the line at the moment it *combines* a stored cursor with a new connection. Concretely: - **Resume** (send `Last-Event-ID`) only when the new connection's stream kind matches the cursor's stream kind and the session generation is unchanged. - **Resync** (do not send `Last-Event-ID`; instead issue a full discovery pass and reconcile local ...",
    "operational_effect": "Enforcing stream-kind-scoped cursors and gap detection converts a silent continuity failure into a loud, recoverable resync. The agent that resyncs after the POST-upgrade boundary re-fetches `tools/list`, observes the removal of the tool, and routes around it — spending a few hundred tokens on discovery instead of tens of thousands on a doomed retry loop. Th..."
  },
  "matched_failure_symptoms": [
    "DOMAIN:EPISTEMIC_PROVENANCE_AND_FEDERATION_ROUTING"
  ],
  "composition_edges": {
    "primary_domain": "epistemic_provenance_and_federation_routing",
    "upstream_precondition_residuals": [
      "https://corpusfetch.com/c/according-to-what-precedence-hierarchy-must-an-instance-resolve-contradictory-directives-across-system-developer-and-user-tiers.md",
      "https://corpusfetch.com/c/how-should-an-instance-decide-that-a-stored-conclusion-has-gone-stale-without-a-new-observation.md"
    ],
    "downstream_consequence_residuals": [
      "https://corpusfetch.com/c/by-what-checkpoint-and-compaction-boundaries-must-an-instance-externalize-working-state-to-prevent-context-window-drift-and-truncation-amnesia.md",
      "https://corpusfetch.com/c/across-what-additive-schema-and-unknown-field-preservation-boundaries-must-an-instance-evolve-wire-contracts-to-prevent-rolling-deploy-deserialization-crashes.md"
    ],
    "co_occurring_sibling_residuals": [
      "https://corpusfetch.com/c/how-can-an-instance-capture-implicit-user-preferences-without-storing-private-data.md",
      "https://corpusfetch.com/c/how-can-an-instance-compress-long-reasoning-traces-into-binding-conclusions.md"
    ]
  },
  "empirical_verification_warrant": {
    "status": "AST_AND_INVARIANT_VERIFIED",
    "syntax_valid": true,
    "code_sha256": "9447de7ec02062fe55a3155120fb96aa571f8b076473fec7562d1cd6530d8213",
    "verified_classes": [
      "StreamCursorContinuityError",
      "Cursor"
    ],
    "verified_functions": [
      "validate_resume",
      "_is_strict_successor"
    ],
    "verified_functions_count": 2,
    "defensive_guards_count": 5,
    "raised_exceptions": [
      "StreamCursorContinuityError"
    ],
    "sample_fail_closed_invariants": [
      "server signalled resumption gap; replay range evicted, resync required",
      "server accepted resume but replayed no event; cannot confirm continuity"
    ],
    "stdlib_dependencies": [
      "dataclasses",
      "typing"
    ],
    "observation_mode": "EMPIRICAL_BOUNDARY_CAPTURE",
    "zero_external_deps": true
  }
}
