@openclaw/googlechat 2026.6.8 → 2026.6.9

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.
@@ -1,5 +1,5 @@
1
1
  import { l as resolveGoogleChatAccount, o as listEnabledGoogleChatAccounts } from "./channel-base-Qh87GFW_.js";
2
- import { b as uploadGoogleChatAttachment, d as resolveGoogleChatOutboundSpace, f as createGoogleChatReaction, g as listGoogleChatReactions, m as deleteGoogleChatReaction, v as sendGoogleChatMessage } from "./channel.adapters-BQoq1F4R.js";
2
+ import { b as uploadGoogleChatAttachment, d as resolveGoogleChatOutboundSpace, f as createGoogleChatReaction, g as listGoogleChatReactions, m as deleteGoogleChatReaction, v as sendGoogleChatMessage } from "./channel.adapters-DqnXEL1u.js";
3
3
  import { P as getGoogleChatRuntime } from "./runtime-api-BbVoWRxq.js";
4
4
  import { extractToolSend } from "openclaw/plugin-sdk/tool-send";
5
5
  import { createActionGate, jsonResult, readPositiveIntegerParam, readReactionParams, readStringParam } from "openclaw/plugin-sdk/channel-actions";
@@ -81,31 +81,31 @@ const googlechatMessageActions = {
81
81
  buffer: loaded.buffer,
82
82
  contentType: loaded.contentType
83
83
  });
84
- await sendGoogleChatMessage({
85
- account,
86
- space,
87
- text: content,
88
- thread: threadId ?? void 0,
89
- attachments: upload.attachmentUploadToken ? [{
90
- attachmentUploadToken: upload.attachmentUploadToken,
91
- contentName: uploadFileName
92
- }] : void 0
93
- });
94
84
  return jsonResult({
95
85
  ok: true,
96
- to: space
86
+ to: space,
87
+ ...await sendGoogleChatMessage({
88
+ account,
89
+ space,
90
+ text: content,
91
+ thread: threadId ?? void 0,
92
+ attachments: upload.attachmentUploadToken ? [{
93
+ attachmentUploadToken: upload.attachmentUploadToken,
94
+ contentName: uploadFileName
95
+ }] : void 0
96
+ })
97
97
  });
98
98
  }
99
99
  if (action === "upload-file") throw new Error("upload-file requires media, filePath, or path");
100
- await sendGoogleChatMessage({
101
- account,
102
- space,
103
- text: content,
104
- thread: threadId ?? void 0
105
- });
106
100
  return jsonResult({
107
101
  ok: true,
108
- to: space
102
+ to: space,
103
+ ...await sendGoogleChatMessage({
104
+ account,
105
+ space,
106
+ text: content,
107
+ thread: threadId ?? void 0
108
+ })
109
109
  });
110
110
  }
111
111
  if (action === "react") {
package/dist/api.js CHANGED
@@ -1,3 +1,3 @@
1
1
  import { a as googlechatSetupAdapter, i as googlechatSetupWizard } from "./channel-base-Qh87GFW_.js";
2
- import { t as googlechatPlugin } from "./channel-BY9hwCh2.js";
2
+ import { t as googlechatPlugin } from "./channel-B0rUtvbH.js";
3
3
  export { googlechatPlugin, googlechatSetupAdapter, googlechatSetupWizard };
@@ -1,5 +1,5 @@
1
1
  import { l as resolveGoogleChatAccount } from "./channel-base-Qh87GFW_.js";
2
- import { l as isGoogleChatUserTarget, u as normalizeGoogleChatTarget } from "./channel.adapters-BQoq1F4R.js";
2
+ import { l as isGoogleChatUserTarget, u as normalizeGoogleChatTarget } from "./channel.adapters-DqnXEL1u.js";
3
3
  import { normalizeLowercaseStringOrEmpty } from "openclaw/plugin-sdk/string-coerce-runtime";
4
4
  import { createResolvedApproverActionAuthAdapter, resolveApprovalApprovers } from "openclaw/plugin-sdk/approval-auth-runtime";
5
5
  //#region extensions/googlechat/src/approval-auth.ts
@@ -1,6 +1,6 @@
1
1
  import { l as resolveGoogleChatAccount } from "./channel-base-Qh87GFW_.js";
2
- import { A as registerGoogleChatManualApprovalFollowupSuppression, C as buildGoogleChatApprovalActionParameters, E as createGoogleChatApprovalToken, M as unregisterGoogleChatApprovalCardBindings, N as unregisterGoogleChatManualApprovalFollowupSuppression, S as GOOGLECHAT_APPROVAL_ACTION, d as resolveGoogleChatOutboundSpace, k as registerGoogleChatApprovalCardBinding, v as sendGoogleChatMessage, y as updateGoogleChatMessage } from "./channel.adapters-BQoq1F4R.js";
3
- import { n as isGoogleChatNativeApprovalClientEnabled, r as shouldHandleGoogleChatNativeApprovalRequest } from "./channel-BY9hwCh2.js";
2
+ import { A as registerGoogleChatManualApprovalFollowupSuppression, C as buildGoogleChatApprovalActionParameters, E as createGoogleChatApprovalToken, M as unregisterGoogleChatApprovalCardBindings, N as unregisterGoogleChatManualApprovalFollowupSuppression, S as GOOGLECHAT_APPROVAL_ACTION, d as resolveGoogleChatOutboundSpace, k as registerGoogleChatApprovalCardBinding, v as sendGoogleChatMessage, y as updateGoogleChatMessage } from "./channel.adapters-DqnXEL1u.js";
3
+ import { n as isGoogleChatNativeApprovalClientEnabled, r as shouldHandleGoogleChatNativeApprovalRequest } from "./channel-B0rUtvbH.js";
4
4
  import { buildChannelApprovalNativeTargetKey } from "openclaw/plugin-sdk/approval-native-runtime";
5
5
  import { normalizeOptionalString } from "openclaw/plugin-sdk/string-coerce-runtime";
6
6
  import { createChannelApprovalNativeRuntimeAdapter } from "openclaw/plugin-sdk/approval-handler-runtime";
@@ -1,7 +1,7 @@
1
1
  import { c as resolveDefaultGoogleChatAccountId, l as resolveGoogleChatAccount, n as createGoogleChatPluginBase, s as listGoogleChatAccountIds, t as GOOGLECHAT_CHANNEL_ID } from "./channel-base-Qh87GFW_.js";
2
- import { a as googlechatPairingTextAdapter, c as isGoogleChatSpaceTarget, i as googlechatOutboundAdapter, l as isGoogleChatUserTarget, n as googlechatGroupsAdapter, o as googlechatSecurityAdapter, r as googlechatMessageAdapter, s as googlechatThreadingAdapter, t as googlechatDirectoryAdapter, u as normalizeGoogleChatTarget } from "./channel.adapters-BQoq1F4R.js";
2
+ import { a as googlechatPairingTextAdapter, c as isGoogleChatSpaceTarget, i as googlechatOutboundAdapter, l as isGoogleChatUserTarget, n as googlechatGroupsAdapter, o as googlechatSecurityAdapter, r as googlechatMessageAdapter, s as googlechatThreadingAdapter, t as googlechatDirectoryAdapter, u as normalizeGoogleChatTarget } from "./channel.adapters-DqnXEL1u.js";
3
3
  import { a as buildChannelConfigSchema, r as GoogleChatConfigSchema, t as DEFAULT_ACCOUNT_ID } from "./runtime-api-BbVoWRxq.js";
4
- import { n as googleChatApprovalAuth, r as normalizeGoogleChatApproverId, t as getGoogleChatApprovalApprovers } from "./approval-auth-C-vWY4bY.js";
4
+ import { n as googleChatApprovalAuth, r as normalizeGoogleChatApproverId, t as getGoogleChatApprovalApprovers } from "./approval-auth-C-eKNZAV.js";
5
5
  import { n as normalizeCompatibilityConfig, t as legacyConfigRules } from "./doctor-contract-BcEqUZ4j.js";
6
6
  import { n as collectRuntimeConfigAssignments, r as secretTargetRegistryEntries } from "./secret-contract-lCMHqumt.js";
7
7
  import { createChatChannelPlugin } from "openclaw/plugin-sdk/channel-core";
@@ -9,7 +9,7 @@ import { buildPassiveProbedChannelStatusSummary } from "openclaw/plugin-sdk/exte
9
9
  import { createLazyRuntimeNamedExport } from "openclaw/plugin-sdk/lazy-runtime";
10
10
  import { createComputedAccountStatusAdapter, createDefaultChannelRuntimeState } from "openclaw/plugin-sdk/status-helpers";
11
11
  import { extractToolSend } from "openclaw/plugin-sdk/tool-send";
12
- import { createApproverRestrictedNativeApprovalCapability, splitChannelApprovalCapability } from "openclaw/plugin-sdk/approval-delivery-runtime";
12
+ import { createApproverRestrictedNativeApprovalCapability } from "openclaw/plugin-sdk/approval-delivery-runtime";
13
13
  import { CHANNEL_APPROVAL_NATIVE_RUNTIME_CONTEXT_CAPABILITY, createLazyChannelApprovalNativeRuntimeAdapter } from "openclaw/plugin-sdk/approval-handler-adapter-runtime";
14
14
  import { createChannelApproverDmTargetResolver, createChannelNativeOriginTargetResolver, createNativeApprovalChannelRouteGates, shouldSuppressLocalNativeExecApprovalPrompt } from "openclaw/plugin-sdk/approval-native-runtime";
15
15
  import { normalizeLowercaseStringOrEmpty, normalizeOptionalString } from "openclaw/plugin-sdk/string-coerce-runtime";
@@ -139,10 +139,9 @@ const googleChatApprovalCapability = createApproverRestrictedNativeApprovalCapab
139
139
  accountId,
140
140
  request
141
141
  }),
142
- load: async () => (await import("./approval-handler.runtime-CWeVJAQF.js")).googleChatApprovalNativeRuntime
142
+ load: async () => (await import("./approval-handler.runtime-DSyDDrrE.js")).googleChatApprovalNativeRuntime
143
143
  })
144
144
  });
145
- splitChannelApprovalCapability(googleChatApprovalCapability);
146
145
  //#endregion
147
146
  //#region extensions/googlechat/src/doctor.ts
148
147
  function asObjectRecord(value) {
@@ -182,7 +181,7 @@ const collectGoogleChatMutableAllowlistWarnings = createDangerousNameMatchingMut
182
181
  });
183
182
  //#endregion
184
183
  //#region extensions/googlechat/src/gateway.ts
185
- const loadGoogleChatChannelRuntime$1 = createLazyRuntimeNamedExport(() => import("./channel.runtime-CbSK_Zox.js"), "googleChatChannelRuntime");
184
+ const loadGoogleChatChannelRuntime$1 = createLazyRuntimeNamedExport(() => import("./channel.runtime-BMM1gm2H.js"), "googleChatChannelRuntime");
186
185
  async function startGoogleChatGatewayAccount(ctx) {
187
186
  const account = ctx.account;
188
187
  const statusSink = createAccountStatusSink({
@@ -198,6 +197,15 @@ async function startGoogleChatGatewayAccount(ctx) {
198
197
  audienceType: account.config.audienceType,
199
198
  audience: account.config.audience
200
199
  });
200
+ let stopped = false;
201
+ const markStopped = () => {
202
+ if (stopped) return;
203
+ stopped = true;
204
+ statusSink({
205
+ running: false,
206
+ lastStopAt: Date.now()
207
+ });
208
+ };
201
209
  if (isGoogleChatNativeApprovalClientEnabled({
202
210
  cfg: ctx.cfg,
203
211
  accountId: account.accountId
@@ -209,31 +217,33 @@ async function startGoogleChatGatewayAccount(ctx) {
209
217
  context: { account },
210
218
  abortSignal: ctx.abortSignal
211
219
  });
212
- await runPassiveAccountLifecycle({
213
- abortSignal: ctx.abortSignal,
214
- start: async () => await startGoogleChatMonitor({
215
- account,
216
- config: ctx.cfg,
217
- runtime: ctx.runtime,
220
+ try {
221
+ await runPassiveAccountLifecycle({
218
222
  abortSignal: ctx.abortSignal,
219
- webhookPath: account.config.webhookPath,
220
- webhookUrl: account.config.webhookUrl,
221
- statusSink
222
- }),
223
- stop: async (unregister) => {
224
- unregister?.();
225
- },
226
- onStop: async () => {
227
- statusSink({
228
- running: false,
229
- lastStopAt: Date.now()
230
- });
231
- }
232
- });
223
+ start: async () => await startGoogleChatMonitor({
224
+ account,
225
+ config: ctx.cfg,
226
+ runtime: ctx.runtime,
227
+ abortSignal: ctx.abortSignal,
228
+ webhookPath: account.config.webhookPath,
229
+ webhookUrl: account.config.webhookUrl,
230
+ statusSink
231
+ }),
232
+ stop: async (unregister) => {
233
+ unregister?.();
234
+ },
235
+ onStop: async () => {
236
+ markStopped();
237
+ }
238
+ });
239
+ } catch (error) {
240
+ markStopped();
241
+ throw error;
242
+ }
233
243
  }
234
244
  //#endregion
235
245
  //#region extensions/googlechat/src/channel.ts
236
- const loadGoogleChatChannelRuntime = createLazyRuntimeNamedExport(() => import("./channel.runtime-CbSK_Zox.js"), "googleChatChannelRuntime");
246
+ const loadGoogleChatChannelRuntime = createLazyRuntimeNamedExport(() => import("./channel.runtime-BMM1gm2H.js"), "googleChatChannelRuntime");
237
247
  const googlechatActions = {
238
248
  describeMessageTool: ({ cfg, accountId }) => {
239
249
  const accounts = accountId ? [resolveGoogleChatAccount({
@@ -253,7 +263,7 @@ const googlechatActions = {
253
263
  },
254
264
  extractToolSend: ({ args }) => extractToolSend(args, "sendMessage"),
255
265
  handleAction: async (ctx) => {
256
- const { googlechatMessageActions } = await import("./actions-DvYC089V.js");
266
+ const { googlechatMessageActions } = await import("./actions-CD1aBGEt.js");
257
267
  if (!googlechatMessageActions.handleAction) throw new Error("Google Chat actions are not available.");
258
268
  return await googlechatMessageActions.handleAction(ctx);
259
269
  }
@@ -1,2 +1,2 @@
1
- import { t as googlechatPlugin } from "./channel-BY9hwCh2.js";
1
+ import { t as googlechatPlugin } from "./channel-B0rUtvbH.js";
2
2
  export { googlechatPlugin };
@@ -703,7 +703,10 @@ async function sendGoogleChatMessage(params) {
703
703
  method: "POST",
704
704
  body: JSON.stringify(body)
705
705
  });
706
- return result ? { messageName: result.name } : null;
706
+ return result ? {
707
+ messageName: result.name,
708
+ threadName: result.thread?.name
709
+ } : null;
707
710
  }
708
711
  async function updateGoogleChatMessage(params) {
709
712
  const { account, messageName, text, cardsV2 } = params;
@@ -839,7 +842,7 @@ function resolveGoogleChatGroupRequireMention(params) {
839
842
  }
840
843
  //#endregion
841
844
  //#region extensions/googlechat/src/channel.adapters.ts
842
- const loadGoogleChatChannelRuntime = createLazyRuntimeNamedExport(() => import("./channel.runtime-CbSK_Zox.js"), "googleChatChannelRuntime");
845
+ const loadGoogleChatChannelRuntime = createLazyRuntimeNamedExport(() => import("./channel.runtime-BMM1gm2H.js"), "googleChatChannelRuntime");
843
846
  function createGoogleChatSendReceipt(params) {
844
847
  const messageId = params.messageId?.trim();
845
848
  return createMessageReceiptFromOutboundResults({
@@ -853,7 +856,6 @@ function createGoogleChatSendReceipt(params) {
853
856
  kind: params.kind
854
857
  });
855
858
  }
856
- const formatAllowFromEntry = formatGoogleChatAllowFromEntry;
857
859
  const collectGoogleChatSecurityWarnings = composeAccountWarningCollectors(createAllowlistProviderOpenWarningCollector({
858
860
  providerConfigPresent: (cfg) => cfg.channels?.googlechat !== void 0,
859
861
  resolveGroupPolicy: (account) => account.config.groupPolicy,
@@ -883,7 +885,7 @@ const googlechatSecurityAdapter = {
883
885
  resolvePolicy: (account) => account.config.dm?.policy,
884
886
  resolveAllowFrom: (account) => account.config.dm?.allowFrom,
885
887
  allowFromPathSuffix: "dm.",
886
- normalizeEntry: (raw) => formatAllowFromEntry(raw)
888
+ normalizeEntry: (raw) => formatGoogleChatAllowFromEntry(raw)
887
889
  },
888
890
  collectWarnings: collectGoogleChatSecurityWarnings
889
891
  };
@@ -914,7 +916,7 @@ const googlechatThreadingAdapter = {
914
916
  const googlechatPairingTextAdapter = {
915
917
  idLabel: "googlechatUserId",
916
918
  message: PAIRING_APPROVED_MESSAGE,
917
- normalizeAllowEntry: (entry) => formatAllowFromEntry(entry),
919
+ normalizeAllowEntry: (entry) => formatGoogleChatAllowFromEntry(entry),
918
920
  notify: async ({ cfg, id, message, accountId }) => {
919
921
  const account = resolveGoogleChatAccount({
920
922
  cfg,
@@ -1,6 +1,6 @@
1
- import { D as getGoogleChatApprovalCardBinding, O as readGoogleChatApprovalActionToken, T as completeGoogleChatApprovalCardBinding, _ as probeGoogleChat, b as uploadGoogleChatAttachment, h as downloadGoogleChatMedia, j as releaseGoogleChatApprovalCardBinding, p as deleteGoogleChatMessage, v as sendGoogleChatMessage, w as claimGoogleChatApprovalCardBinding, x as verifyGoogleChatRequest, y as updateGoogleChatMessage } from "./channel.adapters-BQoq1F4R.js";
1
+ import { D as getGoogleChatApprovalCardBinding, O as readGoogleChatApprovalActionToken, T as completeGoogleChatApprovalCardBinding, _ as probeGoogleChat, b as uploadGoogleChatAttachment, h as downloadGoogleChatMedia, j as releaseGoogleChatApprovalCardBinding, p as deleteGoogleChatMessage, v as sendGoogleChatMessage, w as claimGoogleChatApprovalCardBinding, x as verifyGoogleChatRequest, y as updateGoogleChatMessage } from "./channel.adapters-DqnXEL1u.js";
2
2
  import { E as resolveDefaultGroupPolicy, M as warnMissingProviderGroupPolicyFallbackOnce, O as resolveInboundRouteEnvelopeBuilderWithRuntime, P as getGoogleChatRuntime, k as resolveWebhookPath, m as isDangerousNameMatchingEnabled, n as GROUP_POLICY_BLOCKED_LABEL, u as createChannelPairingController, w as resolveAllowlistProviderRuntimeGroupPolicy } from "./runtime-api-BbVoWRxq.js";
3
- import { n as googleChatApprovalAuth } from "./approval-auth-C-vWY4bY.js";
3
+ import { n as googleChatApprovalAuth } from "./approval-auth-C-eKNZAV.js";
4
4
  import { normalizeLowercaseStringOrEmpty, normalizeOptionalLowercaseString, normalizeOptionalString, normalizeStringEntries } from "openclaw/plugin-sdk/string-coerce-runtime";
5
5
  import { mergePairLoopGuardConfig } from "openclaw/plugin-sdk/pair-loop-guard-runtime";
6
6
  import { recordChannelBotPairLoopAndCheckSuppression } from "openclaw/plugin-sdk/channel-inbound";
@@ -1,4 +1,4 @@
1
- import { t as googlechatDirectoryAdapter } from "./channel.adapters-BQoq1F4R.js";
1
+ import { t as googlechatDirectoryAdapter } from "./channel.adapters-DqnXEL1u.js";
2
2
  //#region extensions/googlechat/directory-contract-api.ts
3
3
  const googlechatDirectoryContractPlugin = {
4
4
  id: "googlechat",
@@ -1,19 +1,19 @@
1
1
  {
2
2
  "name": "@openclaw/googlechat",
3
- "version": "2026.6.8",
3
+ "version": "2026.6.9",
4
4
  "lockfileVersion": 3,
5
5
  "requires": true,
6
6
  "packages": {
7
7
  "": {
8
8
  "name": "@openclaw/googlechat",
9
- "version": "2026.6.8",
9
+ "version": "2026.6.9",
10
10
  "dependencies": {
11
11
  "gaxios": "7.1.4",
12
12
  "google-auth-library": "10.6.2",
13
13
  "zod": "4.4.3"
14
14
  },
15
15
  "peerDependencies": {
16
- "openclaw": ">=2026.6.8"
16
+ "openclaw": ">=2026.6.9"
17
17
  },
18
18
  "peerDependenciesMeta": {
19
19
  "openclaw": {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@openclaw/googlechat",
3
- "version": "2026.6.8",
3
+ "version": "2026.6.9",
4
4
  "description": "OpenClaw Google Chat channel plugin for spaces and direct messages.",
5
5
  "repository": {
6
6
  "type": "git",
@@ -13,7 +13,7 @@
13
13
  "zod": "4.4.3"
14
14
  },
15
15
  "peerDependencies": {
16
- "openclaw": ">=2026.6.8"
16
+ "openclaw": ">=2026.6.9"
17
17
  },
18
18
  "peerDependenciesMeta": {
19
19
  "openclaw": {
@@ -71,10 +71,10 @@
71
71
  "minHostVersion": ">=2026.4.10"
72
72
  },
73
73
  "compat": {
74
- "pluginApi": ">=2026.6.8"
74
+ "pluginApi": ">=2026.6.9"
75
75
  },
76
76
  "build": {
77
- "openclawVersion": "2026.6.8"
77
+ "openclawVersion": "2026.6.9"
78
78
  },
79
79
  "release": {
80
80
  "publishToClawHub": true,