Open
Description
Typescript server I'm testing my Java SDK client with streamable HTTP against enforces client requests to server Content-Type header value of application/json, e.g.
const ct = req.headers["content-type"];
if (!ct || !ct.includes("application/json")) {
res.writeHead(415).end(JSON.stringify({
jsonrpc: "2.0",
error: {
code: -32000,
message: "Unsupported Media Type: Content-Type must be application/json"
},
id: null
}));
return;
}
I was fine with adding it, but the spec doesn't call out that requirement. It only dictates Content-Type header rules for the server's responses.
Is this something that should be added to the spec, or removed from the TS SDK server implementation?