@frumu/tandem-panel 0.4.37 → 0.4.39
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/bin/setup.js +186 -75
- package/dist/assets/{index-C6soKUiJ.css → index-Cj42d_-Y.css} +1 -1
- package/dist/assets/index-DWi6ftxU.js +7376 -0
- package/dist/index.html +2 -2
- package/package.json +3 -3
- package/server/routes/aca.js +61 -0
- package/dist/assets/index-B4DAxlnB.js +0 -7376
package/dist/index.html
CHANGED
|
@@ -11,14 +11,14 @@
|
|
|
11
11
|
href="https://fonts.googleapis.com/css2?family=JetBrains+Mono:wght@400;600&family=Rubik:wght@500;700;800&family=Manrope:wght@400;500;600;700&display=swap"
|
|
12
12
|
rel="stylesheet"
|
|
13
13
|
/>
|
|
14
|
-
<script type="module" crossorigin src="/assets/index-
|
|
14
|
+
<script type="module" crossorigin src="/assets/index-DWi6ftxU.js"></script>
|
|
15
15
|
<link rel="modulepreload" crossorigin href="/assets/rolldown-runtime-Dgq8h090.js">
|
|
16
16
|
<link rel="modulepreload" crossorigin href="/assets/motion-CBnf8hfk.js">
|
|
17
17
|
<link rel="modulepreload" crossorigin href="/assets/react-query-_hsOQSt5.js">
|
|
18
18
|
<link rel="modulepreload" crossorigin href="/assets/preact-vendor-B239Onrg.js">
|
|
19
19
|
<link rel="modulepreload" crossorigin href="/assets/vendor-Dysht3Ll.js">
|
|
20
20
|
<link rel="modulepreload" crossorigin href="/assets/markdown-Dd89TVib.js">
|
|
21
|
-
<link rel="stylesheet" crossorigin href="/assets/index-
|
|
21
|
+
<link rel="stylesheet" crossorigin href="/assets/index-Cj42d_-Y.css">
|
|
22
22
|
</head>
|
|
23
23
|
<body>
|
|
24
24
|
<div id="app"></div>
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@frumu/tandem-panel",
|
|
3
|
-
"version": "0.4.
|
|
3
|
+
"version": "0.4.39",
|
|
4
4
|
"description": "Full web control center for Tandem Engine (chat, routines, swarm, memory, channels, and ops)",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"bin": {
|
|
@@ -46,8 +46,8 @@
|
|
|
46
46
|
"@fullcalendar/interaction": "6.1.20",
|
|
47
47
|
"@fullcalendar/react": "6.1.20",
|
|
48
48
|
"@fullcalendar/timegrid": "6.1.20",
|
|
49
|
-
"@frumu/tandem": "^0.4.
|
|
50
|
-
"@frumu/tandem-client": "^0.4.
|
|
49
|
+
"@frumu/tandem": "^0.4.39",
|
|
50
|
+
"@frumu/tandem-client": "^0.4.39",
|
|
51
51
|
"@tanstack/react-query": "^5.90.21",
|
|
52
52
|
"dompurify": "^3.3.1",
|
|
53
53
|
"lucide": "^0.575.0",
|
package/server/routes/aca.js
CHANGED
|
@@ -27,6 +27,67 @@ export function createAcaApiHandler(deps) {
|
|
|
27
27
|
|
|
28
28
|
const incoming = new URL(req.url, `http://127.0.0.1:${PORTAL_PORT}`);
|
|
29
29
|
const targetPath = incoming.pathname.replace(/^\/api\/aca/, "") || "/";
|
|
30
|
+
|
|
31
|
+
if (targetPath === "/overview" && req.method === "GET") {
|
|
32
|
+
const token = String(getAcaToken?.() || "aca-proxy").trim();
|
|
33
|
+
const headers = copyRequestHeaders(req);
|
|
34
|
+
if (token) headers.set("authorization", `Bearer ${token}`);
|
|
35
|
+
headers.set("content-type", "application/json");
|
|
36
|
+
headers.set("accept", "application/json");
|
|
37
|
+
|
|
38
|
+
let upstream;
|
|
39
|
+
try {
|
|
40
|
+
upstream = await fetch(`${baseUrl}/mcp`, {
|
|
41
|
+
method: "POST",
|
|
42
|
+
headers,
|
|
43
|
+
body: JSON.stringify({
|
|
44
|
+
jsonrpc: "2.0",
|
|
45
|
+
id: "aca-overview",
|
|
46
|
+
method: "tools/call",
|
|
47
|
+
params: { name: "describe_aca", arguments: {} },
|
|
48
|
+
}),
|
|
49
|
+
});
|
|
50
|
+
} catch (error) {
|
|
51
|
+
sendJson(res, 502, {
|
|
52
|
+
ok: false,
|
|
53
|
+
error: `ACA overview is unavailable: ${error instanceof Error ? error.message : String(error)}`,
|
|
54
|
+
});
|
|
55
|
+
return true;
|
|
56
|
+
}
|
|
57
|
+
|
|
58
|
+
let payload;
|
|
59
|
+
try {
|
|
60
|
+
payload = await upstream.json();
|
|
61
|
+
} catch {
|
|
62
|
+
payload = null;
|
|
63
|
+
}
|
|
64
|
+
|
|
65
|
+
if (!upstream.ok) {
|
|
66
|
+
sendJson(res, upstream.status, {
|
|
67
|
+
ok: false,
|
|
68
|
+
error: String(payload?.error?.message || payload?.detail || `ACA overview failed (${upstream.status})`),
|
|
69
|
+
});
|
|
70
|
+
return true;
|
|
71
|
+
}
|
|
72
|
+
|
|
73
|
+
const overview = payload?.result?.overview;
|
|
74
|
+
if (!overview || typeof overview !== "object") {
|
|
75
|
+
sendJson(res, 502, {
|
|
76
|
+
ok: false,
|
|
77
|
+
error: "ACA overview tool returned an unexpected payload.",
|
|
78
|
+
});
|
|
79
|
+
return true;
|
|
80
|
+
}
|
|
81
|
+
|
|
82
|
+
sendJson(res, 200, {
|
|
83
|
+
ok: true,
|
|
84
|
+
source: "aca-mcp",
|
|
85
|
+
fetched_at_ms: Date.now(),
|
|
86
|
+
overview,
|
|
87
|
+
});
|
|
88
|
+
return true;
|
|
89
|
+
}
|
|
90
|
+
|
|
30
91
|
const targetUrl = `${baseUrl}${targetPath}${incoming.search}`;
|
|
31
92
|
const token = String(getAcaToken?.() || "aca-proxy").trim();
|
|
32
93
|
const needsAuth = targetPath !== "/health";
|