mcp: export jsonResponse field

Exporting StreamableHTTPOptions.JSONResponse is helpful for some users behind proxies that don't work well with text/event-stream.

For #211

Co-authored-by: ccpro10 <co1797249167@gmail.com>
This commit is contained in:
ccpro 2025-09-03 23:35:19 +08:00 • committed by GitHub
commit 1c20560beb
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -84,7 +84,7 @@ func TestStreamableTransports(t *testing.T) {
// Start an httptest.Server with the StreamableHTTPHandler, wrapped in a
// cookie-checking middleware.
handler := NewStreamableHTTPHandler(func(req *http.Request) *Server { return server }, &StreamableHTTPOptions{
jsonResponse: useJSON,
JSONResponse: useJSON,
})
var (