docs: Add clarifying comments for stateless streamable HTTP endpoints
Add inline comments explaining why GET and DELETE endpoints return 405 in stateless mode: - GET: SSE notifications not supported without session management - DELETE: Session termination not needed in stateless mode
This commit is contained in:
parent
0c4b308275
commit
eefdcf5bf3
1 changed files with 2 additions and 0 deletions
|
|
@ -347,6 +347,7 @@ app.post('/mcp', async (req: Request, res: Response) => {
|
|||
}
|
||||
});
|
||||
|
||||
// SSE notifications not supported in stateless mode
|
||||
app.get('/mcp', async (req: Request, res: Response) => {
|
||||
console.log('Received GET MCP request');
|
||||
res.writeHead(405).end(JSON.stringify({
|
||||
|
|
@ -359,6 +360,7 @@ app.get('/mcp', async (req: Request, res: Response) => {
|
|||
}));
|
||||
});
|
||||
|
||||
// Session termination not needed in stateless mode
|
||||
app.delete('/mcp', async (req: Request, res: Response) => {
|
||||
console.log('Received DELETE MCP request');
|
||||
res.writeHead(405).end(JSON.stringify({
|
||||
|
|
|
|||
Loading…
Reference in a new issue