@opengeni/sdk 3.3.2 → 3.4.0
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/README.md +1007 -72
- package/dist/adapters/express.d.ts +31 -0
- package/dist/adapters/express.js +87 -0
- package/dist/adapters/express.js.map +1 -0
- package/dist/adapters/hono.d.ts +16 -0
- package/dist/adapters/hono.js +8 -0
- package/dist/adapters/hono.js.map +1 -0
- package/dist/adapters/next.d.ts +29 -0
- package/dist/adapters/next.js +22 -0
- package/dist/adapters/next.js.map +1 -0
- package/dist/allowance-refusal.d.ts +2 -0
- package/dist/allowance-refusal.js +50 -0
- package/dist/allowance-refusal.js.map +1 -0
- package/dist/app-links.d.ts +42 -0
- package/dist/app-links.js +66 -0
- package/dist/app-links.js.map +1 -0
- package/dist/artifact-catalog.d.ts +40 -0
- package/dist/artifact-client.d.ts +20 -8
- package/dist/artifacts.d.ts +1 -1
- package/dist/artifacts.js +8 -6
- package/dist/automations.js +8 -2
- package/dist/automations.js.map +1 -1
- package/dist/azure-live-transport.d.ts +32 -0
- package/dist/browser.d.ts +7 -2
- package/dist/browser.js +27 -5
- package/dist/chat/fold.d.ts +75 -0
- package/dist/chat/handler.d.ts +41 -0
- package/dist/chat/http.d.ts +67 -0
- package/dist/chat/ids.d.ts +34 -0
- package/dist/chat/index.d.ts +9 -0
- package/dist/chat/index.js +1369 -0
- package/dist/chat/index.js.map +1 -0
- package/dist/chat/openai.d.ts +30 -0
- package/dist/chat/opengeni.d.ts +129 -0
- package/dist/chat/types.d.ts +207 -0
- package/dist/chat/vercel.d.ts +49 -0
- package/dist/chats.d.ts +8 -0
- package/dist/chunk-4AHR4KGA.js +301 -0
- package/dist/chunk-4AHR4KGA.js.map +1 -0
- package/dist/chunk-6GYGMLX4.js +332 -0
- package/dist/chunk-6GYGMLX4.js.map +1 -0
- package/dist/chunk-7EWT3PV6.js +368 -0
- package/dist/chunk-7EWT3PV6.js.map +1 -0
- package/dist/chunk-FTWVVPR6.js +1665 -0
- package/dist/chunk-FTWVVPR6.js.map +1 -0
- package/dist/{chunk-VYCTL62C.js → chunk-GZQSWAKD.js} +1 -1
- package/dist/chunk-GZQSWAKD.js.map +1 -0
- package/dist/chunk-KGEABAID.js +71 -0
- package/dist/chunk-KGEABAID.js.map +1 -0
- package/dist/{chunk-YKZME56C.js → chunk-KWADQ227.js} +3 -3
- package/dist/{chunk-YKZME56C.js.map → chunk-KWADQ227.js.map} +1 -1
- package/dist/{chunk-JUS2UYRP.js → chunk-NCU5OAN7.js} +27 -2
- package/dist/chunk-NCU5OAN7.js.map +1 -0
- package/dist/{chunk-YXQX7RQT.js → chunk-OI5YLASH.js} +73 -2
- package/dist/chunk-OI5YLASH.js.map +1 -0
- package/dist/chunk-OV3POE62.js +359 -0
- package/dist/chunk-OV3POE62.js.map +1 -0
- package/dist/chunk-P7UWKORG.js +561 -0
- package/dist/chunk-P7UWKORG.js.map +1 -0
- package/dist/chunk-QGEIL4TR.js +195 -0
- package/dist/chunk-QGEIL4TR.js.map +1 -0
- package/dist/{chunk-TRNI7KEO.js → chunk-S2NLS3ES.js} +3669 -1281
- package/dist/chunk-S2NLS3ES.js.map +1 -0
- package/dist/chunk-UM4ZXXJR.js +9 -0
- package/dist/chunk-UM4ZXXJR.js.map +1 -0
- package/dist/{chunk-QT3KFVDP.js → chunk-UME3X7CP.js} +28 -32
- package/dist/chunk-UME3X7CP.js.map +1 -0
- package/dist/chunk-VT4YM4XQ.js +210 -0
- package/dist/chunk-VT4YM4XQ.js.map +1 -0
- package/dist/chunk-WSYYXONG.js +1602 -0
- package/dist/chunk-WSYYXONG.js.map +1 -0
- package/dist/{chunk-C2H7HBNP.js → chunk-WVCJRSGJ.js} +119 -14
- package/dist/chunk-WVCJRSGJ.js.map +1 -0
- package/dist/chunk-X5ITQVXE.js +15 -0
- package/dist/chunk-X5ITQVXE.js.map +1 -0
- package/dist/chunk-XA7HVIHI.js +126 -0
- package/dist/chunk-XA7HVIHI.js.map +1 -0
- package/dist/{chunk-KKRO2VCP.js → chunk-YJCHB7R3.js} +60 -12
- package/dist/chunk-YJCHB7R3.js.map +1 -0
- package/dist/chunk-YKIHNLWD.js +153 -0
- package/dist/chunk-YKIHNLWD.js.map +1 -0
- package/dist/chunk-ZDUBPV33.js +277 -0
- package/dist/chunk-ZDUBPV33.js.map +1 -0
- package/dist/client.d.ts +1068 -118
- package/dist/codex-realtime-controller.d.ts +13 -0
- package/dist/codex-realtime-controller.js +4 -2
- package/dist/codex-realtime-v3-wire.d.ts +3 -2
- package/dist/codex-realtime.d.ts +5 -1
- package/dist/company-brain.d.ts +1 -11
- package/dist/core.d.ts +7 -2
- package/dist/core.js +25 -6
- package/dist/deprecation.d.ts +47 -0
- package/dist/document-authority-client.d.ts +24 -2
- package/dist/document-authority.js +7 -5
- package/dist/editable-artifacts/index.d.ts +1 -1
- package/dist/editable-artifacts/types.d.ts +12 -2
- package/dist/editable-artifacts.js +19 -3
- package/dist/editable-artifacts.js.map +1 -1
- package/dist/embedding-client.d.ts +129 -0
- package/dist/errors.d.ts +76 -1
- package/dist/external-vault-receiver.d.ts +203 -0
- package/dist/external-vault-receiver.js +564 -0
- package/dist/external-vault-receiver.js.map +1 -0
- package/dist/feedback.d.ts +23 -0
- package/dist/gateway-realtime-transport.js +1 -1
- package/dist/github-repositories.d.ts +10 -0
- package/dist/github-repositories.js +36 -0
- package/dist/github-repositories.js.map +1 -0
- package/dist/index.d.ts +62 -11
- package/dist/index.js +557 -338
- package/dist/index.js.map +1 -1
- package/dist/insights-usage.d.ts +33 -0
- package/dist/insights-usage.js +7 -0
- package/dist/insights-usage.js.map +1 -0
- package/dist/interaction.d.ts +165 -71
- package/dist/interaction.js +2 -2
- package/dist/knowledge.d.ts +7 -0
- package/dist/knowledge.js +20 -0
- package/dist/knowledge.js.map +1 -0
- package/dist/known-tools.d.ts +4 -0
- package/dist/message-links.d.ts +68 -0
- package/dist/model-context.d.ts +68 -0
- package/dist/model-display.d.ts +2 -0
- package/dist/model-display.js +17 -0
- package/dist/model-display.js.map +1 -0
- package/dist/model-picker-order.d.ts +1 -0
- package/dist/model-picker-order.js +10 -0
- package/dist/model-picker-order.js.map +1 -0
- package/dist/organization-integration-policy.d.ts +26 -0
- package/dist/organization-integration-policy.js +26 -0
- package/dist/organization-integration-policy.js.map +1 -0
- package/dist/pr-review-client.d.ts +1 -1
- package/dist/pr-review.d.ts +1 -1
- package/dist/pr-review.js.map +1 -1
- package/dist/preference-registry.d.ts +1 -1
- package/dist/prepared-mcp-setup.d.ts +5 -0
- package/dist/proxy.d.ts +13 -11
- package/dist/realtime.d.ts +1 -1
- package/dist/realtime.js +253 -7
- package/dist/realtime.js.map +1 -1
- package/dist/session-history-import.d.ts +22 -0
- package/dist/session-history-import.js +36 -0
- package/dist/session-history-import.js.map +1 -0
- package/dist/session-list-entries.d.ts +1 -0
- package/dist/session-list-entries.js +7 -0
- package/dist/session-list-entries.js.map +1 -0
- package/dist/session-message-search.d.ts +53 -0
- package/dist/session-proxy-client.d.ts +28 -0
- package/dist/session-proxy.d.ts +334 -0
- package/dist/session-proxy.js +24 -0
- package/dist/session-proxy.js.map +1 -0
- package/dist/session-titles.d.ts +2 -28
- package/dist/session-usage-limits.d.ts +10 -0
- package/dist/session-usage-limits.js +43 -0
- package/dist/session-usage-limits.js.map +1 -0
- package/dist/shared-catalog-loader.d.ts +34 -0
- package/dist/site-ai.d.ts +35 -0
- package/dist/site-bridge-host.d.ts +112 -0
- package/dist/site-bridge-host.js +286 -0
- package/dist/site-bridge-host.js.map +1 -0
- package/dist/site-browser-entry.d.ts +1 -0
- package/dist/site-browser-runtime.gen.d.ts +1 -0
- package/dist/site-data.d.ts +178 -0
- package/dist/site-document.d.ts +5 -0
- package/dist/site-document.js +20 -0
- package/dist/site-document.js.map +1 -0
- package/dist/site-document.test.d.ts +1 -0
- package/dist/site-http.d.ts +17 -0
- package/dist/site-sql.d.ts +31 -0
- package/dist/site-tool-bridge.d.ts +57 -0
- package/dist/site.d.ts +186 -0
- package/dist/site.js +63 -0
- package/dist/site.js.map +1 -0
- package/dist/skills.d.ts +75 -0
- package/dist/sse.d.ts +1 -1
- package/dist/stream.d.ts +2 -0
- package/dist/tenant-workspaces.d.ts +47 -0
- package/dist/tenant-workspaces.js +8 -0
- package/dist/tenant-workspaces.js.map +1 -0
- package/dist/tool-auth.d.ts +87 -0
- package/dist/tool-auth.js +23 -0
- package/dist/tool-auth.js.map +1 -0
- package/dist/tool-display-metadata.d.ts +3 -0
- package/dist/tools-37DCTCNZ.js +12 -0
- package/dist/tools-37DCTCNZ.js.map +1 -0
- package/dist/tools.d.ts +81 -0
- package/dist/transcription.d.ts +1 -1
- package/dist/types.d.ts +2807 -583
- package/dist/usage-allowances.d.ts +36 -0
- package/dist/usage-allowances.js +80 -0
- package/dist/usage-allowances.js.map +1 -0
- package/dist/vault-types.d.ts +324 -0
- package/dist/vaults-api.d.ts +65 -0
- package/dist/workspace-artifacts.d.ts +47 -5
- package/dist/workspace-instruction-policies.d.ts +2 -2
- package/dist/workspace-integrations.d.ts +74 -0
- package/dist/workspace-integrations.js +67 -0
- package/dist/workspace-integrations.js.map +1 -0
- package/dist/workspace-state.d.ts +8 -71
- package/package.json +103 -5
- package/src/adapters/express.ts +136 -0
- package/src/adapters/hono.ts +18 -0
- package/src/adapters/next.ts +42 -0
- package/src/allowance-refusal.ts +5 -0
- package/src/app-links.ts +117 -0
- package/src/artifact-catalog.ts +51 -0
- package/src/artifact-client.ts +40 -49
- package/src/artifacts.ts +1 -0
- package/src/automations-client.ts +8 -2
- package/src/azure-live-transport.ts +286 -0
- package/src/browser.ts +37 -0
- package/src/chat/fold.ts +431 -0
- package/src/chat/handler.ts +240 -0
- package/src/chat/http.ts +257 -0
- package/src/chat/ids.ts +85 -0
- package/src/chat/index.ts +88 -0
- package/src/chat/openai.ts +439 -0
- package/src/chat/opengeni.ts +737 -0
- package/src/chat/types.ts +219 -0
- package/src/chat/vercel.ts +204 -0
- package/src/chats.ts +16 -0
- package/src/client.ts +5697 -1833
- package/src/codex-realtime-controller.ts +163 -8
- package/src/codex-realtime-v3-wire.ts +4 -3
- package/src/codex-realtime-v3.ts +12 -3
- package/src/codex-realtime.ts +11 -3
- package/src/company-brain.ts +0 -40
- package/src/core.ts +20 -0
- package/src/deprecation.ts +149 -0
- package/src/document-authority-client.ts +104 -1
- package/src/editable-artifacts/controller.ts +36 -2
- package/src/editable-artifacts/index.ts +1 -0
- package/src/editable-artifacts/types.ts +29 -16
- package/src/embedding-client.ts +519 -0
- package/src/errors.ts +303 -4
- package/src/external-vault-receiver.ts +914 -0
- package/src/feedback.ts +20 -0
- package/src/gateway-realtime-transport.ts +3 -3
- package/src/github-repositories.ts +60 -0
- package/src/index.ts +603 -65
- package/src/insights-usage.ts +64 -0
- package/src/interaction.ts +315 -93
- package/src/knowledge.ts +72 -0
- package/src/known-tools.ts +279 -0
- package/src/message-links.ts +178 -0
- package/src/model-context.ts +113 -0
- package/src/model-display.ts +11 -0
- package/src/model-picker-order.ts +6 -0
- package/src/organization-integration-policy.ts +54 -0
- package/src/pr-review-client.ts +1 -1
- package/src/pr-review.ts +1 -1
- package/src/preference-registry.ts +2 -0
- package/src/prepared-mcp-setup.ts +123 -0
- package/src/proxy.ts +23 -12
- package/src/realtime.ts +15 -6
- package/src/session-history-import.ts +84 -0
- package/src/session-list-entries.ts +1 -0
- package/src/session-message-search.ts +47 -0
- package/src/session-proxy-client.ts +68 -0
- package/src/session-proxy.ts +2098 -0
- package/src/session-titles.ts +8 -82
- package/src/session-usage-limits.ts +71 -0
- package/src/shared-catalog-loader.ts +169 -0
- package/src/site-ai.ts +284 -0
- package/src/site-bridge-host.ts +422 -0
- package/src/site-browser-entry.ts +6 -0
- package/src/site-browser-runtime.gen.ts +2 -0
- package/src/site-data.ts +372 -0
- package/src/site-document.test.ts +64 -0
- package/src/site-document.ts +18 -0
- package/src/site-http.ts +171 -0
- package/src/site-sql.ts +153 -0
- package/src/site-tool-bridge.ts +401 -0
- package/src/site.ts +878 -0
- package/src/skills.ts +69 -0
- package/src/sse.ts +9 -3
- package/src/stream.ts +33 -10
- package/src/tenant-workspaces.ts +148 -0
- package/src/tool-auth.ts +301 -0
- package/src/tool-display-metadata.ts +27 -0
- package/src/tools.ts +452 -0
- package/src/transcription.ts +3 -0
- package/src/types.ts +3170 -582
- package/src/usage-allowances.ts +189 -0
- package/src/vault-types.ts +379 -0
- package/src/vaults-api.ts +339 -0
- package/src/workspace-artifacts.ts +55 -6
- package/src/workspace-instruction-policies.ts +2 -1
- package/src/workspace-integrations.ts +402 -0
- package/src/workspace-state.ts +8 -82
- package/dist/chunk-C2H7HBNP.js.map +0 -1
- package/dist/chunk-C4DJPZRU.js +0 -119
- package/dist/chunk-C4DJPZRU.js.map +0 -1
- package/dist/chunk-JUS2UYRP.js.map +0 -1
- package/dist/chunk-KKRO2VCP.js.map +0 -1
- package/dist/chunk-QT3KFVDP.js.map +0 -1
- package/dist/chunk-TRNI7KEO.js.map +0 -1
- package/dist/chunk-VYCTL62C.js.map +0 -1
- package/dist/chunk-YXQX7RQT.js.map +0 -1
package/dist/index.js
CHANGED
|
@@ -1,15 +1,41 @@
|
|
|
1
1
|
import {
|
|
2
|
-
|
|
3
|
-
} from "./chunk-
|
|
2
|
+
OpenGeniEmbeddingClient
|
|
3
|
+
} from "./chunk-6GYGMLX4.js";
|
|
4
|
+
import "./chunk-UME3X7CP.js";
|
|
5
|
+
import "./chunk-OI5YLASH.js";
|
|
4
6
|
import {
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
7
|
+
humanizeModelSlug,
|
|
8
|
+
isRawModelLabel,
|
|
9
|
+
modelDisplayName,
|
|
10
|
+
modelSlug,
|
|
11
|
+
modelVendor
|
|
12
|
+
} from "./chunk-YKIHNLWD.js";
|
|
13
|
+
import {
|
|
14
|
+
DEFAULT_WORKSPACE_TRANSCRIPTION_POLICY,
|
|
15
|
+
authorizeTranscriptionAdapter,
|
|
16
|
+
createTranscriptionSessionRequest,
|
|
17
|
+
resolveWorkspaceTranscriptionPolicy,
|
|
18
|
+
resolveWorkspaceVoiceInputEnabled
|
|
19
|
+
} from "./chunk-GZQSWAKD.js";
|
|
20
|
+
import {
|
|
21
|
+
OPENGENI_WEBHOOK_HEADERS,
|
|
22
|
+
OpenGeniSignatureError,
|
|
23
|
+
verifyCredentialProviderRequest,
|
|
24
|
+
verifyWebhookEvent
|
|
25
|
+
} from "./chunk-VT4YM4XQ.js";
|
|
26
|
+
import {
|
|
27
|
+
OPENGENI_TEST_REQUEST_NIL_ID,
|
|
28
|
+
OPENGENI_WEBHOOK_TEST_EVENT_TYPE,
|
|
29
|
+
WORKSPACE_WEBHOOK_EVENT_TYPES,
|
|
30
|
+
signOpenGeniPayload,
|
|
31
|
+
verifyOpenGeniSignature
|
|
32
|
+
} from "./chunk-KGEABAID.js";
|
|
8
33
|
import {
|
|
9
34
|
CODEX_REALTIME_CONTEXT_APPEND_MAX_BYTES,
|
|
10
35
|
CodexRealtimeMicrophoneError,
|
|
11
36
|
acquireCodexRealtimeMicrophone,
|
|
12
37
|
codexRealtimeMicrophoneHealthy,
|
|
38
|
+
codexRealtimeRefusal,
|
|
13
39
|
contextAppendChunks,
|
|
14
40
|
createCodexRealtimeController,
|
|
15
41
|
createCodexRealtimeV3Bridge,
|
|
@@ -18,17 +44,70 @@ import {
|
|
|
18
44
|
parseCodexRealtimeV3Event,
|
|
19
45
|
projectSessionRealtimeLifecycle,
|
|
20
46
|
startCodexRealtimeWebrtc
|
|
21
|
-
} from "./chunk-
|
|
22
|
-
import "./chunk-YXQX7RQT.js";
|
|
47
|
+
} from "./chunk-WVCJRSGJ.js";
|
|
23
48
|
import {
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
} from "./chunk-
|
|
49
|
+
AUTOMATIC_SESSION_TITLE_FALLBACK,
|
|
50
|
+
deriveAutomaticSessionTitlePreview,
|
|
51
|
+
deriveSessionDisplayTitle,
|
|
52
|
+
sessionListEntry,
|
|
53
|
+
sessionTitleIsPending
|
|
54
|
+
} from "./chunk-ZDUBPV33.js";
|
|
55
|
+
import {
|
|
56
|
+
SESSION_SCOPE_HEADER,
|
|
57
|
+
artifactViewerCapability,
|
|
58
|
+
createSessionProxyHandler,
|
|
59
|
+
formatSseEvent,
|
|
60
|
+
isReservedOpenGeniLink,
|
|
61
|
+
openGeniConsolePath,
|
|
62
|
+
openGeniLinkScheme,
|
|
63
|
+
parseOpenGeniLink,
|
|
64
|
+
parseRetainedFileReference,
|
|
65
|
+
parseSandboxLink,
|
|
66
|
+
proxySessionEventStream,
|
|
67
|
+
resumeSequenceFromRequest,
|
|
68
|
+
sessionEventsToSseResponse,
|
|
69
|
+
sessionEventsToSseStream
|
|
70
|
+
} from "./chunk-FTWVVPR6.js";
|
|
71
|
+
import "./chunk-UM4ZXXJR.js";
|
|
72
|
+
import {
|
|
73
|
+
ToolRequestError,
|
|
74
|
+
verifyToolRequest
|
|
75
|
+
} from "./chunk-QGEIL4TR.js";
|
|
76
|
+
import {
|
|
77
|
+
createGatewayRealtimeTransportStarter,
|
|
78
|
+
createXaiSubscriptionRealtimeTransportStarter
|
|
79
|
+
} from "./chunk-KWADQ227.js";
|
|
80
|
+
import {
|
|
81
|
+
OPENGENI_SITE_BRIDGE_CANCEL,
|
|
82
|
+
OPENGENI_SITE_BRIDGE_CONNECT,
|
|
83
|
+
OPENGENI_SITE_BRIDGE_READY,
|
|
84
|
+
OPENGENI_SITE_BRIDGE_REQUEST,
|
|
85
|
+
OPENGENI_SITE_BRIDGE_RESPONSE,
|
|
86
|
+
OPENGENI_SITE_BRIDGE_SIGN_IN_METHOD,
|
|
87
|
+
OPENGENI_SITE_BRIDGE_VERSION,
|
|
88
|
+
OPENGENI_SITE_BRIDGE_VIEWER_METHOD,
|
|
89
|
+
OpenGeniSiteBridgeError,
|
|
90
|
+
createOpenGeniSiteClient,
|
|
91
|
+
createSiteToolBridge,
|
|
92
|
+
isOpenGeniSiteBridgeCancelMessage,
|
|
93
|
+
isOpenGeniSiteBridgeConnectMessage,
|
|
94
|
+
isOpenGeniSiteBridgeRequestMessage,
|
|
95
|
+
isSiteCatalogStaleError,
|
|
96
|
+
sanitizeOpenGeniSiteToolCallRequest
|
|
97
|
+
} from "./chunk-WSYYXONG.js";
|
|
98
|
+
import {
|
|
99
|
+
EMPTY_FINAL_REPLY_NOTICE,
|
|
100
|
+
turnCompletedWithEmptyFinalReply
|
|
101
|
+
} from "./chunk-OV3POE62.js";
|
|
30
102
|
import {
|
|
103
|
+
OpenGeniToolCallError,
|
|
104
|
+
OpenGeniToolReapprovalRequiredError,
|
|
105
|
+
OpenGeniToolsClient
|
|
106
|
+
} from "./chunk-P7UWKORG.js";
|
|
107
|
+
import {
|
|
108
|
+
asVaultClient,
|
|
31
109
|
generatedImageSandboxPathMatches,
|
|
110
|
+
parseDeprecationNotice,
|
|
32
111
|
parseGeneratedImageReceipt,
|
|
33
112
|
parseGeneratedVideoReceipt,
|
|
34
113
|
parseMediaGenerationResult,
|
|
@@ -36,13 +115,20 @@ import {
|
|
|
36
115
|
parseRetainedGeneratedVideoReference,
|
|
37
116
|
parseRetainedWorkspaceFileReference,
|
|
38
117
|
parseSandboxFileArtifactReceipt,
|
|
39
|
-
parseSseStream,
|
|
40
118
|
parseWorkspaceLiveEvent,
|
|
41
|
-
streamSessionEvents,
|
|
42
119
|
streamWorkspaceControlEvents,
|
|
43
120
|
streamWorkspaceInteractionRevisions,
|
|
44
|
-
streamWorkspaceLiveEvents
|
|
45
|
-
|
|
121
|
+
streamWorkspaceLiveEvents,
|
|
122
|
+
vaultErrorCode,
|
|
123
|
+
vaultErrorDetail,
|
|
124
|
+
vaultsApi
|
|
125
|
+
} from "./chunk-S2NLS3ES.js";
|
|
126
|
+
import "./chunk-X5ITQVXE.js";
|
|
127
|
+
import {
|
|
128
|
+
parseSseStream,
|
|
129
|
+
sessionEventStreamCoveredThrough,
|
|
130
|
+
streamSessionEvents
|
|
131
|
+
} from "./chunk-4AHR4KGA.js";
|
|
46
132
|
import {
|
|
47
133
|
DEFAULT_FILE_RESOURCE_MOUNT_ROOT,
|
|
48
134
|
GENERATED_VIDEO_MAX_BYTES,
|
|
@@ -57,7 +143,7 @@ import {
|
|
|
57
143
|
RETAINED_OUTPUT_MAX_PAGE_BYTES,
|
|
58
144
|
SANDBOX_FILE_ARTIFACT_MAX_BYTES,
|
|
59
145
|
SESSION_EVENT_TYPES
|
|
60
|
-
} from "./chunk-
|
|
146
|
+
} from "./chunk-NCU5OAN7.js";
|
|
61
147
|
import {
|
|
62
148
|
AttachedBrowserDeviceCollection,
|
|
63
149
|
AttachedBrowserDeviceResource,
|
|
@@ -99,313 +185,394 @@ import {
|
|
|
99
185
|
interactionControlFailureFromError,
|
|
100
186
|
parseBrowserFrameMetadata,
|
|
101
187
|
parseComputerFrameMetadata
|
|
102
|
-
} from "./chunk-
|
|
188
|
+
} from "./chunk-YJCHB7R3.js";
|
|
103
189
|
import {
|
|
190
|
+
OpenGeniAllowanceExhaustedError,
|
|
104
191
|
OpenGeniApiContractMismatchError,
|
|
105
192
|
OpenGeniApiError,
|
|
193
|
+
OpenGeniSecureContextRequiredError,
|
|
106
194
|
OpenGeniSessionListCursorError,
|
|
195
|
+
OpenGeniSessionUsageLimitReachedError,
|
|
196
|
+
OpenGeniSessionUsageLimitUnsupportedError,
|
|
197
|
+
OpenGeniSetupError,
|
|
107
198
|
OpenGeniStreamError,
|
|
199
|
+
formatErrorMessage,
|
|
108
200
|
isRetryableStreamError
|
|
109
|
-
} from "./chunk-
|
|
201
|
+
} from "./chunk-7EWT3PV6.js";
|
|
110
202
|
|
|
111
|
-
//
|
|
112
|
-
var
|
|
113
|
-
var
|
|
114
|
-
var
|
|
115
|
-
var
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
var URI_SCHEME_CANDIDATE_PATTERN = /\b[a-z][a-z0-9+.-]*:\S+/giu;
|
|
125
|
-
var WINDOWS_DRIVE_PATH_PATTERN = /^[a-z]:[\\/](?![\\/])[^:]*$/iu;
|
|
126
|
-
var SCHEMELESS_HOST_CANDIDATE_PATTERN = /\b(?:www\.)?(?:[a-z0-9](?:[a-z0-9-]{0,61}[a-z0-9])?\.)+[a-z](?:[a-z0-9-]{0,61}[a-z0-9])?(?::\d{1,5})?(?:[/?#][^\s]*)?/giu;
|
|
127
|
-
var SCHEMELESS_LOCAL_NETWORK_PATTERNS = [
|
|
128
|
-
/\blocalhost(?:(?::\d{1,5})(?:[/?#][^\s]*)?|[/?#][^\s]*)/iu,
|
|
129
|
-
/\b(?:(?:25[0-5]|2[0-4]\d|1?\d?\d)\.){3}(?:25[0-5]|2[0-4]\d|1?\d?\d)(?:(?::\d{1,5})(?:[/?#][^\s]*)?|[/?#][^\s]*)/u,
|
|
130
|
-
/\[(?=[0-9a-f:.]*:[0-9a-f:.]*\])[0-9a-f:.]+\](?:(?::\d{1,5})(?:[/?#][^\s]*)?|[/?#][^\s]*)/iu
|
|
131
|
-
];
|
|
132
|
-
var FILE_LIKE_HOST_SUFFIXES = /* @__PURE__ */ new Set([
|
|
133
|
-
"css",
|
|
134
|
-
"html",
|
|
135
|
-
"js",
|
|
136
|
-
"json",
|
|
137
|
-
"jsx",
|
|
138
|
-
"lock",
|
|
139
|
-
"md",
|
|
140
|
-
"sql",
|
|
141
|
-
"toml",
|
|
142
|
-
"ts",
|
|
143
|
-
"tsx",
|
|
144
|
-
"xml",
|
|
145
|
-
"yaml",
|
|
146
|
-
"yml"
|
|
147
|
-
]);
|
|
148
|
-
var DOTTED_TECHNOLOGY_PATH_AUTHORITIES = /* @__PURE__ */ new Set([
|
|
149
|
-
"ASP.NET",
|
|
150
|
-
"AWS.SDK",
|
|
151
|
-
"Microsoft.Extensions",
|
|
152
|
-
"System.IO"
|
|
153
|
-
]);
|
|
154
|
-
var SECRET_ASSIGNMENT_CANDIDATE_PATTERN = /(?:^|[^A-Za-z0-9])(?:(['"])([A-Za-z][A-Za-z0-9_. -]*)\1|([A-Za-z][A-Za-z0-9_.-]*))\s*[=:]\s*[^\s,;]+/gu;
|
|
155
|
-
var SECRET_LABEL_ASSIGNMENT_PATTERN = /\b(?:api[ _-]?key|access[ _-]?token|auth[ _-]?token|credential|credentials|password|passwd|private[ _-]?key|secret|token)\b\s*[=:]\s*[^\s,;]+/iu;
|
|
156
|
-
var SENSITIVE_ASSIGNMENT_KEY_SUFFIXES = /* @__PURE__ */ new Set([
|
|
157
|
-
"credential",
|
|
158
|
-
"credentials",
|
|
159
|
-
"password",
|
|
160
|
-
"passwd",
|
|
161
|
-
"secret",
|
|
162
|
-
"token"
|
|
163
|
-
]);
|
|
164
|
-
var COMPACT_SENSITIVE_ASSIGNMENT_KEY_SUFFIXES = [
|
|
165
|
-
"apikey",
|
|
166
|
-
"accesskey",
|
|
167
|
-
"accesskeyid",
|
|
168
|
-
"accesstoken",
|
|
169
|
-
"authtoken",
|
|
170
|
-
"credential",
|
|
171
|
-
"credentials",
|
|
172
|
-
"password",
|
|
173
|
-
"passwd",
|
|
174
|
-
"privatekey",
|
|
175
|
-
"secret",
|
|
176
|
-
"secretkey",
|
|
177
|
-
"token"
|
|
178
|
-
];
|
|
179
|
-
var SENSITIVE_ASSIGNMENT_KEY_WORD_SUFFIXES = [
|
|
180
|
-
["api", "key"],
|
|
181
|
-
["access", "key"],
|
|
182
|
-
["access", "key", "id"],
|
|
183
|
-
["auth", "key"],
|
|
184
|
-
["private", "key"],
|
|
185
|
-
["secret", "key"]
|
|
186
|
-
];
|
|
187
|
-
function hasWordSuffix(words, suffix) {
|
|
188
|
-
if (words.length < suffix.length) return false;
|
|
189
|
-
const offset = words.length - suffix.length;
|
|
190
|
-
return suffix.every((word, index) => words[offset + index] === word);
|
|
191
|
-
}
|
|
192
|
-
function containsSensitiveAssignment(value) {
|
|
193
|
-
for (const match of value.matchAll(SECRET_ASSIGNMENT_CANDIDATE_PATTERN)) {
|
|
194
|
-
const key = match[2] ?? match[3];
|
|
195
|
-
if (!key) continue;
|
|
196
|
-
const words = key.replace(/([a-z0-9])([A-Z])/g, "$1 $2").replace(/([A-Z]+)([A-Z][a-z])/g, "$1 $2").toLowerCase().split(/[^a-z0-9]+/).filter(Boolean);
|
|
197
|
-
const last = words.at(-1);
|
|
198
|
-
if (last && SENSITIVE_ASSIGNMENT_KEY_SUFFIXES.has(last)) return true;
|
|
199
|
-
if (last && COMPACT_SENSITIVE_ASSIGNMENT_KEY_SUFFIXES.some((suffix) => last.endsWith(suffix))) {
|
|
200
|
-
return true;
|
|
201
|
-
}
|
|
202
|
-
if (SENSITIVE_ASSIGNMENT_KEY_WORD_SUFFIXES.some((suffix) => hasWordSuffix(words, suffix))) {
|
|
203
|
-
return true;
|
|
204
|
-
}
|
|
205
|
-
}
|
|
206
|
-
return false;
|
|
207
|
-
}
|
|
208
|
-
function containsUriScheme(value) {
|
|
209
|
-
for (const match of value.matchAll(URI_SCHEME_CANDIDATE_PATTERN)) {
|
|
210
|
-
if (!WINDOWS_DRIVE_PATH_PATTERN.test(match[0])) return true;
|
|
211
|
-
}
|
|
212
|
-
return false;
|
|
213
|
-
}
|
|
214
|
-
function isDottedTechnologyPath(candidate) {
|
|
215
|
-
if (/[?:#]/u.test(candidate)) return false;
|
|
216
|
-
const [authority, ...pathSegments] = candidate.split("/");
|
|
217
|
-
if (!authority || pathSegments.length === 0 || pathSegments.some((segment) => !segment)) {
|
|
218
|
-
return false;
|
|
219
|
-
}
|
|
220
|
-
if (!DOTTED_TECHNOLOGY_PATH_AUTHORITIES.has(authority) || pathSegments.some((segment) => !/^[A-Z][A-Za-z0-9_-]*$/u.test(segment))) {
|
|
203
|
+
// src/prepared-mcp-setup.ts
|
|
204
|
+
var record = (value) => value !== null && typeof value === "object" && !Array.isArray(value);
|
|
205
|
+
var keys = (value, allowed) => Object.keys(value).every((key) => allowed.includes(key));
|
|
206
|
+
var text = (value, max, min = 1) => typeof value === "string" && value.length >= min && value.length <= max;
|
|
207
|
+
var trimmedText = (value, max) => typeof value === "string" && text(value.trim(), max);
|
|
208
|
+
var headerPart = (value) => text(value, 16384, 0) && !/[\r\n\0]/.test(value);
|
|
209
|
+
var fieldId = (value) => typeof value === "string" && /^[A-Za-z][A-Za-z0-9_]{0,63}$/.test(value);
|
|
210
|
+
var endpoint = (value) => {
|
|
211
|
+
if (!text(value, 2048)) return false;
|
|
212
|
+
try {
|
|
213
|
+
const url = new URL(value);
|
|
214
|
+
return url.protocol === "https:" && !url.username && !url.password && !url.search && !url.hash;
|
|
215
|
+
} catch {
|
|
221
216
|
return false;
|
|
222
217
|
}
|
|
223
|
-
|
|
224
|
-
|
|
225
|
-
|
|
226
|
-
|
|
227
|
-
|
|
228
|
-
|
|
229
|
-
|
|
230
|
-
|
|
231
|
-
|
|
232
|
-
|
|
233
|
-
|
|
234
|
-
|
|
235
|
-
|
|
236
|
-
|
|
237
|
-
|
|
238
|
-
|
|
239
|
-
|
|
240
|
-
|
|
241
|
-
|
|
242
|
-
|
|
243
|
-
|
|
244
|
-
|
|
245
|
-
}
|
|
246
|
-
function containsSensitiveAutomaticSessionTitleValue(value) {
|
|
247
|
-
const detectionValue = automaticTitleDetectionValue(value);
|
|
248
|
-
if (KNOWN_SENSITIVE_VALUE_PATTERNS.some((pattern) => pattern.test(detectionValue))) return true;
|
|
249
|
-
if (containsUriScheme(detectionValue)) return true;
|
|
250
|
-
if (containsSchemelessUrl(detectionValue)) return true;
|
|
251
|
-
if (SECRET_LABEL_ASSIGNMENT_PATTERN.test(detectionValue)) return true;
|
|
252
|
-
if (containsSensitiveAssignment(detectionValue)) return true;
|
|
253
|
-
if (OPAQUE_IDENTIFIER_PATTERN.test(detectionValue)) return true;
|
|
254
|
-
return false;
|
|
255
|
-
}
|
|
256
|
-
function automaticTitleGraphemes(value) {
|
|
257
|
-
if (titleSegmenter === void 0) {
|
|
258
|
-
titleSegmenter = typeof Intl.Segmenter === "function" ? new Intl.Segmenter(void 0, { granularity: "grapheme" }) : null;
|
|
259
|
-
}
|
|
260
|
-
if (titleSegmenter) {
|
|
261
|
-
return Array.from(titleSegmenter.segment(value), (part) => part.segment);
|
|
218
|
+
};
|
|
219
|
+
function parseCustomMcpSetupRequest(value) {
|
|
220
|
+
if (!record(value) || !keys(value, ["kind", "name", "endpointUrl", "rationale", "ownership", "mcpSetup"]) || value.kind !== "mcp" || !trimmedText(value.name, 256) || !endpoint(value.endpointUrl) || !trimmedText(value.rationale, 2e3))
|
|
221
|
+
return null;
|
|
222
|
+
const base = {
|
|
223
|
+
kind: "mcp",
|
|
224
|
+
name: value.name.trim(),
|
|
225
|
+
endpointUrl: value.endpointUrl,
|
|
226
|
+
rationale: value.rationale.trim()
|
|
227
|
+
};
|
|
228
|
+
if (value.ownership === void 0 && value.mcpSetup === void 0) return base;
|
|
229
|
+
if (value.ownership !== "personal" && value.ownership !== "workspace") return null;
|
|
230
|
+
const setup = value.mcpSetup;
|
|
231
|
+
if (!record(setup) || !keys(setup, ["name", "endpointUrl", "headers", "secretFields"]) || !trimmedText(setup.name, 256) || setup.name.trim() !== base.name || setup.endpointUrl !== base.endpointUrl || !Array.isArray(setup.headers) || setup.headers.length < 1 || setup.headers.length > 32 || !Array.isArray(setup.secretFields) || setup.secretFields.length > 32)
|
|
232
|
+
return null;
|
|
233
|
+
const fields = [];
|
|
234
|
+
const fieldIds = /* @__PURE__ */ new Set();
|
|
235
|
+
for (const field of setup.secretFields) {
|
|
236
|
+
if (!record(field) || !keys(field, ["id", "label"]) || !fieldId(field.id) || !trimmedText(field.label, 256) || fieldIds.has(field.id))
|
|
237
|
+
return null;
|
|
238
|
+
fieldIds.add(field.id);
|
|
239
|
+
fields.push({ id: field.id, label: field.label.trim() });
|
|
262
240
|
}
|
|
263
|
-
const
|
|
264
|
-
|
|
265
|
-
|
|
266
|
-
|
|
267
|
-
|
|
241
|
+
const headers = [];
|
|
242
|
+
const names = /* @__PURE__ */ new Set();
|
|
243
|
+
const used = /* @__PURE__ */ new Set();
|
|
244
|
+
for (const header of setup.headers) {
|
|
245
|
+
if (!record(header) || !text(header.name, 256) || !/^[!#$%&'*+.^_`|~0-9A-Za-z-]+$/.test(header.name))
|
|
246
|
+
return null;
|
|
247
|
+
const name = header.name.toLowerCase();
|
|
248
|
+
if (names.has(name)) return null;
|
|
249
|
+
names.add(name);
|
|
250
|
+
if ("value" in header) {
|
|
251
|
+
if (!keys(header, ["name", "value"]) || !headerPart(header.value) || !header.value || ["authorization", "proxy-authorization", "cookie", "x-api-key", "api-key"].includes(name))
|
|
252
|
+
return null;
|
|
253
|
+
headers.push({ name: header.name, value: header.value });
|
|
268
254
|
} else {
|
|
269
|
-
|
|
255
|
+
if (!keys(header, ["name", "secret", "prefix", "suffix"]) || !fieldId(header.secret) || !fieldIds.has(header.secret) || header.prefix !== void 0 && !headerPart(header.prefix) || header.suffix !== void 0 && !headerPart(header.suffix))
|
|
256
|
+
return null;
|
|
257
|
+
used.add(header.secret);
|
|
258
|
+
headers.push({
|
|
259
|
+
name: header.name,
|
|
260
|
+
secret: header.secret,
|
|
261
|
+
...header.prefix !== void 0 ? { prefix: header.prefix } : {},
|
|
262
|
+
...header.suffix !== void 0 ? { suffix: header.suffix } : {}
|
|
263
|
+
});
|
|
270
264
|
}
|
|
271
265
|
}
|
|
272
|
-
return
|
|
273
|
-
|
|
274
|
-
|
|
275
|
-
|
|
276
|
-
|
|
277
|
-
|
|
278
|
-
if (graphemes.length <= AUTOMATIC_SESSION_TITLE_MAX_GRAPHEMES) return wordBounded;
|
|
279
|
-
const prefix = graphemes.slice(0, AUTOMATIC_SESSION_TITLE_MAX_GRAPHEMES).join("");
|
|
280
|
-
const lastWhitespace = prefix.search(/\s+\S*$/u);
|
|
281
|
-
return (lastWhitespace >= 16 ? prefix.slice(0, lastWhitespace) : prefix).trimEnd();
|
|
266
|
+
if (used.size !== fieldIds.size) return null;
|
|
267
|
+
return {
|
|
268
|
+
...base,
|
|
269
|
+
ownership: value.ownership,
|
|
270
|
+
mcpSetup: { name: base.name, endpointUrl: base.endpointUrl, headers, secretFields: fields }
|
|
271
|
+
};
|
|
282
272
|
}
|
|
283
273
|
|
|
284
|
-
// src/
|
|
285
|
-
var
|
|
286
|
-
|
|
287
|
-
|
|
288
|
-
|
|
289
|
-
|
|
290
|
-
|
|
291
|
-
|
|
292
|
-
|
|
293
|
-
|
|
294
|
-
}
|
|
295
|
-
|
|
296
|
-
|
|
297
|
-
|
|
298
|
-
|
|
299
|
-
|
|
300
|
-
|
|
301
|
-
|
|
302
|
-
|
|
303
|
-
|
|
304
|
-
|
|
305
|
-
return title;
|
|
306
|
-
}
|
|
307
|
-
for (const key of options.metadataKeys ?? []) {
|
|
308
|
-
const value = input.metadata?.[key];
|
|
309
|
-
if (typeof value === "string" && value.trim().length > 0) {
|
|
310
|
-
return value.trim();
|
|
274
|
+
// ../contracts/src/tool-review-presentation.ts
|
|
275
|
+
var protectedName = /password|passwd|secret|credential|authorization|cookie|(^|[_-])token($|[_-])|api[_-]?key|accessToken|refreshToken|privateKey/i;
|
|
276
|
+
var protectedReviewField = (key, fields = []) => protectedName.test(key) || fields.includes(key) || fields.includes("*");
|
|
277
|
+
var bound = (value, limit) => value.length > limit ? `${value.slice(0, limit)}\u2026` : value;
|
|
278
|
+
function toolReviewFieldLabel(key) {
|
|
279
|
+
const label = key.replace(/([a-z0-9])([A-Z])/g, "$1 $2").replace(/[_-]+/g, " ").replace(/\bids?\b/gi, (word) => word.length === 3 ? "IDs" : "ID").replace(
|
|
280
|
+
/\b(api|url|uri|http|https|ip|sql|json|html)(s?)\b/gi,
|
|
281
|
+
(_word, name, plural) => `${name.toUpperCase()}${plural}`
|
|
282
|
+
).replace(
|
|
283
|
+
/(?<=\S\s+)([A-Z])([a-z]+)\b/g,
|
|
284
|
+
(_word, first, rest) => `${first.toLowerCase()}${rest}`
|
|
285
|
+
).trim();
|
|
286
|
+
return label.charAt(0).toUpperCase() + label.slice(1);
|
|
287
|
+
}
|
|
288
|
+
function decodeReviewArguments(value) {
|
|
289
|
+
let decoded = value;
|
|
290
|
+
if (typeof decoded === "string") {
|
|
291
|
+
try {
|
|
292
|
+
decoded = JSON.parse(decoded);
|
|
293
|
+
} catch {
|
|
294
|
+
return null;
|
|
311
295
|
}
|
|
312
296
|
}
|
|
313
|
-
return
|
|
314
|
-
}
|
|
315
|
-
|
|
316
|
-
|
|
317
|
-
|
|
318
|
-
|
|
319
|
-
|
|
320
|
-
|
|
321
|
-
|
|
322
|
-
|
|
297
|
+
return decoded && typeof decoded === "object" && !Array.isArray(decoded) ? decoded : null;
|
|
298
|
+
}
|
|
299
|
+
function safeReviewValue(value, key = "", protectedFields = [], depth = 0) {
|
|
300
|
+
if (protectedReviewField(key, protectedFields)) return "[Protected value]";
|
|
301
|
+
if (depth > 20) return "[Nested value; open this field for details]";
|
|
302
|
+
if (Array.isArray(value))
|
|
303
|
+
return value.map((entry) => safeReviewValue(entry, "", protectedFields, depth + 1));
|
|
304
|
+
if (value && typeof value === "object")
|
|
305
|
+
return Object.fromEntries(
|
|
306
|
+
Object.entries(value).map(([name, entry]) => [
|
|
307
|
+
name,
|
|
308
|
+
safeReviewValue(entry, name, protectedFields, depth + 1)
|
|
309
|
+
])
|
|
310
|
+
);
|
|
311
|
+
return value;
|
|
312
|
+
}
|
|
313
|
+
function valueText(value) {
|
|
314
|
+
return typeof value === "string" ? value : value === null ? "None" : typeof value === "boolean" ? value ? "Yes" : "No" : JSON.stringify(value) ?? "Unavailable";
|
|
315
|
+
}
|
|
316
|
+
var pointer = (name) => `/${name.replaceAll("~", "~0").replaceAll("/", "~1")}`;
|
|
317
|
+
var fieldPointer = (key, index, parent = "") => pointer(key).length > 256 || parent.length + pointer(key).length > 1024 ? `/~2${index}` : pointer(key);
|
|
318
|
+
function toolReviewFields(argumentsValue, context) {
|
|
319
|
+
const args = decodeReviewArguments(argumentsValue);
|
|
320
|
+
if (!args) return { fields: [], moreFields: 0 };
|
|
321
|
+
const entries = Object.entries(args);
|
|
322
|
+
if (context?.email) {
|
|
323
|
+
const email = toolReviewFields(context.email);
|
|
324
|
+
const original = toolReviewFields(args, { ...context, email: void 0 });
|
|
325
|
+
const fields = [
|
|
326
|
+
...email.fields.filter(
|
|
327
|
+
(field) => field.path !== "/contentSha256" && field.path !== "/htmlBody" && field.preview !== ""
|
|
328
|
+
).map((field) => ({
|
|
329
|
+
...field,
|
|
330
|
+
label: field.path === "/textBody" ? "Message" : field.label,
|
|
331
|
+
path: `/$email${field.path}`,
|
|
332
|
+
...field.path === "/attachments" ? {
|
|
333
|
+
preview: context.email.attachments.map((attachment) => attachment.name).join(", ").slice(0, 240)
|
|
334
|
+
} : {}
|
|
335
|
+
})),
|
|
336
|
+
...original.fields.filter(
|
|
337
|
+
(field) => ![
|
|
338
|
+
"/raw",
|
|
339
|
+
"/expectedContentSha256",
|
|
340
|
+
"/from",
|
|
341
|
+
"/to",
|
|
342
|
+
"/cc",
|
|
343
|
+
"/bcc",
|
|
344
|
+
"/subject",
|
|
345
|
+
"/body",
|
|
346
|
+
"/textBody",
|
|
347
|
+
"/htmlBody",
|
|
348
|
+
"/attachments"
|
|
349
|
+
].includes(field.path)
|
|
350
|
+
)
|
|
351
|
+
];
|
|
352
|
+
return {
|
|
353
|
+
fields: fields.slice(0, 16),
|
|
354
|
+
moreFields: original.moreFields + Math.max(0, fields.length - 16)
|
|
355
|
+
};
|
|
356
|
+
}
|
|
357
|
+
return {
|
|
358
|
+
moreFields: Math.max(0, entries.length - 16),
|
|
359
|
+
fields: entries.slice(0, 16).map(([key, value], index) => {
|
|
360
|
+
const hidden = protectedReviewField(key, context?.protectedFields);
|
|
361
|
+
const safe = hidden ? "[Protected value]" : value;
|
|
362
|
+
const count = !hidden && Array.isArray(value) ? value.length : void 0;
|
|
363
|
+
const compactList = !hidden && Array.isArray(value) && value.length > 0 && value.length <= 4 && value.every(
|
|
364
|
+
(entry) => typeof entry === "string" || typeof entry === "number" || typeof entry === "boolean"
|
|
365
|
+
) ? value.map(valueText).join(", ") : void 0;
|
|
366
|
+
const text2 = compactList !== void 0 ? compactList : count !== void 0 ? `${count.toLocaleString("en-US")} item${count === 1 ? "" : "s"}` : safe && typeof safe === "object" ? `${Object.keys(safe).length} field${Object.keys(safe).length === 1 ? "" : "s"}` : valueText(safe);
|
|
367
|
+
return {
|
|
368
|
+
path: fieldPointer(key, index),
|
|
369
|
+
label: bound(
|
|
370
|
+
(context?.fieldLabels && Object.hasOwn(context.fieldLabels, key) ? context.fieldLabels[key] : void 0) ?? toolReviewFieldLabel(key),
|
|
371
|
+
256
|
|
372
|
+
),
|
|
373
|
+
preview: bound(text2, 240),
|
|
374
|
+
...count !== void 0 ? { count } : {},
|
|
375
|
+
truncated: !hidden && (text2.length > 240 || compactList === void 0 && typeof value === "object" && value !== null),
|
|
376
|
+
...hidden ? { protected: true } : {}
|
|
377
|
+
};
|
|
378
|
+
})
|
|
379
|
+
};
|
|
323
380
|
}
|
|
324
|
-
function
|
|
325
|
-
const
|
|
326
|
-
|
|
327
|
-
|
|
328
|
-
|
|
329
|
-
|
|
330
|
-
|
|
331
|
-
|
|
332
|
-
|
|
333
|
-
|
|
381
|
+
function toolReviewAction(toolName, argumentsValue, context) {
|
|
382
|
+
const fallback = {
|
|
383
|
+
title: context?.title ?? bound(
|
|
384
|
+
toolReviewFieldLabel(
|
|
385
|
+
toolName.replace(/^mcp_[^_]+__/, "").replace(/^batch[_-](?=[a-z])/i, "")
|
|
386
|
+
),
|
|
387
|
+
256
|
|
388
|
+
),
|
|
389
|
+
approveLabel: "Approve action",
|
|
390
|
+
effects: []
|
|
334
391
|
};
|
|
335
|
-
return
|
|
336
|
-
|
|
337
|
-
|
|
338
|
-
|
|
339
|
-
|
|
340
|
-
|
|
341
|
-
|
|
342
|
-
|
|
343
|
-
|
|
344
|
-
|
|
345
|
-
|
|
346
|
-
|
|
347
|
-
|
|
348
|
-
|
|
349
|
-
|
|
350
|
-
|
|
351
|
-
|
|
352
|
-
|
|
353
|
-
|
|
354
|
-
|
|
355
|
-
|
|
356
|
-
|
|
392
|
+
if (context?.kind !== "gmail") return fallback;
|
|
393
|
+
const args = decodeReviewArguments(argumentsValue);
|
|
394
|
+
if (!args) return fallback;
|
|
395
|
+
const thread = toolName.endsWith("_thread");
|
|
396
|
+
const selectionKind = thread ? "threads" : "messages";
|
|
397
|
+
const ids = thread && typeof args.threadId === "string" ? [args.threadId] : Array.isArray(args.messageIds) ? args.messageIds : typeof args.messageId === "string" ? [args.messageId] : null;
|
|
398
|
+
const selectionCount = ids?.every((id) => typeof id === "string") ? new Set(ids).size : void 0;
|
|
399
|
+
const noun = selectionCount === void 0 ? thread ? "conversations" : "messages" : `${selectionCount.toLocaleString("en-US")} ${thread ? "conversation" : "message"}${selectionCount === 1 ? "" : "s"}`;
|
|
400
|
+
const addValues = toolName.startsWith("label_") ? args.labelIds : args.addLabelIds;
|
|
401
|
+
const adds = Array.isArray(addValues) ? addValues.filter((v) => typeof v === "string") : [];
|
|
402
|
+
const removeValues = toolName.startsWith("unlabel_") ? args.labelIds : args.removeLabelIds;
|
|
403
|
+
const removes = Array.isArray(removeValues) ? removeValues.filter((v) => typeof v === "string") : [];
|
|
404
|
+
const labelEffect = (label, adding) => {
|
|
405
|
+
const known = {
|
|
406
|
+
TRASH: ["Move to Trash", "Remove from Trash"],
|
|
407
|
+
INBOX: ["Move to Inbox", "Remove from Inbox"],
|
|
408
|
+
UNREAD: ["Mark as unread", "Mark as read"],
|
|
409
|
+
STARRED: ["Add star", "Remove star"],
|
|
410
|
+
SPAM: ["Mark as spam", "Remove from Spam"],
|
|
411
|
+
IMPORTANT: ["Mark as important", "Remove importance"]
|
|
412
|
+
};
|
|
413
|
+
return (Object.hasOwn(known, label) ? known[label]?.[adding ? 0 : 1] : void 0) ?? `${adding ? "Add" : "Remove"} label ${bound(label, 120)}`;
|
|
414
|
+
};
|
|
415
|
+
const effects = [
|
|
416
|
+
...adds.map((id) => labelEffect(id, true)),
|
|
417
|
+
...removes.map((id) => labelEffect(id, false))
|
|
418
|
+
];
|
|
419
|
+
if ([
|
|
420
|
+
"batch_modify_messages",
|
|
421
|
+
"modify_message",
|
|
422
|
+
"modify_thread",
|
|
423
|
+
"label_message",
|
|
424
|
+
"label_thread",
|
|
425
|
+
"unlabel_message",
|
|
426
|
+
"unlabel_thread"
|
|
427
|
+
].includes(toolName)) {
|
|
428
|
+
const trash = adds.includes("TRASH");
|
|
429
|
+
return {
|
|
430
|
+
title: trash ? `Move ${noun} to Trash` : `Update ${noun}`,
|
|
431
|
+
approveLabel: trash ? "Move to Trash" : "Apply changes",
|
|
432
|
+
effects,
|
|
433
|
+
...selectionCount === void 0 ? {} : { selectionCount, selectionKind },
|
|
434
|
+
...trash ? { consequence: "Messages stay recoverable in Trash until Gmail deletes them." } : thread ? { consequence: "Applies to every message in the conversation." } : {}
|
|
435
|
+
};
|
|
436
|
+
}
|
|
437
|
+
if (["trash_message", "restore_message", "trash_thread", "restore_thread"].includes(toolName))
|
|
438
|
+
return {
|
|
439
|
+
title: toolName.startsWith("trash_") ? `Move ${noun} to Trash` : `Remove ${noun} from Trash`,
|
|
440
|
+
approveLabel: toolName.startsWith("trash_") ? "Move to Trash" : "Remove from Trash",
|
|
441
|
+
effects,
|
|
442
|
+
...selectionCount === void 0 ? {} : { selectionCount, selectionKind }
|
|
443
|
+
};
|
|
444
|
+
const named = {
|
|
445
|
+
send_message: ["Send email", "Send email"],
|
|
446
|
+
send_draft: ["Send draft", "Send draft"],
|
|
447
|
+
create_draft: ["Create email draft", "Create draft"],
|
|
448
|
+
update_draft: ["Update email draft", "Update draft"],
|
|
449
|
+
delete_draft: ["Delete email draft", "Delete draft"],
|
|
450
|
+
create_label: ["Create label", "Create label"],
|
|
451
|
+
update_label: ["Update label", "Update label"],
|
|
452
|
+
delete_label: ["Delete label", "Delete label"]
|
|
453
|
+
};
|
|
454
|
+
const action = Object.hasOwn(named, toolName) ? named[toolName] : void 0;
|
|
455
|
+
return action ? { title: action[0], approveLabel: action[1], effects } : fallback;
|
|
456
|
+
}
|
|
457
|
+
function toolReviewDetails(argumentsValue, context, path, offset, limit = 25) {
|
|
458
|
+
if (!Number.isSafeInteger(offset) || offset < 0 || !Number.isSafeInteger(limit) || limit < 1 || limit > 50)
|
|
459
|
+
throw new Error("Invalid review page");
|
|
460
|
+
const args = decodeReviewArguments(argumentsValue);
|
|
461
|
+
let value = context?.email ? { ...args, $email: context.email } : args;
|
|
462
|
+
if (path !== "") {
|
|
463
|
+
if (!path.startsWith("/")) throw new Error("Invalid review field");
|
|
464
|
+
for (const escaped of path.slice(1).split("/")) {
|
|
465
|
+
if (/^~2\d+$/.test(escaped)) {
|
|
466
|
+
if (!value || typeof value !== "object" || Array.isArray(value))
|
|
467
|
+
throw new Error("Review field not found");
|
|
468
|
+
const selected = Object.entries(value)[Number(escaped.slice(2))];
|
|
469
|
+
if (!selected) throw new Error("Review field not found");
|
|
470
|
+
value = {
|
|
471
|
+
fieldName: selected[0],
|
|
472
|
+
value: protectedReviewField(selected[0], context?.protectedFields) ? "[Protected value]" : selected[1]
|
|
473
|
+
};
|
|
474
|
+
continue;
|
|
357
475
|
}
|
|
358
|
-
|
|
359
|
-
|
|
360
|
-
|
|
361
|
-
|
|
476
|
+
const key = escaped.replaceAll("~1", "/").replaceAll("~0", "~");
|
|
477
|
+
if (protectedReviewField(key, context?.protectedFields)) {
|
|
478
|
+
value = "[Protected value]";
|
|
479
|
+
break;
|
|
362
480
|
}
|
|
363
|
-
|
|
364
|
-
|
|
365
|
-
|
|
366
|
-
cancelled = true;
|
|
367
|
-
stopHeartbeat();
|
|
368
|
-
options.onCancel?.();
|
|
369
|
-
void Promise.resolve(iterator.return?.(void 0)).then(
|
|
370
|
-
() => void 0,
|
|
371
|
-
() => void 0
|
|
372
|
-
);
|
|
481
|
+
if (!value || typeof value !== "object" || !Object.hasOwn(value, key))
|
|
482
|
+
throw new Error("Review field not found");
|
|
483
|
+
value = value[key];
|
|
373
484
|
}
|
|
374
|
-
}
|
|
375
|
-
|
|
376
|
-
|
|
377
|
-
|
|
378
|
-
|
|
379
|
-
|
|
380
|
-
|
|
381
|
-
|
|
485
|
+
}
|
|
486
|
+
const preview = (entry, key, childPath) => {
|
|
487
|
+
const hidden = protectedReviewField(key, context?.protectedFields);
|
|
488
|
+
if (!hidden && entry !== null && typeof entry === "object") {
|
|
489
|
+
const count = Array.isArray(entry) ? entry.length : Object.keys(entry).length;
|
|
490
|
+
return {
|
|
491
|
+
value: `${count.toLocaleString("en-US")} ${Array.isArray(entry) ? count === 1 ? "item" : "items" : count === 1 ? "field" : "fields"}`,
|
|
492
|
+
path: childPath,
|
|
493
|
+
truncated: true
|
|
494
|
+
};
|
|
382
495
|
}
|
|
383
|
-
|
|
384
|
-
|
|
385
|
-
|
|
386
|
-
|
|
387
|
-
|
|
388
|
-
|
|
389
|
-
|
|
390
|
-
|
|
391
|
-
|
|
392
|
-
|
|
393
|
-
|
|
394
|
-
|
|
395
|
-
|
|
496
|
+
const text2 = valueText(safeReviewValue(entry, key, context?.protectedFields));
|
|
497
|
+
return {
|
|
498
|
+
value: bound(text2, 4e3),
|
|
499
|
+
...hidden ? {} : { path: childPath },
|
|
500
|
+
truncated: !hidden && text2.length > 4e3
|
|
501
|
+
};
|
|
502
|
+
};
|
|
503
|
+
let total;
|
|
504
|
+
let items;
|
|
505
|
+
if (Array.isArray(value)) {
|
|
506
|
+
total = value.length;
|
|
507
|
+
items = value.slice(offset, offset + limit).map((entry, index) => ({
|
|
508
|
+
label: `${offset + index + 1}`,
|
|
509
|
+
...preview(entry, "", `${path}/${offset + index}`)
|
|
510
|
+
}));
|
|
511
|
+
} else if (value && typeof value === "object") {
|
|
512
|
+
const entries = Object.entries(value);
|
|
513
|
+
total = entries.length;
|
|
514
|
+
items = entries.slice(offset, offset + limit).map(([key, entry], index) => ({
|
|
515
|
+
label: bound(
|
|
516
|
+
(context?.fieldLabels && Object.hasOwn(context.fieldLabels, key) ? context.fieldLabels[key] : void 0) ?? toolReviewFieldLabel(key),
|
|
517
|
+
256
|
|
518
|
+
),
|
|
519
|
+
...preview(entry, key, `${path}${fieldPointer(key, offset + index, path)}`)
|
|
520
|
+
}));
|
|
396
521
|
} else {
|
|
397
|
-
|
|
522
|
+
const text2 = valueText(value);
|
|
523
|
+
total = Math.max(1, Math.ceil(text2.length / 4e3));
|
|
524
|
+
items = Array.from({ length: Math.max(0, Math.min(limit, total - offset)) }, (_, index) => ({
|
|
525
|
+
label: `Part ${offset + index + 1}`,
|
|
526
|
+
value: text2.slice((offset + index) * 4e3, (offset + index + 1) * 4e3)
|
|
527
|
+
}));
|
|
398
528
|
}
|
|
399
|
-
|
|
400
|
-
|
|
401
|
-
|
|
402
|
-
|
|
403
|
-
|
|
404
|
-
|
|
405
|
-
|
|
406
|
-
|
|
407
|
-
|
|
408
|
-
|
|
529
|
+
return { path, items, total, nextOffset: offset + limit < total ? offset + limit : null };
|
|
530
|
+
}
|
|
531
|
+
|
|
532
|
+
// ../contracts/src/mcp-endpoint.ts
|
|
533
|
+
function mcpEndpointIdentity(value) {
|
|
534
|
+
if (!value) return null;
|
|
535
|
+
try {
|
|
536
|
+
const url = new URL(value);
|
|
537
|
+
if (!["https:", "http:"].includes(url.protocol) || url.username || url.password) return null;
|
|
538
|
+
url.hash = "";
|
|
539
|
+
return url.href;
|
|
540
|
+
} catch {
|
|
541
|
+
return null;
|
|
542
|
+
}
|
|
543
|
+
}
|
|
544
|
+
function pluginMcpUnavailableReason(server) {
|
|
545
|
+
if (server.transport === "stdio" || !server.endpoint) return "Requires a local runtime";
|
|
546
|
+
if (server.transport && !["http", "streamable-http", "streamable_http"].includes(server.transport))
|
|
547
|
+
return "Unsupported transport: " + server.transport;
|
|
548
|
+
if (server.requiresConfiguration || server.endpoint.includes("{"))
|
|
549
|
+
return "Requires custom connection configuration";
|
|
550
|
+
const endpoint2 = mcpEndpointIdentity(server.endpoint);
|
|
551
|
+
if (!endpoint2?.startsWith("https://")) return "Requires a valid HTTPS endpoint";
|
|
552
|
+
return null;
|
|
553
|
+
}
|
|
554
|
+
|
|
555
|
+
// src/tool-display-metadata.ts
|
|
556
|
+
function parseToolDisplayMetadata(value) {
|
|
557
|
+
if (!value || typeof value !== "object" || Array.isArray(value)) return void 0;
|
|
558
|
+
const item = value;
|
|
559
|
+
if (Object.keys(item).some(
|
|
560
|
+
(key) => !["toolName", "title", "accountLabel", "connector", "providerDomain"].includes(key)
|
|
561
|
+
))
|
|
562
|
+
return void 0;
|
|
563
|
+
const text2 = (v, max) => typeof v === "string" && v.length > 0 && v.length <= max;
|
|
564
|
+
if (!text2(item.toolName, 512) || /[\u0000-\u001f\u007f]/u.test(item.toolName)) return void 0;
|
|
565
|
+
if (item.title !== void 0 && !text2(item.title, 512)) return void 0;
|
|
566
|
+
if (item.accountLabel !== void 0 && !text2(item.accountLabel, 1024)) return void 0;
|
|
567
|
+
if (item.connector !== void 0 && !text2(item.connector, 512)) return void 0;
|
|
568
|
+
if (item.providerDomain !== void 0 && !text2(item.providerDomain, 253)) return void 0;
|
|
569
|
+
return {
|
|
570
|
+
toolName: item.toolName,
|
|
571
|
+
...item.title !== void 0 ? { title: item.title } : {},
|
|
572
|
+
...item.accountLabel !== void 0 ? { accountLabel: item.accountLabel } : {},
|
|
573
|
+
...item.connector !== void 0 ? { connector: item.connector } : {},
|
|
574
|
+
...item.providerDomain !== void 0 ? { providerDomain: item.providerDomain } : {}
|
|
575
|
+
};
|
|
409
576
|
}
|
|
410
577
|
|
|
411
578
|
// src/mcp-output.ts
|
|
@@ -438,31 +605,31 @@ function normalizeValue(value, depth, ancestors) {
|
|
|
438
605
|
if (Array.isArray(value)) {
|
|
439
606
|
return { value, text: safeStringify(value), isError: false };
|
|
440
607
|
}
|
|
441
|
-
const
|
|
442
|
-
const envelopeError =
|
|
443
|
-
if (
|
|
444
|
-
const normalized = normalizeText(
|
|
608
|
+
const record2 = value;
|
|
609
|
+
const envelopeError = record2.isError === true;
|
|
610
|
+
if (record2.type === "text" && typeof record2.text === "string") {
|
|
611
|
+
const normalized = normalizeText(record2.text, depth + 1, ancestors);
|
|
445
612
|
return {
|
|
446
613
|
value: normalized.value,
|
|
447
|
-
text:
|
|
614
|
+
text: record2.text,
|
|
448
615
|
isError: envelopeError || normalized.isError
|
|
449
616
|
};
|
|
450
617
|
}
|
|
451
|
-
if ("structuredContent" in
|
|
452
|
-
const normalized = normalizeValue(
|
|
618
|
+
if ("structuredContent" in record2) {
|
|
619
|
+
const normalized = normalizeValue(record2.structuredContent, depth + 1, ancestors);
|
|
453
620
|
return {
|
|
454
621
|
value: normalized.value,
|
|
455
|
-
text: firstMcpText(
|
|
622
|
+
text: firstMcpText(record2.content) ?? normalized.text,
|
|
456
623
|
isError: envelopeError || normalized.isError
|
|
457
624
|
};
|
|
458
625
|
}
|
|
459
|
-
if (isMcpContent(
|
|
460
|
-
const
|
|
461
|
-
if (
|
|
462
|
-
const normalized = normalizeText(
|
|
626
|
+
if (isMcpContent(record2.content)) {
|
|
627
|
+
const text2 = firstMcpText(record2.content);
|
|
628
|
+
if (text2 !== null) {
|
|
629
|
+
const normalized = normalizeText(text2, depth + 1, ancestors);
|
|
463
630
|
return {
|
|
464
631
|
value: normalized.value,
|
|
465
|
-
text,
|
|
632
|
+
text: text2,
|
|
466
633
|
isError: envelopeError || normalized.isError
|
|
467
634
|
};
|
|
468
635
|
}
|
|
@@ -472,8 +639,8 @@ function normalizeValue(value, depth, ancestors) {
|
|
|
472
639
|
isError: envelopeError
|
|
473
640
|
};
|
|
474
641
|
}
|
|
475
|
-
if (isResultEnvelope(
|
|
476
|
-
const normalized = normalizeValue(
|
|
642
|
+
if (isResultEnvelope(record2)) {
|
|
643
|
+
const normalized = normalizeValue(record2.result, depth + 1, ancestors);
|
|
477
644
|
return {
|
|
478
645
|
value: normalized.value,
|
|
479
646
|
text: normalized.text,
|
|
@@ -489,17 +656,17 @@ function normalizeValue(value, depth, ancestors) {
|
|
|
489
656
|
ancestors.delete(value);
|
|
490
657
|
}
|
|
491
658
|
}
|
|
492
|
-
function normalizeText(
|
|
659
|
+
function normalizeText(text2, depth, ancestors) {
|
|
493
660
|
try {
|
|
494
|
-
const parsed = JSON.parse(
|
|
661
|
+
const parsed = JSON.parse(text2);
|
|
495
662
|
const normalized = normalizeValue(parsed, depth + 1, ancestors);
|
|
496
663
|
return {
|
|
497
664
|
value: normalized.value,
|
|
498
|
-
text,
|
|
665
|
+
text: text2,
|
|
499
666
|
isError: normalized.isError
|
|
500
667
|
};
|
|
501
668
|
} catch {
|
|
502
|
-
return { value:
|
|
669
|
+
return { value: text2, text: text2, isError: false };
|
|
503
670
|
}
|
|
504
671
|
}
|
|
505
672
|
function isMcpContent(value) {
|
|
@@ -518,8 +685,8 @@ function firstMcpText(value) {
|
|
|
518
685
|
}
|
|
519
686
|
return null;
|
|
520
687
|
}
|
|
521
|
-
function isResultEnvelope(
|
|
522
|
-
return "result" in
|
|
688
|
+
function isResultEnvelope(record2) {
|
|
689
|
+
return "result" in record2 && Object.keys(record2).every((key) => RESULT_ENVELOPE_KEYS.has(key));
|
|
523
690
|
}
|
|
524
691
|
function safeStringify(value) {
|
|
525
692
|
try {
|
|
@@ -635,18 +802,6 @@ function normalizeCompanyProfileStableKey(value) {
|
|
|
635
802
|
function inspectorPath(workspaceId, suffix) {
|
|
636
803
|
return `/v1/workspaces/${workspaceId}/company-brain/${suffix}`;
|
|
637
804
|
}
|
|
638
|
-
function searchCompanyBrainKnowledge(client, workspaceId, request) {
|
|
639
|
-
return client.requestJson("POST", inspectorPath(workspaceId, "knowledge/search"), request);
|
|
640
|
-
}
|
|
641
|
-
function getCompanyBrainKnowledge(client, workspaceId, recordId) {
|
|
642
|
-
return client.requestJson(
|
|
643
|
-
"GET",
|
|
644
|
-
`${inspectorPath(workspaceId, "knowledge/record")}?id=${encodeURIComponent(recordId)}`
|
|
645
|
-
);
|
|
646
|
-
}
|
|
647
|
-
function browseCompanyBrainKnowledge(client, workspaceId, request = {}) {
|
|
648
|
-
return client.requestJson("POST", inspectorPath(workspaceId, "knowledge/browse"), request);
|
|
649
|
-
}
|
|
650
805
|
function listCompanyBrainContextReceipts(client, workspaceId, options = {}) {
|
|
651
806
|
const params = new URLSearchParams();
|
|
652
807
|
if (options.attemptId) params.set("attemptId", options.attemptId);
|
|
@@ -700,6 +855,7 @@ export {
|
|
|
700
855
|
ComputerTargetCollection,
|
|
701
856
|
DEFAULT_FILE_RESOURCE_MOUNT_ROOT,
|
|
702
857
|
DEFAULT_WORKSPACE_TRANSCRIPTION_POLICY,
|
|
858
|
+
EMPTY_FINAL_REPLY_NOTICE,
|
|
703
859
|
GENERATED_VIDEO_MAX_BYTES,
|
|
704
860
|
INTERACTION_PROTOCOL_VERSION,
|
|
705
861
|
InteractionInterventionCollection,
|
|
@@ -711,85 +867,148 @@ export {
|
|
|
711
867
|
OPENGENI_API_CONTRACT_HEADER,
|
|
712
868
|
OPENGENI_API_CONTRACT_REVISION,
|
|
713
869
|
OPENGENI_CORRELATION_HEADER,
|
|
870
|
+
OPENGENI_SITE_BRIDGE_CANCEL,
|
|
871
|
+
OPENGENI_SITE_BRIDGE_CONNECT,
|
|
872
|
+
OPENGENI_SITE_BRIDGE_READY,
|
|
873
|
+
OPENGENI_SITE_BRIDGE_REQUEST,
|
|
874
|
+
OPENGENI_SITE_BRIDGE_RESPONSE,
|
|
875
|
+
OPENGENI_SITE_BRIDGE_SIGN_IN_METHOD,
|
|
876
|
+
OPENGENI_SITE_BRIDGE_VERSION,
|
|
877
|
+
OPENGENI_SITE_BRIDGE_VIEWER_METHOD,
|
|
878
|
+
OPENGENI_TEST_REQUEST_NIL_ID,
|
|
879
|
+
OPENGENI_WEBHOOK_HEADERS,
|
|
880
|
+
OPENGENI_WEBHOOK_TEST_EVENT_TYPE,
|
|
881
|
+
OpenGeniAllowanceExhaustedError,
|
|
714
882
|
OpenGeniApiContractMismatchError,
|
|
715
883
|
OpenGeniApiError,
|
|
716
|
-
OpenGeniClient,
|
|
884
|
+
OpenGeniEmbeddingClient as OpenGeniClient,
|
|
717
885
|
OpenGeniInteractionClient,
|
|
886
|
+
OpenGeniSecureContextRequiredError,
|
|
718
887
|
OpenGeniSessionListCursorError,
|
|
888
|
+
OpenGeniSessionUsageLimitReachedError,
|
|
889
|
+
OpenGeniSessionUsageLimitUnsupportedError,
|
|
890
|
+
OpenGeniSetupError,
|
|
891
|
+
OpenGeniSignatureError,
|
|
892
|
+
OpenGeniSiteBridgeError,
|
|
719
893
|
OpenGeniStreamError,
|
|
894
|
+
OpenGeniToolCallError,
|
|
895
|
+
OpenGeniToolReapprovalRequiredError,
|
|
896
|
+
OpenGeniToolsClient,
|
|
720
897
|
PERSONAL_RESOURCE_SHARED_OUTPUT_WARNING,
|
|
721
898
|
PERSONAL_RESOURCE_SHARED_OUTPUT_WARNING_VERSION,
|
|
722
899
|
RETAINED_OUTPUT_DEFAULT_PAGE_BYTES,
|
|
723
900
|
RETAINED_OUTPUT_MAX_PAGE_BYTES,
|
|
724
901
|
SANDBOX_FILE_ARTIFACT_MAX_BYTES,
|
|
725
902
|
SESSION_EVENT_TYPES,
|
|
903
|
+
SESSION_SCOPE_HEADER,
|
|
726
904
|
SiteAuthConnectionCollection,
|
|
727
905
|
SiteAuthConnectionResource,
|
|
728
906
|
TTYD_SUBPROTOCOL,
|
|
907
|
+
ToolRequestError,
|
|
729
908
|
TtydClientCommand,
|
|
730
909
|
TtydServerCommand,
|
|
731
910
|
WORKSPACE_INSTRUCTION_POLICY_CONTENT_MAX_CHARS,
|
|
911
|
+
WORKSPACE_WEBHOOK_EVENT_TYPES,
|
|
732
912
|
acquireCodexRealtimeMicrophone,
|
|
733
913
|
applyUrlRotation,
|
|
914
|
+
artifactViewerCapability,
|
|
915
|
+
asVaultClient,
|
|
734
916
|
authorizeTranscriptionAdapter,
|
|
735
|
-
browseCompanyBrainKnowledge,
|
|
736
917
|
browserFrameSocketUrl,
|
|
737
918
|
codexRealtimeMicrophoneHealthy,
|
|
919
|
+
codexRealtimeRefusal,
|
|
738
920
|
computerFrameSocketUrl,
|
|
739
921
|
contextAppendChunks,
|
|
740
922
|
createCodexRealtimeController,
|
|
741
923
|
createCodexRealtimeV3Bridge,
|
|
742
924
|
createGatewayRealtimeTransportStarter,
|
|
925
|
+
createOpenGeniSiteClient,
|
|
926
|
+
createSessionProxyHandler,
|
|
927
|
+
createSiteToolBridge,
|
|
743
928
|
createTranscriptionSessionRequest,
|
|
744
929
|
createXaiSubscriptionRealtimeTransportStarter,
|
|
745
930
|
decodeBrowserFrameMessage,
|
|
746
931
|
decodeComputerFrameMessage,
|
|
747
932
|
decodeComputerFrameMetadataHeader,
|
|
933
|
+
deriveAutomaticSessionTitlePreview,
|
|
748
934
|
deriveSessionDisplayTitle,
|
|
749
935
|
desktopSocketUrl,
|
|
750
936
|
encodeCodexRealtimeV3DelegationContextAppend,
|
|
751
937
|
encodeCodexRealtimeV3SessionContextAppend,
|
|
938
|
+
formatErrorMessage,
|
|
752
939
|
formatSseEvent,
|
|
753
940
|
generatedImageSandboxPathMatches,
|
|
754
|
-
|
|
941
|
+
humanizeModelSlug,
|
|
755
942
|
interactionControlFailureFromError,
|
|
943
|
+
isOpenGeniSiteBridgeCancelMessage,
|
|
944
|
+
isOpenGeniSiteBridgeConnectMessage,
|
|
945
|
+
isOpenGeniSiteBridgeRequestMessage,
|
|
946
|
+
isRawModelLabel,
|
|
947
|
+
isReservedOpenGeniLink,
|
|
756
948
|
isRetryableStreamError,
|
|
949
|
+
isSiteCatalogStaleError,
|
|
757
950
|
listCompanyBrainContextReceipts,
|
|
758
951
|
listCompanyBrainKnowledgeProposals,
|
|
952
|
+
modelDisplayName,
|
|
953
|
+
modelSlug,
|
|
954
|
+
modelVendor,
|
|
759
955
|
nextDesktopState,
|
|
760
956
|
normalizeCompanyProfileStableKey,
|
|
761
957
|
normalizeMcpOutput,
|
|
762
958
|
normalizePreferenceRegistryStableKey,
|
|
763
959
|
normalizeWorkspaceInstructionPolicyRoleKey,
|
|
960
|
+
openGeniConsolePath,
|
|
961
|
+
openGeniLinkScheme,
|
|
764
962
|
parseBrowserFrameMetadata,
|
|
765
963
|
parseCodexRealtimeV3Event,
|
|
766
964
|
parseComputerFrameMetadata,
|
|
965
|
+
parseCustomMcpSetupRequest,
|
|
966
|
+
parseDeprecationNotice,
|
|
767
967
|
parseGeneratedImageReceipt,
|
|
768
968
|
parseGeneratedVideoReceipt,
|
|
769
969
|
parseMediaGenerationResult,
|
|
970
|
+
parseOpenGeniLink,
|
|
971
|
+
parseRetainedFileReference,
|
|
770
972
|
parseRetainedGeneratedImageReference,
|
|
771
973
|
parseRetainedGeneratedVideoReference,
|
|
772
974
|
parseRetainedWorkspaceFileReference,
|
|
773
975
|
parseSandboxFileArtifactReceipt,
|
|
976
|
+
parseSandboxLink,
|
|
774
977
|
parseSseStream,
|
|
978
|
+
parseToolDisplayMetadata,
|
|
775
979
|
parseWorkspaceLiveEvent,
|
|
980
|
+
pluginMcpUnavailableReason,
|
|
776
981
|
projectSessionRealtimeLifecycle,
|
|
777
982
|
proxySessionEventStream,
|
|
778
983
|
resolveWorkspaceTranscriptionPolicy,
|
|
779
984
|
resolveWorkspaceVoiceInputEnabled,
|
|
780
985
|
resumeSequenceFromRequest,
|
|
781
|
-
|
|
986
|
+
sanitizeOpenGeniSiteToolCallRequest,
|
|
987
|
+
sessionEventStreamCoveredThrough,
|
|
782
988
|
sessionEventsToSseResponse,
|
|
783
989
|
sessionEventsToSseStream,
|
|
990
|
+
sessionListEntry,
|
|
784
991
|
sessionTitleIsPending,
|
|
992
|
+
signOpenGeniPayload,
|
|
785
993
|
startCodexRealtimeWebrtc,
|
|
786
994
|
streamSessionEvents,
|
|
787
995
|
streamWorkspaceControlEvents,
|
|
788
996
|
streamWorkspaceInteractionRevisions,
|
|
789
997
|
streamWorkspaceLiveEvents,
|
|
790
998
|
terminalSocketUrl,
|
|
999
|
+
toolReviewAction,
|
|
1000
|
+
toolReviewDetails,
|
|
1001
|
+
toolReviewFields,
|
|
791
1002
|
ttydAuthFrame,
|
|
792
1003
|
ttydInputFrame,
|
|
793
|
-
ttydResizeFrame
|
|
1004
|
+
ttydResizeFrame,
|
|
1005
|
+
turnCompletedWithEmptyFinalReply,
|
|
1006
|
+
vaultErrorCode,
|
|
1007
|
+
vaultErrorDetail,
|
|
1008
|
+
vaultsApi,
|
|
1009
|
+
verifyCredentialProviderRequest,
|
|
1010
|
+
verifyOpenGeniSignature,
|
|
1011
|
+
verifyToolRequest,
|
|
1012
|
+
verifyWebhookEvent
|
|
794
1013
|
};
|
|
795
1014
|
//# sourceMappingURL=index.js.map
|