signal-relay-mcp 1.0.0 → 1.0.2
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/package.json +3 -1
- package/src/index.ts +36 -0
package/package.json
CHANGED
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "signal-relay-mcp",
|
|
3
|
-
"version": "1.0.
|
|
3
|
+
"version": "1.0.2",
|
|
4
|
+
"mcpName": "io.github.SocioLogicAI/signal-relay",
|
|
4
5
|
"description": "MCP Server for SocioLogic Revenue Intelligence Platform - Interview synthetic personas, run research campaigns, and export insights",
|
|
5
6
|
"type": "module",
|
|
6
7
|
"main": "dist/index.js",
|
|
@@ -39,6 +40,7 @@
|
|
|
39
40
|
},
|
|
40
41
|
"devDependencies": {
|
|
41
42
|
"@cloudflare/workers-types": "^4.20241230.0",
|
|
43
|
+
"smithery": "^0.5.2",
|
|
42
44
|
"typescript": "^5.7.2",
|
|
43
45
|
"wrangler": "^4.59.2"
|
|
44
46
|
},
|
package/src/index.ts
CHANGED
|
@@ -354,6 +354,42 @@ export default {
|
|
|
354
354
|
});
|
|
355
355
|
}
|
|
356
356
|
|
|
357
|
+
// Server card for Smithery discovery (no auth required - must be before auth check)
|
|
358
|
+
// Format follows SEP-1649 spec: https://smithery.ai/docs/build/external#server-scanning
|
|
359
|
+
if (url.pathname === "/.well-known/mcp/server-card.json") {
|
|
360
|
+
const toolsWithSchema = TOOL_DEFINITIONS.map((t) => ({
|
|
361
|
+
name: t.name,
|
|
362
|
+
description: t.description,
|
|
363
|
+
inputSchema: zodToJsonSchema(t.inputSchema, {
|
|
364
|
+
target: "jsonSchema7",
|
|
365
|
+
$refStrategy: "none",
|
|
366
|
+
}),
|
|
367
|
+
}));
|
|
368
|
+
|
|
369
|
+
return new Response(
|
|
370
|
+
JSON.stringify({
|
|
371
|
+
serverInfo: {
|
|
372
|
+
name: "signal-relay-mcp",
|
|
373
|
+
version: "1.0.2",
|
|
374
|
+
},
|
|
375
|
+
authentication: {
|
|
376
|
+
required: true,
|
|
377
|
+
schemes: ["apiKey"],
|
|
378
|
+
instructions: "Get your API key at https://sociologic.ai/dashboard/api-keys (100 free credits on signup)",
|
|
379
|
+
},
|
|
380
|
+
tools: toolsWithSchema,
|
|
381
|
+
resources: [],
|
|
382
|
+
prompts: [],
|
|
383
|
+
}),
|
|
384
|
+
{
|
|
385
|
+
headers: {
|
|
386
|
+
"Content-Type": "application/json",
|
|
387
|
+
"Access-Control-Allow-Origin": "*",
|
|
388
|
+
},
|
|
389
|
+
}
|
|
390
|
+
);
|
|
391
|
+
}
|
|
392
|
+
|
|
357
393
|
// Early check of Content-Length header if present (optimization)
|
|
358
394
|
const contentLength = request.headers.get("Content-Length");
|
|
359
395
|
if (contentLength && parseInt(contentLength, 10) > MAX_REQUEST_SIZE) {
|