A client receives an SSE response stream for one tools/call over Streamable HTTP. Several messages arrive before the stream closes. What may this stream contain?
Select an answer to reveal the explanation.
Short Explanation
A per-request SSE stream is a private channel for one call. You'll see progress or log notes about that call, then the answer, then it closes. Anything unrelated, or any server request, doesn't belong there.
Full Explanation
When the server answers a request with text/event-stream, it MAY send JSON-RPC notifications before the final response, for example notifications/progress or notifications/message, and those notifications MUST relate to the originating client request. The final JSON-RPC response SHOULD terminate the stream. The server MUST NOT send independent JSON-RPC requests on the stream; server-to-client needs such as elicitation are embedded as input requests inside an InputRequiredResult, which is itself the response to the call. That rules out server-initiated elicitation requests answered mid-stream, which was permitted only in revisions 2025-03-26 through 2025-11-25. Change notifications for subscriptions, such as tool list changes or resource updates, are delivered on the response stream of a subscriptions/listen request, and request-scoped notifications are likewise kept off the listen stream, so the two kinds are not mixed. Each request on Streamable HTTP has its own POST and its own response, so other requests' responses never share this stream; stdio is the transport where all messages share one channel. Exam caveat: resumable SSE using Last-Event-ID is not supported in this revision, so a dropped stream means the request is lost and must be re-issued with a new id. Operational check: capture a streamed call and confirm only related notifications precede one final response, after which the stream ends.