@syke1/mcp-server 1.4.0 → 1.4.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/dist/config.d.ts +4 -0
- package/dist/config.js +23 -0
- package/dist/index.js +30 -4
- package/dist/license/validator.d.ts +4 -0
- package/dist/license/validator.js +14 -0
- package/dist/web/public/app.js +672 -28
- package/dist/web/public/index.html +62 -0
- package/dist/web/public/style.css +683 -2
- package/dist/web/server.d.ts +6 -1
- package/dist/web/server.js +17 -1
- package/package.json +1 -1
package/dist/web/server.js
CHANGED
|
@@ -226,7 +226,7 @@ function acknowledgeWarnings() {
|
|
|
226
226
|
function getAllWarnings() {
|
|
227
227
|
return [...warningStore];
|
|
228
228
|
}
|
|
229
|
-
function createWebServer(getGraphFn, initialFileCache, switchProjectFn, getProjectRoot, getPackageName, getLicenseStatus, hasAIKeyFn) {
|
|
229
|
+
function createWebServer(getGraphFn, initialFileCache, switchProjectFn, getProjectRoot, getPackageName, getLicenseStatus, hasAIKeyFn, setLicenseKeyFn) {
|
|
230
230
|
const app = (0, express_1.default)();
|
|
231
231
|
app.use(express_1.default.json());
|
|
232
232
|
// Serve static files from public/
|
|
@@ -746,11 +746,27 @@ function createWebServer(getGraphFn, initialFileCache, switchProjectFn, getProje
|
|
|
746
746
|
fileCount: graph.files.size,
|
|
747
747
|
edgeCount,
|
|
748
748
|
plan: license?.plan || "free",
|
|
749
|
+
planSource: license?.source || "default",
|
|
749
750
|
expiresAt: license?.expiresAt || null,
|
|
750
751
|
freeFileLimit: 50,
|
|
751
752
|
sykeVersion,
|
|
752
753
|
});
|
|
753
754
|
});
|
|
755
|
+
// POST /api/set-license-key — Set or remove license key via dashboard
|
|
756
|
+
app.post("/api/set-license-key", async (req, res) => {
|
|
757
|
+
if (!setLicenseKeyFn) {
|
|
758
|
+
res.status(501).json({ success: false, error: "Not supported" });
|
|
759
|
+
return;
|
|
760
|
+
}
|
|
761
|
+
const { key } = req.body;
|
|
762
|
+
try {
|
|
763
|
+
const result = await setLicenseKeyFn(key || null);
|
|
764
|
+
res.json(result);
|
|
765
|
+
}
|
|
766
|
+
catch (err) {
|
|
767
|
+
res.status(500).json({ success: false, error: err.message || "Unknown error" });
|
|
768
|
+
}
|
|
769
|
+
});
|
|
754
770
|
// GET /api/browse-dirs — List subdirectories for folder browser
|
|
755
771
|
app.get("/api/browse-dirs", (req, res) => {
|
|
756
772
|
const dirPath = req.query.path || (process.platform === "win32" ? "C:\\" : "/");
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@syke1/mcp-server",
|
|
3
|
-
"version": "1.4.
|
|
3
|
+
"version": "1.4.2",
|
|
4
4
|
"mcpName": "io.github.khalomsky/syke",
|
|
5
5
|
"description": "AI code impact analysis MCP server — dependency graphs, cascade detection, and a mandatory build gate for AI coding agents",
|
|
6
6
|
"main": "dist/index.js",
|