@opengeni/api-router 3.0.1-canary.2 → 3.0.1-canary.3
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
CHANGED
|
@@ -7,7 +7,7 @@ import {
|
|
|
7
7
|
createOpenGeniSlackBotInteractionClient,
|
|
8
8
|
startSlackInteractionPump,
|
|
9
9
|
startTemporalScheduleCleanupPump
|
|
10
|
-
} from "./chunk-
|
|
10
|
+
} from "./chunk-ICAFSKJY.js";
|
|
11
11
|
|
|
12
12
|
// src/index.ts
|
|
13
13
|
import { scheduledTaskKnowledgeSource } from "@opengeni/contracts";
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@opengeni/api-router",
|
|
3
|
-
"version": "3.0.1-canary.
|
|
3
|
+
"version": "3.0.1-canary.3",
|
|
4
4
|
"description": "OpenGeni HTTP surface: the Hono adapter/router (createApp), routes, MCP HTTP transport, and HTTP access adapters over @opengeni/core. An engine-distribution surface — its runtime closure includes engine-internal packages.",
|
|
5
5
|
"license": "Apache-2.0",
|
|
6
6
|
"repository": {
|
|
@@ -43,24 +43,24 @@
|
|
|
43
43
|
"@hono/zod-validator": "^0.7.6",
|
|
44
44
|
"@llamaindex/liteparse": "2.14.2",
|
|
45
45
|
"@modelcontextprotocol/sdk": "^1.29.0",
|
|
46
|
-
"@opengeni/agent-proto": "^0.6.0-canary.
|
|
47
|
-
"@opengeni/artifact-tool": "^0.3.29-canary.
|
|
48
|
-
"@opengeni/capabilities": "^0.3.4-canary.
|
|
49
|
-
"@opengeni/codemode": "^0.5.9-canary.
|
|
50
|
-
"@opengeni/codex": "^0.2.23-canary.
|
|
51
|
-
"@opengeni/config": "^1.2.2-canary.
|
|
52
|
-
"@opengeni/contracts": "^4.1.0-canary.
|
|
53
|
-
"@opengeni/core": "^3.0.1-canary.
|
|
54
|
-
"@opengeni/db": "^5.0.1-canary.
|
|
55
|
-
"@opengeni/documents": "^0.8.30-canary.
|
|
56
|
-
"@opengeni/events": "^0.4.28-canary.
|
|
57
|
-
"@opengeni/github": "^0.7.13-canary.
|
|
58
|
-
"@opengeni/network": "^0.3.1-canary.
|
|
59
|
-
"@opengeni/observability": "^0.8.29-canary.
|
|
60
|
-
"@opengeni/runtime": "^3.0.1-canary.
|
|
61
|
-
"@opengeni/storage": "^0.2.130-canary.
|
|
62
|
-
"@opengeni/tool-gateway": "^0.1.10-canary.
|
|
63
|
-
"@opengeni/xai-subscription": "^0.1.4-canary.
|
|
46
|
+
"@opengeni/agent-proto": "^0.6.0-canary.8",
|
|
47
|
+
"@opengeni/artifact-tool": "^0.3.29-canary.3",
|
|
48
|
+
"@opengeni/capabilities": "^0.3.4-canary.3",
|
|
49
|
+
"@opengeni/codemode": "^0.5.9-canary.3",
|
|
50
|
+
"@opengeni/codex": "^0.2.23-canary.5",
|
|
51
|
+
"@opengeni/config": "^1.2.2-canary.3",
|
|
52
|
+
"@opengeni/contracts": "^4.1.0-canary.3",
|
|
53
|
+
"@opengeni/core": "^3.0.1-canary.3",
|
|
54
|
+
"@opengeni/db": "^5.0.1-canary.3",
|
|
55
|
+
"@opengeni/documents": "^0.8.30-canary.3",
|
|
56
|
+
"@opengeni/events": "^0.4.28-canary.3",
|
|
57
|
+
"@opengeni/github": "^0.7.13-canary.3",
|
|
58
|
+
"@opengeni/network": "^0.3.1-canary.20",
|
|
59
|
+
"@opengeni/observability": "^0.8.29-canary.3",
|
|
60
|
+
"@opengeni/runtime": "^3.0.1-canary.3",
|
|
61
|
+
"@opengeni/storage": "^0.2.130-canary.3",
|
|
62
|
+
"@opengeni/tool-gateway": "^0.1.10-canary.3",
|
|
63
|
+
"@opengeni/xai-subscription": "^0.1.4-canary.20",
|
|
64
64
|
"@temporalio/client": "^1.17.0",
|
|
65
65
|
"better-auth": "^1.6.14",
|
|
66
66
|
"hono": "^4.12.18",
|
package/src/routes/plugins.ts
CHANGED
|
@@ -48,6 +48,7 @@ import {
|
|
|
48
48
|
getConnectionMetadata,
|
|
49
49
|
getInstalledPluginPackage,
|
|
50
50
|
getPluginPackageUninstallPreview,
|
|
51
|
+
PluginUninstallPreviewChangedError,
|
|
51
52
|
integrationBindingKey,
|
|
52
53
|
installApiIntegration,
|
|
53
54
|
installPluginMcpReference,
|
|
@@ -349,9 +350,14 @@ export function registerPluginRoutes(
|
|
|
349
350
|
|
|
350
351
|
app.get("/v1/workspaces/:workspaceId/plugins/:pluginKey/uninstall-preview", async (c) => {
|
|
351
352
|
const workspaceId = c.req.param("workspaceId");
|
|
352
|
-
await requireAccessGrant(c, deps, workspaceId, "workspace:read");
|
|
353
|
+
const grant = await requireAccessGrant(c, deps, workspaceId, "workspace:read");
|
|
353
354
|
const pluginKey = decodeURIComponent(c.req.param("pluginKey"));
|
|
354
|
-
const preview = await getPluginPackageUninstallPreview(
|
|
355
|
+
const preview = await getPluginPackageUninstallPreview(
|
|
356
|
+
deps.db,
|
|
357
|
+
workspaceId,
|
|
358
|
+
pluginKey,
|
|
359
|
+
grant.subjectId,
|
|
360
|
+
);
|
|
355
361
|
return c.json(PluginUninstallPreview.parse({ pluginKey, ...preview }));
|
|
356
362
|
});
|
|
357
363
|
|
|
@@ -378,11 +384,33 @@ export function registerPluginRoutes(
|
|
|
378
384
|
subjectId: grant.subjectId,
|
|
379
385
|
pluginKey,
|
|
380
386
|
expectedInstallationVersion: payload.expectedInstallationVersion,
|
|
387
|
+
...(payload.expectedPreviewToken
|
|
388
|
+
? { expectedPreviewToken: payload.expectedPreviewToken }
|
|
389
|
+
: {}),
|
|
381
390
|
idempotencyKey: payload.idempotencyKey,
|
|
382
391
|
})),
|
|
383
392
|
}),
|
|
384
393
|
);
|
|
385
394
|
} catch (error) {
|
|
395
|
+
if (error instanceof PluginUninstallPreviewChangedError) {
|
|
396
|
+
const preview = error.preview ?? {
|
|
397
|
+
pluginKey,
|
|
398
|
+
...(await getPluginPackageUninstallPreview(
|
|
399
|
+
deps.db,
|
|
400
|
+
workspaceId,
|
|
401
|
+
pluginKey,
|
|
402
|
+
grant.subjectId,
|
|
403
|
+
)),
|
|
404
|
+
};
|
|
405
|
+
return c.json(
|
|
406
|
+
{
|
|
407
|
+
code: error.code,
|
|
408
|
+
message: error.message,
|
|
409
|
+
preview: PluginUninstallPreview.parse(preview),
|
|
410
|
+
},
|
|
411
|
+
409,
|
|
412
|
+
);
|
|
413
|
+
}
|
|
386
414
|
throw pluginMutationHttpError(error);
|
|
387
415
|
}
|
|
388
416
|
});
|