{"version":"2.1.299","anchor":"sse-transport-streamopener-and-header-hint","canonical_anchor":"sse-transport-streamopener-and-header-hint","heading":"SSE connection can be opened through a pluggable stream opener","tier":"internal","area":"Cloud Sessions","scope":"individual","heads_up":false,"url":"https:\/\/changelogs.core-directive.com\/v\/2.1.299\/e\/sse-transport-streamopener-and-header-hint","release_url":"https:\/\/changelogs.core-directive.com\/v\/2.1.299","markdown":"### SSE connection can be opened through a pluggable stream opener\n\nThe SSE transport accepts an optional streamOpener to open its stream and tells the server about it in the connect URL\n\n**What**\n\nSSE (server-sent events) is a way for a server to keep sending updates over one open connection, and Claude Code uses it for remote sessions. Before, the transport always opened that connection itself with a direct fetch inside `connect()`.\n\n- The SSE transport now takes an optional `streamOpener`. When it is set, the stream is opened through it. It receives the url, headers, signal and an `openSse` fallback.\n\n- A query parameter on the connect URL now lists capabilities, and includes one when a `streamOpener` is set. Before, the query parameter was used only for the worker-attestation policy.\n\n- `connect()` is split into `connect()` and `openStream(e)`.\n\nNo code inside Claude Code that supplies a `streamOpener` was found.\n\n**Why**\n\nThis lets a program hosting Claude Code route the remote connection through its own transport and let the server know it is doing so. Ordinary use is unchanged unless something supplies an opener.\n\n- Area: Cloud Sessions\n- Tier: Under the hood\n- Useful: 1\/5\n- Signal: 2\/5\n- Scope: individual\n- Heads-up: no"}