File tree Expand file tree Collapse file tree 2 files changed +6
-3
lines changed
Expand file tree Collapse file tree 2 files changed +6
-3
lines changed Original file line number Diff line number Diff line change 11{
22 "name" : " @deco/mcp" ,
3- "version" : " 0.1.15 " ,
3+ "version" : " 0.1.16 " ,
44 "exports" : " ./mod.ts" ,
55 "tasks" : {
66 "check" : " deno fmt && deno lint && deno check mod.ts"
Original file line number Diff line number Diff line change @@ -239,7 +239,8 @@ export function mcpServer<TManifest extends AppManifest>(
239239 const path = new URL ( c . req . url ) . pathname ;
240240
241241 if (
242- path === `${ options ?. basePath ?? "" } /mcp/ws` && c . req . raw . headers . get ( "upgrade" ) === "websocket"
242+ path === `${ options ?. basePath ?? "" } /mcp/ws` &&
243+ c . req . raw . headers . get ( "upgrade" ) === "websocket"
243244 ) {
244245 const { response, socket } = Deno . upgradeWebSocket ( c . req . raw ) ;
245246
@@ -252,7 +253,9 @@ export function mcpServer<TManifest extends AppManifest>(
252253 }
253254
254255 if ( path === `${ options ?. basePath ?? "" } /mcp/sse` ) {
255- const transport = new SSEServerTransport ( MESSAGES_ENDPOINT ) ;
256+ const transport = new SSEServerTransport (
257+ `${ options ?. basePath ?? "" } ${ MESSAGES_ENDPOINT } ` ,
258+ ) ;
256259 transports . set ( transport . sessionId , transport ) ;
257260
258261 transport . onclose = ( ) => {
You can’t perform that action at this time.
0 commit comments