@toolbaux/guardian 0.1.13 → 0.1.14
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/commands/mcp-serve.js +19 -3
- package/package.json +1 -1
|
@@ -354,8 +354,12 @@ async function handleRequest(req) {
|
|
|
354
354
|
case "initialize":
|
|
355
355
|
respond(req.id, {
|
|
356
356
|
protocolVersion: "2024-11-05",
|
|
357
|
-
capabilities: {
|
|
358
|
-
|
|
357
|
+
capabilities: {
|
|
358
|
+
tools: {},
|
|
359
|
+
resources: {},
|
|
360
|
+
prompts: {},
|
|
361
|
+
},
|
|
362
|
+
serverInfo: { name: "guardian", version: "0.1.13" },
|
|
359
363
|
});
|
|
360
364
|
break;
|
|
361
365
|
case "initialized":
|
|
@@ -364,6 +368,15 @@ async function handleRequest(req) {
|
|
|
364
368
|
case "tools/list":
|
|
365
369
|
respond(req.id, { tools: TOOLS });
|
|
366
370
|
break;
|
|
371
|
+
case "resources/list":
|
|
372
|
+
respond(req.id, { resources: [] });
|
|
373
|
+
break;
|
|
374
|
+
case "resources/templates/list":
|
|
375
|
+
respond(req.id, { resourceTemplates: [] });
|
|
376
|
+
break;
|
|
377
|
+
case "prompts/list":
|
|
378
|
+
respond(req.id, { prompts: [] });
|
|
379
|
+
break;
|
|
367
380
|
case "tools/call": {
|
|
368
381
|
const toolName = req.params?.name;
|
|
369
382
|
const toolArgs = req.params?.arguments || {};
|
|
@@ -400,7 +413,10 @@ async function handleRequest(req) {
|
|
|
400
413
|
break;
|
|
401
414
|
}
|
|
402
415
|
default:
|
|
403
|
-
|
|
416
|
+
// Notifications (no id) don't need a response
|
|
417
|
+
if (req.id != null) {
|
|
418
|
+
respondError(req.id, -32601, `Method not found: ${req.method}`);
|
|
419
|
+
}
|
|
404
420
|
}
|
|
405
421
|
}
|
|
406
422
|
// ── Entry point ──
|
package/package.json
CHANGED