@openclaw/google-meet 2026.7.2-beta.7 → 2026.8.1-beta.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/chrome-create-PKAyxCiL.js +325 -0
- package/dist/{cli-DCcRyaMf.js → cli-Bd63VJ5q.js} +191 -237
- package/dist/{config-BcaS1BDr.js → config-wBK8loBb.js} +97 -221
- package/dist/{create-af1MDlus.js → create-BEDHM6uL.js} +3 -14
- package/dist/google-meet-platform-adapter-C3J-iFRE.js +791 -0
- package/dist/google-meet-platform-constants-Bs5iAg3E.js +25 -0
- package/dist/index.js +185 -2639
- package/dist/meet-url-BP2Jlvjs.js +17 -0
- package/dist/node-host-BXtXbsMa.js +49 -0
- package/dist/node-invoke-policy-B0gOlLJR.js +24 -0
- package/dist/{oauth-DOfMKlGp.js → oauth-9sUJ68Mw.js} +3 -14
- package/dist/{chrome-create-DMKruRFW.js → plugin-helpers-C9-Y0Ago.js} +335 -355
- package/dist/plugin-registration-Csi-NdQU.js +131 -0
- package/dist/runtime-B8d1beHo.js +1308 -0
- package/openclaw.plugin.json +15 -47
- package/package.json +4 -6
- package/node_modules/pretty-ms/index.d.ts +0 -157
- package/node_modules/pretty-ms/index.js +0 -149
- package/node_modules/pretty-ms/license +0 -9
- package/node_modules/pretty-ms/node_modules/parse-ms/index.d.ts +0 -30
- package/node_modules/pretty-ms/node_modules/parse-ms/index.js +0 -45
- package/node_modules/pretty-ms/node_modules/parse-ms/license +0 -9
- package/node_modules/pretty-ms/node_modules/parse-ms/package.json +0 -47
- package/node_modules/pretty-ms/node_modules/parse-ms/readme.md +0 -46
- package/node_modules/pretty-ms/package.json +0 -55
- package/node_modules/pretty-ms/readme.md +0 -179
|
@@ -0,0 +1,131 @@
|
|
|
1
|
+
import { i as isGoogleMeetBrowserManualActionError, n as GOOGLE_MEET_NODE_COMMAND } from "./google-meet-platform-constants-Bs5iAg3E.js";
|
|
2
|
+
import { i as resolveGoogleMeetGatewayOperationTimeoutMs } from "./config-wBK8loBb.js";
|
|
3
|
+
import { asNonArrayRecord as asParamRecord, normalizeOptionalString } from "openclaw/plugin-sdk/string-coerce-runtime";
|
|
4
|
+
import { formatErrorMessage } from "openclaw/plugin-sdk/error-runtime";
|
|
5
|
+
import { createLazyRuntimeModule } from "openclaw/plugin-sdk/lazy-runtime";
|
|
6
|
+
//#region extensions/google-meet/src/plugin-registration.ts
|
|
7
|
+
const loadGoogleMeetPluginHelpers = createLazyRuntimeModule(() => import("./plugin-helpers-C9-Y0Ago.js").then((n) => n.r));
|
|
8
|
+
const loadGoogleMeetCliModule = createLazyRuntimeModule(() => import("./cli-Bd63VJ5q.js"));
|
|
9
|
+
const loadGoogleMeetNodeHostModule = createLazyRuntimeModule(() => import("./node-host-BXtXbsMa.js"));
|
|
10
|
+
const loadGoogleMeetRuntimeModule = createLazyRuntimeModule(() => import("./runtime-B8d1beHo.js"));
|
|
11
|
+
const loadGoogleMeetNodeInvokePolicyModule = createLazyRuntimeModule(() => import("./node-invoke-policy-B0gOlLJR.js"));
|
|
12
|
+
const loadGoogleMeetGatewayRuntimeModule = createLazyRuntimeModule(() => import("openclaw/plugin-sdk/gateway-runtime"));
|
|
13
|
+
const loadGoogleMeetNodeInvokePolicy = async (config) => (await loadGoogleMeetNodeInvokePolicyModule()).createGoogleMeetChromeNodeInvokePolicy(config);
|
|
14
|
+
function normalizeTransport(value) {
|
|
15
|
+
return value === "chrome" || value === "chrome-node" || value === "twilio" ? value : void 0;
|
|
16
|
+
}
|
|
17
|
+
function normalizeMode(value) {
|
|
18
|
+
if (value === "realtime") return "agent";
|
|
19
|
+
return value === "agent" || value === "bidi" || value === "transcribe" ? value : void 0;
|
|
20
|
+
}
|
|
21
|
+
function resolveMeetingInput(config, value) {
|
|
22
|
+
const meeting = normalizeOptionalString(value) ?? config.defaults.meeting;
|
|
23
|
+
if (!meeting) throw new Error("Meeting input is required");
|
|
24
|
+
return meeting;
|
|
25
|
+
}
|
|
26
|
+
function shouldJoinCreatedMeet(raw) {
|
|
27
|
+
return raw.join !== false && raw.join !== "false";
|
|
28
|
+
}
|
|
29
|
+
const googleMeetToolDeps = { platform: () => process.platform };
|
|
30
|
+
function googleMeetGatewayMethodForToolAction(action) {
|
|
31
|
+
switch (action) {
|
|
32
|
+
case "recover_current_tab": return "googlemeet.recoverCurrentTab";
|
|
33
|
+
case "setup_status": return "googlemeet.setup";
|
|
34
|
+
case "test_speech": return "googlemeet.testSpeech";
|
|
35
|
+
case "test_listen": return "googlemeet.testListen";
|
|
36
|
+
case "end_active_conference": return "googlemeet.endActiveConference";
|
|
37
|
+
default: return `googlemeet.${action}`;
|
|
38
|
+
}
|
|
39
|
+
}
|
|
40
|
+
function isGoogleMeetAgentToolActionUnsupportedOnHost(params) {
|
|
41
|
+
const platform = params.platform ?? googleMeetToolDeps.platform();
|
|
42
|
+
if (platform === "darwin" || platform === "linux") return false;
|
|
43
|
+
const action = params.raw.action;
|
|
44
|
+
if (action !== "join" && action !== "test_speech" && !(action === "create" && shouldJoinCreatedMeet(params.raw))) return false;
|
|
45
|
+
const transport = normalizeTransport(params.raw.transport) ?? params.config.defaultTransport;
|
|
46
|
+
const mode = action === "test_speech" ? "agent" : normalizeMode(params.raw.mode) ?? params.config.defaultMode;
|
|
47
|
+
return transport === "chrome" && (mode === "agent" || mode === "bidi");
|
|
48
|
+
}
|
|
49
|
+
function assertGoogleMeetAgentToolActionSupported(params) {
|
|
50
|
+
if (!isGoogleMeetAgentToolActionUnsupportedOnHost(params)) return;
|
|
51
|
+
throw new Error("Google Meet local Chrome talk-back audio requires macOS with BlackHole 2ch or Linux with PipeWire-Pulse. On this host, use mode: transcribe, transport: twilio, or a supported chrome-node.");
|
|
52
|
+
}
|
|
53
|
+
function readGatewayErrorDetails(err) {
|
|
54
|
+
if (!err || typeof err !== "object" || !("details" in err)) return;
|
|
55
|
+
return err.details;
|
|
56
|
+
}
|
|
57
|
+
async function callGoogleMeetGatewayFromTool(params) {
|
|
58
|
+
try {
|
|
59
|
+
if (params.runtime) return await params.runtime.gateway.request(googleMeetGatewayMethodForToolAction(params.action), params.raw, {
|
|
60
|
+
timeoutMs: resolveGoogleMeetGatewayOperationTimeoutMs(params.config),
|
|
61
|
+
scopes: ["operator.admin"]
|
|
62
|
+
});
|
|
63
|
+
return await (googleMeetToolDeps.callGatewayFromCli ?? (await loadGoogleMeetGatewayRuntimeModule()).callGatewayFromCli)(googleMeetGatewayMethodForToolAction(params.action), {
|
|
64
|
+
json: true,
|
|
65
|
+
timeout: String(resolveGoogleMeetGatewayOperationTimeoutMs(params.config))
|
|
66
|
+
}, params.raw, {
|
|
67
|
+
progress: false,
|
|
68
|
+
scopes: ["operator.admin"]
|
|
69
|
+
});
|
|
70
|
+
} catch (err) {
|
|
71
|
+
const details = readGatewayErrorDetails(err);
|
|
72
|
+
if (details && typeof details === "object") return details;
|
|
73
|
+
throw err;
|
|
74
|
+
}
|
|
75
|
+
}
|
|
76
|
+
function keepTrustedToolAgentId(raw, client) {
|
|
77
|
+
const { agentId: rawAgentId, ...rest } = raw;
|
|
78
|
+
if (client?.internal?.pluginRuntimeOwnerId !== "google-meet") return rest;
|
|
79
|
+
const agentId = normalizeOptionalString(rawAgentId);
|
|
80
|
+
return agentId ? {
|
|
81
|
+
...rest,
|
|
82
|
+
agentId
|
|
83
|
+
} : rest;
|
|
84
|
+
}
|
|
85
|
+
function createGoogleMeetRuntimeAccessor(params) {
|
|
86
|
+
let runtimePromise;
|
|
87
|
+
return async () => {
|
|
88
|
+
if (!params.config.enabled) throw new Error("Google Meet plugin disabled in plugin config");
|
|
89
|
+
return await (runtimePromise ?? (runtimePromise = loadGoogleMeetRuntimeModule().then(({ GoogleMeetRuntime: Runtime }) => new Runtime({
|
|
90
|
+
config: params.config,
|
|
91
|
+
fullConfig: params.api.config,
|
|
92
|
+
runtime: params.api.runtime,
|
|
93
|
+
logger: params.api.logger
|
|
94
|
+
}))));
|
|
95
|
+
};
|
|
96
|
+
}
|
|
97
|
+
function createLazyGoogleMeetNodeInvokePolicy(config, loadPolicy = loadGoogleMeetNodeInvokePolicy) {
|
|
98
|
+
let policyPromise;
|
|
99
|
+
return {
|
|
100
|
+
commands: [GOOGLE_MEET_NODE_COMMAND],
|
|
101
|
+
dangerous: true,
|
|
102
|
+
async handle(ctx) {
|
|
103
|
+
let policy;
|
|
104
|
+
try {
|
|
105
|
+
policyPromise ??= loadPolicy(config);
|
|
106
|
+
policy = await policyPromise;
|
|
107
|
+
} catch (error) {
|
|
108
|
+
return {
|
|
109
|
+
ok: false,
|
|
110
|
+
code: "PLUGIN_POLICY_UNAVAILABLE",
|
|
111
|
+
message: `google-meet PLUGIN_POLICY_UNAVAILABLE: node.invoke policy unavailable: ${formatErrorMessage(error)}`,
|
|
112
|
+
unavailable: true
|
|
113
|
+
};
|
|
114
|
+
}
|
|
115
|
+
return await policy.handle(ctx);
|
|
116
|
+
}
|
|
117
|
+
};
|
|
118
|
+
}
|
|
119
|
+
function formatGoogleMeetGatewayError(err) {
|
|
120
|
+
return isGoogleMeetBrowserManualActionError(err) ? err.payload : { error: formatErrorMessage(err) };
|
|
121
|
+
}
|
|
122
|
+
function sendGoogleMeetGatewayError(respond, err, code = "UNAVAILABLE") {
|
|
123
|
+
const payload = formatGoogleMeetGatewayError(err);
|
|
124
|
+
respond(false, payload, {
|
|
125
|
+
code,
|
|
126
|
+
message: typeof payload.error === "string" ? payload.error : "Google Meet request failed",
|
|
127
|
+
details: payload
|
|
128
|
+
});
|
|
129
|
+
}
|
|
130
|
+
//#endregion
|
|
131
|
+
export { createLazyGoogleMeetNodeInvokePolicy as a, loadGoogleMeetCliModule as c, normalizeMode as d, normalizeTransport as f, shouldJoinCreatedMeet as h, createGoogleMeetRuntimeAccessor as i, loadGoogleMeetNodeHostModule as l, sendGoogleMeetGatewayError as m, assertGoogleMeetAgentToolActionSupported as n, formatGoogleMeetGatewayError as o, resolveMeetingInput as p, callGoogleMeetGatewayFromTool as r, keepTrustedToolAgentId as s, asParamRecord as t, loadGoogleMeetPluginHelpers as u };
|