@openclaw/googlechat 2026.8.1-beta.2 → 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.
@@ -1,6 +1,6 @@
1
1
  import { l as resolveGoogleChatAccount } from "./channel-base-BpHXDsur.js";
2
- import { m as resolveGoogleChatOutboundSpace, y as sendGoogleChatMessage } from "./channel.adapters-DiI1p1ml.js";
3
- import { n as describeGoogleChatMessageTool } from "./channel-DkSxE2Ch.js";
2
+ import { m as resolveGoogleChatOutboundSpace, y as sendGoogleChatMessage } from "./channel.adapters-FZq5jdkN.js";
3
+ import { n as describeGoogleChatMessageTool } from "./channel-Cy93IxLN.js";
4
4
  import { extractToolSend } from "openclaw/plugin-sdk/tool-send";
5
5
  import { jsonResult, readStringArrayParam, readStringParam } from "openclaw/plugin-sdk/channel-actions";
6
6
  //#region extensions/googlechat/src/actions.ts
package/dist/api.js CHANGED
@@ -1,3 +1,3 @@
1
1
  import { a as googlechatSetupAdapter, i as googlechatSetupWizard } from "./channel-base-BpHXDsur.js";
2
- import { t as googlechatPlugin } from "./channel-DkSxE2Ch.js";
2
+ import { t as googlechatPlugin } from "./channel-Cy93IxLN.js";
3
3
  export { googlechatPlugin, googlechatSetupAdapter, googlechatSetupWizard };
@@ -1,5 +1,5 @@
1
1
  import { l as resolveGoogleChatAccount } from "./channel-base-BpHXDsur.js";
2
- import { d as isGoogleChatUserTarget, f as normalizeGoogleChatTarget } from "./channel.adapters-DiI1p1ml.js";
2
+ import { d as isGoogleChatUserTarget, f as normalizeGoogleChatTarget } from "./channel.adapters-FZq5jdkN.js";
3
3
  import { normalizeLowercaseStringOrEmpty } from "openclaw/plugin-sdk/string-coerce-runtime";
4
4
  import { createChannelApprovalAuth } 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-BpHXDsur.js";
2
- import { A as registerGoogleChatManualApprovalFollowupSuppression, C as buildGoogleChatApprovalActionParameters, E as createGoogleChatApprovalToken, M as unregisterGoogleChatApprovalCardBindings, N as unregisterGoogleChatManualApprovalFollowupSuppression, S as GOOGLECHAT_APPROVAL_ACTION, b as updateGoogleChatMessage, k as registerGoogleChatApprovalCardBinding, m as resolveGoogleChatOutboundSpace, y as sendGoogleChatMessage } from "./channel.adapters-DiI1p1ml.js";
3
- import { i as shouldHandleGoogleChatNativeApprovalRequest, r as isGoogleChatNativeApprovalClientEnabled } from "./channel-DkSxE2Ch.js";
2
+ import { A as registerGoogleChatManualApprovalFollowupSuppression, C as buildGoogleChatApprovalActionParameters, E as createGoogleChatApprovalToken, M as unregisterGoogleChatApprovalCardBindings, N as unregisterGoogleChatManualApprovalFollowupSuppression, S as GOOGLECHAT_APPROVAL_ACTION, b as updateGoogleChatMessage, k as registerGoogleChatApprovalCardBinding, m as resolveGoogleChatOutboundSpace, y as sendGoogleChatMessage } from "./channel.adapters-FZq5jdkN.js";
3
+ import { i as shouldHandleGoogleChatNativeApprovalRequest, r as isGoogleChatNativeApprovalClientEnabled } from "./channel-Cy93IxLN.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 { truncateUtf16Safe } from "openclaw/plugin-sdk/text-utility-runtime";
@@ -1,8 +1,8 @@
1
1
  import { c as resolveDefaultGoogleChatAccountId, l as resolveGoogleChatAccount, n as createGoogleChatPluginBase, o as inspectGoogleChatAccount, s as listGoogleChatAccountIds, t as GOOGLECHAT_CHANNEL_ID } from "./channel-base-BpHXDsur.js";
2
- import { a as googlechatPairingTextAdapter, d as isGoogleChatUserTarget, f as normalizeGoogleChatTarget, i as googlechatOutboundAdapter, n as googlechatGroupsAdapter, o as googlechatSecurityAdapter, p as resolveGoogleChatOutboundSessionRoute, r as googlechatMessageAdapter, s as googlechatThreadingAdapter, t as googlechatDirectoryAdapter, u as isGoogleChatSpaceTarget } from "./channel.adapters-DiI1p1ml.js";
2
+ import { a as googlechatPairingTextAdapter, d as isGoogleChatUserTarget, f as normalizeGoogleChatTarget, i as googlechatOutboundAdapter, n as googlechatGroupsAdapter, o as googlechatSecurityAdapter, p as resolveGoogleChatOutboundSessionRoute, r as googlechatMessageAdapter, s as googlechatThreadingAdapter, t as googlechatDirectoryAdapter, u as isGoogleChatSpaceTarget } from "./channel.adapters-FZq5jdkN.js";
3
3
  import { n as buildChannelConfigSchema, t as GoogleChatConfigSchema } from "./config-api-CsD0IFxF.js";
4
4
  import { t as DEFAULT_ACCOUNT_ID } from "./runtime-api-Dh0CNVS4.js";
5
- import { n as googleChatApprovalAuth, r as normalizeGoogleChatApproverId, t as getGoogleChatApprovalApprovers } from "./approval-auth-Bm8YFEkI.js";
5
+ import { n as googleChatApprovalAuth, r as normalizeGoogleChatApproverId, t as getGoogleChatApprovalApprovers } from "./approval-auth-AECosdcm.js";
6
6
  import { n as normalizeCompatibilityConfig, t as legacyConfigRules } from "./doctor-contract-BLvSmTXT.js";
7
7
  import { n as collectRuntimeConfigAssignments, r as secretTargetRegistryEntries } from "./secret-contract-BFYyuE0F.js";
8
8
  import { createChatChannelPlugin } from "openclaw/plugin-sdk/channel-core";
@@ -142,7 +142,7 @@ const googleChatApprovalCapability = createApproverRestrictedNativeApprovalCapab
142
142
  approvalKind,
143
143
  request
144
144
  }),
145
- load: async () => (await import("./approval-handler.runtime-B-p-W-_V.js")).googleChatApprovalNativeRuntime
145
+ load: async () => (await import("./approval-handler.runtime-DcfApI4d.js")).googleChatApprovalNativeRuntime
146
146
  })
147
147
  });
148
148
  const collectGoogleChatMutableAllowlistWarnings = createDangerousNameMatchingMutableAllowlistWarningCollector({
@@ -163,7 +163,7 @@ const collectGoogleChatMutableAllowlistWarnings = createDangerousNameMatchingMut
163
163
  });
164
164
  //#endregion
165
165
  //#region extensions/googlechat/src/gateway.ts
166
- const loadGoogleChatChannelRuntime$1 = createLazyRuntimeNamedExport(() => import("./channel.runtime-CqOzrZWb.js"), "googleChatChannelRuntime");
166
+ const loadGoogleChatChannelRuntime$1 = createLazyRuntimeNamedExport(() => import("./channel.runtime-CU_z4ppv.js"), "googleChatChannelRuntime");
167
167
  const UNRESOLVED_WEBHOOK_URL_ERROR = "Invalid webhookUrl: expected an absolute URL such as https://chat.example.com/googlechat. No inbound webhook route was registered.";
168
168
  async function startGoogleChatGatewayAccount(ctx) {
169
169
  const account = ctx.account;
@@ -241,13 +241,13 @@ function describeGoogleChatMessageTool({ cfg, accountId }) {
241
241
  }
242
242
  //#endregion
243
243
  //#region extensions/googlechat/src/channel.ts
244
- const loadGoogleChatChannelRuntime = createLazyRuntimeNamedExport(() => import("./channel.runtime-CqOzrZWb.js"), "googleChatChannelRuntime");
244
+ const loadGoogleChatChannelRuntime = createLazyRuntimeNamedExport(() => import("./channel.runtime-CU_z4ppv.js"), "googleChatChannelRuntime");
245
245
  const googlechatActions = {
246
246
  describeMessageTool: describeGoogleChatMessageTool,
247
247
  supportsAction: ({ action }) => action === "send",
248
248
  extractToolSend: ({ args }) => extractToolSend(args, "sendMessage"),
249
249
  handleAction: async (ctx) => {
250
- const { googlechatMessageActions } = await import("./actions-BIY4DNRJ.js");
250
+ const { googlechatMessageActions } = await import("./actions-B5wHFHkX.js");
251
251
  if (!googlechatMessageActions.handleAction) throw new Error("Google Chat actions are not available.");
252
252
  return await googlechatMessageActions.handleAction(ctx);
253
253
  }
@@ -1,2 +1,2 @@
1
- import { t as googlechatPlugin } from "./channel-DkSxE2Ch.js";
1
+ import { t as googlechatPlugin } from "./channel-Cy93IxLN.js";
2
2
  export { googlechatPlugin };
@@ -16,7 +16,7 @@ import { createMessageReceiptFromOutboundResults, defineChannelMessageAdapter, s
16
16
  import { FormatCapabilityProfile, markdownToIR, renderMarkdownIRChunksWithinLimit, renderMarkdownWithMarkers, sanitizeAssistantVisibleText } from "openclaw/plugin-sdk/text-chunking";
17
17
  import fs from "node:fs/promises";
18
18
  import { adaptScopedAccountAccessor } from "openclaw/plugin-sdk/channel-config-helpers";
19
- import { buildChannelGroupsScopeTree, composeAccountWarningCollectors, createAllowlistProviderOpenWarningCollector, resolveScopeRequireMention } from "openclaw/plugin-sdk/channel-policy";
19
+ import { buildChannelGroupsScopeTree, createAllowlistProviderOpenWarningCollector, createConditionalWarningCollector, resolveScopeRequireMention } from "openclaw/plugin-sdk/channel-policy";
20
20
  import { createChannelDirectoryAdapter, listResolvedDirectoryGroupEntriesFromMapKeys, listResolvedDirectoryUserEntriesFromAllowFrom } from "openclaw/plugin-sdk/directory-runtime";
21
21
  //#region extensions/googlechat/src/approval-card-actions.ts
22
22
  const GOOGLECHAT_APPROVAL_ACTION = "openclaw.approval";
@@ -293,15 +293,19 @@ function assertUrlPrefixField(record, fieldName, expectedPrefix) {
293
293
  function validateGoogleChatServiceAccountCredentials(credentials) {
294
294
  const type = readOptionalTrimmedString(credentials, "type");
295
295
  if (type && type !== "service_account") throw new Error(`Google Chat credentials must use service_account auth, got "${type}" instead`);
296
- readRequiredTrimmedString(credentials, "client_email");
297
- readRequiredTrimmedString(credentials, "private_key");
296
+ const clientEmail = readRequiredTrimmedString(credentials, "client_email");
297
+ const privateKey = readRequiredTrimmedString(credentials, "private_key");
298
298
  const universeDomain = readOptionalTrimmedString(credentials, "universe_domain");
299
299
  if (universeDomain && universeDomain !== GOOGLE_AUTH_UNIVERSE_DOMAIN) throw new Error(`Google Chat service account field "universe_domain" must be ${GOOGLE_AUTH_UNIVERSE_DOMAIN}, got ${universeDomain}`);
300
300
  assertExactUrlField(credentials, "auth_uri", GOOGLE_AUTH_URI);
301
301
  assertExactUrlField(credentials, "auth_provider_x509_cert_url", GOOGLE_AUTH_PROVIDER_CERTS_URL);
302
302
  assertExactUrlField(credentials, "token_uri", GOOGLE_AUTH_TOKEN_URI);
303
303
  assertUrlPrefixField(credentials, "client_x509_cert_url", GOOGLE_CLIENT_CERTS_URL_PREFIX);
304
- return credentials;
304
+ return {
305
+ ...credentials,
306
+ client_email: clientEmail,
307
+ private_key: privateKey
308
+ };
305
309
  }
306
310
  async function readCredentialsFile(filePath) {
307
311
  const resolvedPath = resolveUserPath(filePath);
@@ -972,16 +976,18 @@ function projectGoogleChatLinkLabels(ir) {
972
976
  } : ir;
973
977
  }
974
978
  function markGoogleChatBulletLists(ir, markerToken) {
975
- let text = ir.text;
979
+ let characters;
976
980
  for (const item of ir.listItems ?? []) {
977
981
  const marker = item.listMarker;
978
- if (item.kind !== "bullet" || !marker || text.slice(marker.start, marker.end) !== "• ") continue;
979
- text = `${text.slice(0, marker.start)}${markerToken}${text.slice(marker.end)}`;
982
+ if (item.kind !== "bullet" || !marker || marker.end !== marker.start + 2 || ir.text[marker.start] !== "•" || ir.text[marker.start + 1] !== " ") continue;
983
+ characters ??= ir.text.split("");
984
+ characters[marker.start] = markerToken[0] ?? "";
985
+ characters[marker.start + 1] = markerToken[1] ?? "";
980
986
  }
981
- return text === ir.text ? ir : {
987
+ return characters ? {
982
988
  ...ir,
983
- text
984
- };
989
+ text: characters.join("")
990
+ } : ir;
985
991
  }
986
992
  function projectUnsafeCodeFallbacks(ir) {
987
993
  let text = ir.text;
@@ -1173,7 +1179,7 @@ function resolveGoogleChatGroupRequireMention(params) {
1173
1179
  }
1174
1180
  //#endregion
1175
1181
  //#region extensions/googlechat/src/channel.adapters.ts
1176
- const loadGoogleChatChannelRuntime = createLazyRuntimeNamedExport(() => import("./channel.runtime-CqOzrZWb.js"), "googleChatChannelRuntime");
1182
+ const loadGoogleChatChannelRuntime = createLazyRuntimeNamedExport(() => import("./channel.runtime-CU_z4ppv.js"), "googleChatChannelRuntime");
1177
1183
  function createGoogleChatSendReceipt(params) {
1178
1184
  const messageId = params.messageId?.trim();
1179
1185
  return createMessageReceiptFromOutboundResults({
@@ -1187,7 +1193,7 @@ function createGoogleChatSendReceipt(params) {
1187
1193
  kind: params.kind
1188
1194
  });
1189
1195
  }
1190
- const collectGoogleChatSecurityWarnings = composeAccountWarningCollectors(createAllowlistProviderOpenWarningCollector({
1196
+ const collectGoogleChatGroupPolicyWarnings = createAllowlistProviderOpenWarningCollector({
1191
1197
  providerConfigPresent: (cfg) => cfg.channels?.googlechat !== void 0,
1192
1198
  resolveGroupPolicy: (account) => account.config.groupPolicy,
1193
1199
  buildOpenWarning: {
@@ -1195,7 +1201,14 @@ const collectGoogleChatSecurityWarnings = composeAccountWarningCollectors(create
1195
1201
  openBehavior: "allows any space to trigger (mention-gated)",
1196
1202
  remediation: "Set channels.googlechat.groupPolicy=\"allowlist\" and configure channels.googlechat.groups"
1197
1203
  }
1198
- }), (account) => account.config.dmPolicy === "open" && "- Google Chat DMs are open to anyone. Set channels.googlechat.dmPolicy=\"pairing\" or \"allowlist\".");
1204
+ });
1205
+ const collectGoogleChatOpenGroupFindings = createConditionalWarningCollector.findings({
1206
+ collectWarnings: collectGoogleChatGroupPolicyWarnings,
1207
+ checkId: "channels.googlechat.groups.open",
1208
+ severity: "critical",
1209
+ title: "Google Chat security warning"
1210
+ });
1211
+ const collectGoogleChatSecurityWarnings = (params) => [...collectGoogleChatOpenGroupFindings(params), ...params.account.config.dmPolicy === "open" ? ["- Google Chat DMs are open to anyone. Set channels.googlechat.dmPolicy=\"pairing\" or \"allowlist\"."] : []];
1199
1212
  const googlechatGroupsAdapter = { resolveRequireMention: resolveGoogleChatGroupRequireMention };
1200
1213
  const googlechatDirectoryAdapter = createChannelDirectoryAdapter({
1201
1214
  listPeers: async (params) => listResolvedDirectoryUserEntriesFromAllowFrom({
@@ -1,6 +1,6 @@
1
- import { D as getGoogleChatApprovalCardBinding, O as readGoogleChatApprovalActionToken, T as completeGoogleChatApprovalCardBinding, _ as downloadGoogleChatMedia, b as updateGoogleChatMessage, c as buildGoogleChatGroupPolicyScope, g as deleteGoogleChatMessage, h as GoogleChatApiError, j as releaseGoogleChatApprovalCardBinding, l as isGoogleChatGroupSpace, v as probeGoogleChat, w as claimGoogleChatApprovalCardBinding, x as verifyGoogleChatRequest, y as sendGoogleChatMessage } from "./channel.adapters-DiI1p1ml.js";
1
+ import { D as getGoogleChatApprovalCardBinding, O as readGoogleChatApprovalActionToken, T as completeGoogleChatApprovalCardBinding, _ as downloadGoogleChatMedia, b as updateGoogleChatMessage, c as buildGoogleChatGroupPolicyScope, g as deleteGoogleChatMessage, h as GoogleChatApiError, j as releaseGoogleChatApprovalCardBinding, l as isGoogleChatGroupSpace, v as probeGoogleChat, w as claimGoogleChatApprovalCardBinding, x as verifyGoogleChatRequest, y as sendGoogleChatMessage } from "./channel.adapters-FZq5jdkN.js";
2
2
  import { C as resolveWebhookPath, E as warnMissingProviderGroupPolicyFallbackOnce, O as getGoogleChatRuntime, b as resolveAllowlistProviderRuntimeGroupPolicy, c as createChannelPairingController, f as isDangerousNameMatchingEnabled, n as GROUP_POLICY_BLOCKED_LABEL, x as resolveDefaultGroupPolicy } from "./runtime-api-Dh0CNVS4.js";
3
- import { n as googleChatApprovalAuth } from "./approval-auth-Bm8YFEkI.js";
3
+ import { n as googleChatApprovalAuth } from "./approval-auth-AECosdcm.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 { truncateUtf16Safe } from "openclaw/plugin-sdk/text-utility-runtime";
@@ -13,10 +13,11 @@ import { registerWebhookTargetWithPluginRoute, resolveWebhookTargetWithAuthOrRej
13
13
  import { createWebhookInFlightLimiter, readJsonWebhookBodyOrReject, runDetachedWebhookWork } from "openclaw/plugin-sdk/webhook-request-guards";
14
14
  import { channelBlockedPatch, channelReadyPatch } from "openclaw/plugin-sdk/gateway-runtime";
15
15
  import { isRecord } from "openclaw/plugin-sdk/channel-secret-basic-runtime";
16
+ import { resolveAgentConfig } from "openclaw/plugin-sdk/agent-scope-runtime";
17
+ import { parseDateStringTimestampMs } from "openclaw/plugin-sdk/number-runtime";
16
18
  import { resolveApprovalOverGateway } from "openclaw/plugin-sdk/approval-gateway-runtime";
17
19
  import { channelIngressRoutes, createChannelIngressResolver, createStandardRawEventIngressMonitor, defineStableChannelIngressIdentity } from "openclaw/plugin-sdk/channel-ingress-runtime";
18
20
  import { resolveSendableOutboundReplyParts } from "openclaw/plugin-sdk/reply-payload";
19
- import { parseDateStringTimestampMs } from "openclaw/plugin-sdk/number-runtime";
20
21
  //#region extensions/googlechat/src/approval-terminal-card.ts
21
22
  const GOOGLECHAT_APPROVAL_CARD_ID = "openclaw-approval";
22
23
  const MAX_TEXT_PARAGRAPH_CHARS = 1800;
@@ -1006,7 +1007,7 @@ async function processGoogleChatEvent(event, target, turnAdoptionLifecycle) {
1006
1007
  function resolveBotDisplayName(params) {
1007
1008
  const { accountName, agentId, config } = params;
1008
1009
  if (accountName?.trim()) return accountName.trim();
1009
- const agent = config.agents?.list?.find((a) => a.id === agentId);
1010
+ const agent = resolveAgentConfig(config, agentId);
1010
1011
  if (agent?.name?.trim()) return agent.name.trim();
1011
1012
  return "OpenClaw";
1012
1013
  }
@@ -1106,7 +1107,7 @@ async function processMessageWithPipeline(params) {
1106
1107
  });
1107
1108
  runtime.error?.(`[${account.accountId}] ${notice} Increase channels.googlechat.mediaMaxMb to process larger attachments.`);
1108
1109
  }
1109
- const media = await toInboundMediaFactsWithMetadata(mediaInputs);
1110
+ const media = mediaInputs.length === 0 ? [] : await toInboundMediaFactsWithMetadata(mediaInputs);
1110
1111
  const fromLabel = isGroup ? space.displayName || `space:${spaceId}` : senderName || `user:${senderId}`;
1111
1112
  const timestampMs = parseDateStringTimestampMs(event.eventTime);
1112
1113
  const body = buildEnvelope({
@@ -1,4 +1,4 @@
1
- import { t as googlechatDirectoryAdapter } from "./channel.adapters-DiI1p1ml.js";
1
+ import { t as googlechatDirectoryAdapter } from "./channel.adapters-FZq5jdkN.js";
2
2
  //#region extensions/googlechat/directory-contract-api.ts
3
3
  const googlechatDirectoryContractPlugin = {
4
4
  id: "googlechat",
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@openclaw/googlechat",
3
- "version": "2026.8.1-beta.2",
3
+ "version": "2026.8.1-beta.3",
4
4
  "description": "OpenClaw Google Chat channel plugin for spaces and direct messages.",
5
5
  "repository": {
6
6
  "type": "git",
@@ -12,7 +12,7 @@
12
12
  "zod": "4.4.3"
13
13
  },
14
14
  "peerDependencies": {
15
- "openclaw": ">=2026.8.1-beta.2"
15
+ "openclaw": ">=2026.8.1-beta.3"
16
16
  },
17
17
  "peerDependenciesMeta": {
18
18
  "openclaw": {
@@ -134,10 +134,10 @@
134
134
  "minHostVersion": ">=2026.4.10"
135
135
  },
136
136
  "compat": {
137
- "pluginApi": ">=2026.8.1-beta.2"
137
+ "pluginApi": ">=2026.8.1-beta.3"
138
138
  },
139
139
  "build": {
140
- "openclawVersion": "2026.8.1-beta.2"
140
+ "openclawVersion": "2026.8.1-beta.3"
141
141
  },
142
142
  "release": {
143
143
  "publishToClawHub": true,