@loupekit/mcp 0.5.1-next.19 → 0.5.2-next.20
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/index.js +10 -2
- package/package.json +2 -2
package/dist/index.js
CHANGED
|
@@ -4,6 +4,7 @@
|
|
|
4
4
|
import { McpServer } from "@modelcontextprotocol/sdk/server/mcp.js";
|
|
5
5
|
import { StdioServerTransport } from "@modelcontextprotocol/sdk/server/stdio.js";
|
|
6
6
|
import { pathToFileURL } from "url";
|
|
7
|
+
import { realpathSync } from "fs";
|
|
7
8
|
import { argv } from "process";
|
|
8
9
|
import { z } from "zod";
|
|
9
10
|
var API = (process.env.LOUPE_API || "http://localhost:8787").replace(/\/$/, "");
|
|
@@ -73,7 +74,7 @@ async function updateStatus({ id, status }) {
|
|
|
73
74
|
await api(`/v1/comments/${encodeURIComponent(id)}`, { method: "PATCH", body: JSON.stringify({ status }) });
|
|
74
75
|
return wrap(`#${id} \u2192 ${status}`);
|
|
75
76
|
}
|
|
76
|
-
var server = new McpServer({ name: "loupe", version: "0.5.
|
|
77
|
+
var server = new McpServer({ name: "loupe", version: "0.5.2" });
|
|
77
78
|
server.tool(
|
|
78
79
|
"list_comments",
|
|
79
80
|
"List Loupe product-feedback comments for the project as a task backlog. Use this to see what a PM has flagged, then work through the items.",
|
|
@@ -95,7 +96,14 @@ server.tool(
|
|
|
95
96
|
{ id: z.string(), status: z.enum(["open", "in_progress", "done"]) },
|
|
96
97
|
updateStatus
|
|
97
98
|
);
|
|
98
|
-
|
|
99
|
+
function isEntrypoint() {
|
|
100
|
+
try {
|
|
101
|
+
return import.meta.url === pathToFileURL(realpathSync(argv[1] ?? "")).href;
|
|
102
|
+
} catch {
|
|
103
|
+
return false;
|
|
104
|
+
}
|
|
105
|
+
}
|
|
106
|
+
if (isEntrypoint()) {
|
|
99
107
|
await server.connect(new StdioServerTransport());
|
|
100
108
|
console.error(`[loupe-mcp] connected \xB7 project=${PROJECT_KEY} \xB7 api=${API}`);
|
|
101
109
|
}
|
package/package.json
CHANGED
|
@@ -5,7 +5,7 @@
|
|
|
5
5
|
"email": "m.ashraf.saed@gmail.com",
|
|
6
6
|
"url": "https://www.linkedin.com/in/mohamedashrafelsaed/"
|
|
7
7
|
},
|
|
8
|
-
"version": "0.5.
|
|
8
|
+
"version": "0.5.2-next.20",
|
|
9
9
|
"description": "MCP server that exposes Loupe comments to Claude Code as an actionable, fully-contextualized backlog.",
|
|
10
10
|
"keywords": [
|
|
11
11
|
"loupe",
|
|
@@ -46,6 +46,6 @@
|
|
|
46
46
|
"zod": "^3.24.1"
|
|
47
47
|
},
|
|
48
48
|
"devDependencies": {
|
|
49
|
-
"@loupekit/shared": "0.5.
|
|
49
|
+
"@loupekit/shared": "0.5.2-next.20"
|
|
50
50
|
}
|
|
51
51
|
}
|