-
Notifications
You must be signed in to change notification settings - Fork 1.4k
Open
Labels
P2Moderate issues affecting some users, edge cases, potentially valuable featureModerate issues affecting some users, edge cases, potentially valuable featurebugSomething isn't workingSomething isn't workinggood first issueGood for newcomersGood for newcomersready for workEnough information for someone to start working onEnough information for someone to start working on
Description
When we create SSE client that needs additional headers to be passed to the server, the current code does not work. It does not pass the additional headers configured in the requestInit via SSEClientTransportOptions.
Exact issue is in the method below in SSE client:
https://github.com/modelcontextprotocol/typescript-sdk/blob/main/src/client/sse.ts#L108
return headers;
The return should be changed to something like below: [Similar to how it is done in https://github.com/modelcontextprotocol/typescript-sdk/blob/main/src/client/streamableHttp.ts#L175]
return new Headers(
{ ...headers, ...this._requestInit?.headers }
);
jsCommander, smoyer64, lucaalbinati, wanghsinche, mh-it and 4 more
Metadata
Metadata
Assignees
Labels
P2Moderate issues affecting some users, edge cases, potentially valuable featureModerate issues affecting some users, edge cases, potentially valuable featurebugSomething isn't workingSomething isn't workinggood first issueGood for newcomersGood for newcomersready for workEnough information for someone to start working onEnough information for someone to start working on