@openclaw/slack 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.
Files changed (44) hide show
  1. package/dist/{action-runtime-CgrHdqkC.js → action-runtime-CkD5nTPl.js} +10 -20
  2. package/dist/action-runtime.runtime-CJyuCUxj.js +2 -0
  3. package/dist/{actions-YkhEE5f1.js → actions-B2w2hCZ2.js} +7 -3
  4. package/dist/{actions.runtime-DyVzqzLc.js → actions.runtime-B56qRt06.js} +1 -1
  5. package/dist/api.js +12 -12
  6. package/dist/{approval-handler.runtime-KWkR1mEG.js → approval-handler.runtime-BS6xpR-X.js} +2 -2
  7. package/dist/{channel-BxD37X5Y.js → channel-CwSI6hhC.js} +51 -39
  8. package/dist/channel-plugin-api.js +1 -1
  9. package/dist/{channel.setup-W5YnieWd.js → channel.setup-WLGVcaSf.js} +1 -1
  10. package/dist/{client-Cn2WwpcA.js → client-DhaHONzg.js} +1 -1
  11. package/dist/{directory-config-8UPAEyNg.js → directory-config-Dmhi8ECy.js} +2 -2
  12. package/dist/directory-contract-api.js +1 -1
  13. package/dist/{directory-live-C1acgXKJ.js → directory-live-D_pIXtL1.js} +1 -1
  14. package/dist/{message-tool-api-B9M0zzlQ.js → message-tool-api-NLAYFat2.js} +18 -1
  15. package/dist/message-tool-api.js +1 -1
  16. package/dist/{monitor-DwDmBYfl.js → monitor-CAdKQeRW.js} +3 -3
  17. package/dist/{outbound-adapter-DvXnHfDP.js → outbound-adapter-CBFfXlOI.js} +3 -2
  18. package/dist/{pipeline.runtime-1FYOQOt_.js → pipeline.runtime-DQBGMhhW.js} +38 -31
  19. package/dist/{policy-DT3mRh58.js → policy-Dfbxkneh.js} +1 -1
  20. package/dist/{probe-BTKzLT2u.js → probe-C3PL00Ms.js} +1 -1
  21. package/dist/{provider-ChhYGpXx.js → provider-DbHhtmBz.js} +146 -32
  22. package/dist/{replies-Bt4nWmSd.js → replies-CH4Dmgbr.js} +2 -2
  23. package/dist/{thread-ts-Cffag8e2.js → reply-blocks-DSfujQlj.js} +4 -15
  24. package/dist/{resolve-channels-DX2GSx9c.js → resolve-channels-DNiE0Z0_.js} +1 -1
  25. package/dist/{resolve-users-DOULgUwy.js → resolve-users-D_TmaIfG.js} +1 -1
  26. package/dist/{runtime-api-DudG6lbf.js → runtime-api-DYg05-Op.js} +2 -2
  27. package/dist/runtime-api.js +10 -10
  28. package/dist/{scopes-CErQL0td.js → scopes-CR4oXiXN.js} +1 -1
  29. package/dist/{send-rekB-Xjp.js → send-EpqsWCGd.js} +20 -8
  30. package/dist/send.runtime-CbeGF-al.js +2 -0
  31. package/dist/setup-plugin-api.js +1 -1
  32. package/dist/{setup-surface-NNMjGpXc.js → setup-surface-BHsOhTJd.js} +3 -3
  33. package/dist/{shared-Bkkmro6q.js → shared-BxzdaqOc.js} +1 -1
  34. package/dist/{slash-dispatch.runtime-Dvvs747S.js → slash-dispatch.runtime-BOl9Cbn9.js} +1 -1
  35. package/dist/{target-parsing-C7eeWg7M.js → target-parsing-3jYH8LfB.js} +6 -1
  36. package/dist/targets-Dll4NJgs.js +13 -0
  37. package/dist/thread-ts-DUGhaYKq.js +13 -0
  38. package/node_modules/semver/classes/range.js +11 -2
  39. package/node_modules/semver/package.json +2 -2
  40. package/npm-shrinkwrap.json +6 -6
  41. package/package.json +4 -4
  42. package/dist/action-runtime.runtime-D05xDf1s.js +0 -2
  43. package/dist/send.runtime-DGyqPLWj.js +0 -2
  44. package/dist/targets-nUqxHGgg.js +0 -2
@@ -1,15 +1,15 @@
1
1
  import { l as resolveSlackReplyToMode } from "./accounts-f6Xcv9Vi.js";
2
- import { r as parseSlackTarget } from "./target-parsing-C7eeWg7M.js";
3
- import "./targets-nUqxHGgg.js";
4
- import { b as truncateSlackText, f as normalizeAllowListLower, h as resolveSlackAllowListMatch, p as normalizeSlackAllowOwnerEntry, s as SLACK_TEXT_LIMIT } from "./thread-ts-Cffag8e2.js";
2
+ import { r as parseSlackTarget } from "./target-parsing-3jYH8LfB.js";
3
+ import "./targets-Dll4NJgs.js";
4
+ import { a as SLACK_TEXT_LIMIT, d as normalizeSlackAllowOwnerEntry, p as resolveSlackAllowListMatch, u as normalizeAllowListLower, v as truncateSlackText } from "./reply-blocks-DSfujQlj.js";
5
5
  import { n as isSlackInteractiveRepliesEnabled, t as compileSlackInteractiveReplies } from "./interactive-replies-DrBq4Mld.js";
6
6
  import { n as resolveSlackNativeStreaming, r as resolveSlackStreamingMode, t as mapStreamingModeToSlackLegacyDraftStreamMode } from "./streaming-compat-DjlgH-Be.js";
7
- import { a as recordSlackThreadParticipation, i as hasSlackThreadParticipationWithPersistence, s as normalizeSlackOutboundText, t as sendMessageSlack } from "./send-rekB-Xjp.js";
8
- import { _ as resolveSlackThreadStarter, b as buildSlackEditTextPayload, f as removeSlackReaction, g as resolveSlackThreadHistory, l as reactSlackMessage, r as editSlackMessage, t as deleteSlackMessage, y as formatSlackFileReference } from "./actions-YkhEE5f1.js";
7
+ import { a as recordSlackThreadParticipation, i as hasSlackThreadParticipationWithPersistence, s as normalizeSlackOutboundText, t as sendMessageSlack } from "./send-EpqsWCGd.js";
8
+ import { _ as resolveSlackThreadStarter, b as buildSlackEditTextPayload, f as removeSlackReaction, g as resolveSlackThreadHistory, l as reactSlackMessage, r as editSlackMessage, t as deleteSlackMessage, y as formatSlackFileReference } from "./actions-B2w2hCZ2.js";
9
9
  import { t as formatSlackError } from "./errors-CZtmv-h0.js";
10
- import { _ as resolveStorePath, a as escapeSlackMrkdwn, b as stripSlackMentionsForCommandDetection, c as authorizeSlackBotRoomMessage, d as buildSlackAssistantThreadMetadata, f as parseSlackAssistantThreadMetadata, g as resolveChannelContextVisibilityMode, h as readSessionUpdatedAt, i as authorizeSlackDirectMessage, l as resolveSlackCommandIngress, m as resolveSlackChatType, o as recordInboundSession, p as normalizeSlackChannelType, r as resolveSlackRoomContextHints, s as resolveConversationLabel$1, u as resolveSlackEffectiveAllowFrom, v as updateLastRoute } from "./provider-ChhYGpXx.js";
11
- import { n as resolveSlackChannelConfig } from "./policy-DT3mRh58.js";
12
- import { a as resolveDeliveredSlackReplyThreadTs, i as readSlackReplyBlocks, n as deliverReplies, o as resolveSlackThreadTs, s as emitSlackMessageSentHooks, t as createSlackReplyDeliveryPlan } from "./replies-Bt4nWmSd.js";
10
+ import { _ as resolveStorePath, a as escapeSlackMrkdwn, b as stripSlackMentionsForCommandDetection, c as authorizeSlackBotRoomMessage, d as buildSlackAssistantThreadMetadata, f as parseSlackAssistantThreadMetadata, g as resolveChannelContextVisibilityMode, h as readSessionUpdatedAt, i as authorizeSlackDirectMessage, l as resolveSlackCommandIngress, m as resolveSlackChatType, o as recordInboundSession, p as normalizeSlackChannelType, r as resolveSlackRoomContextHints, s as resolveConversationLabel$1, u as resolveSlackEffectiveAllowFrom, v as updateLastRoute } from "./provider-DbHhtmBz.js";
11
+ import { n as resolveSlackChannelConfig } from "./policy-Dfbxkneh.js";
12
+ import { a as resolveDeliveredSlackReplyThreadTs, i as readSlackReplyBlocks, n as deliverReplies, o as resolveSlackThreadTs, s as emitSlackMessageSentHooks, t as createSlackReplyDeliveryPlan } from "./replies-CH4Dmgbr.js";
13
13
  import { asOptionalRecord, normalizeLowercaseStringOrEmpty, normalizeOptionalLowercaseString, normalizeOptionalString, readStringValue } from "openclaw/plugin-sdk/string-coerce-runtime";
14
14
  import { resolveAgentRoute, resolveInboundLastRouteSessionKey, resolveThreadSessionKeys } from "openclaw/plugin-sdk/routing";
15
15
  import { buildChannelProgressDraftLine, buildChannelProgressDraftLineForEntry, createChannelMessageReplyPipeline, createChannelProgressDraftGate, createDraftStreamLoop, defineFinalizableLivePreviewAdapter, deliverWithFinalizableLivePreviewAdapter, formatChannelProgressDraftText, isChannelProgressDraftWorkToolName, mergeChannelProgressDraftLine, resolveAgentOutboundIdentity, resolveChannelMessageSourceReplyDeliveryMode, resolveChannelProgressDraftConfig, resolveChannelProgressDraftMaxLineChars, resolveChannelProgressDraftMaxLines, resolveChannelProgressDraftRender, resolveChannelStreamingBlockEnabled, resolveChannelStreamingNativeTransport, resolveChannelStreamingPreviewToolProgress, resolveChannelStreamingSuppressDefaultToolProgressMessages } from "openclaw/plugin-sdk/channel-outbound";
@@ -181,7 +181,7 @@ function compactChunkText(value) {
181
181
  return truncateSlackText(value.replace(/\s+/g, " ").trim(), SLACK_PROGRESS_CHUNK_TEXT_MAX);
182
182
  }
183
183
  function lineDetailParts(line) {
184
- return [line.detail, line.status && !line.detail?.includes(line.status) ? line.status : void 0].map((part) => part?.trim()).filter((part) => Boolean(part));
184
+ return [line.detail, line.status && line.status !== "completed" && !line.detail?.includes(line.status) ? line.status : void 0].map((part) => part?.trim()).filter((part) => Boolean(part));
185
185
  }
186
186
  function legacyLineTitle(line) {
187
187
  return `${line.icon ?? "•"} *${escapeSlackMrkdwn(line.label)}*`;
@@ -192,7 +192,7 @@ function legacyLineDetail(line, maxChars) {
192
192
  }
193
193
  function lineTaskTitle(line, maxLineChars) {
194
194
  const label = line.label.replace(/\s+/g, " ").trim() || line.toolName || line.kind || "Update";
195
- const detail = lineDetailParts(line).join(" · ");
195
+ const detail = lineDetailParts(line).join(" · ") || line.status?.trim();
196
196
  const fallback = line.text.replace(/\s+/g, " ").trim();
197
197
  if (detail) return compactTitle(`${label} — ${compactDetail(detail, maxLineChars)}`);
198
198
  if (fallback && fallback !== label) return compactTitle(fallback);
@@ -314,14 +314,13 @@ function applyAppendOnlyStreamUpdate(params) {
314
314
  //#endregion
315
315
  //#region extensions/slack/src/streaming.ts
316
316
  /**
317
- * Thrown when Slack rejects a stream flush/finalize with a recipient-resolution
318
- * error (see {@link BENIGN_SLACK_FINALIZE_ERROR_CODES}) while text is still
319
- * only buffered locally by the Slack SDK. Carries the pending text so the
317
+ * Thrown when Slack definitively rejects a stream flush/finalize while text
318
+ * remains buffered locally by the Slack SDK. Carries the pending text so the
320
319
  * caller can deliver it via the normal Slack reply path.
321
320
  */
322
321
  var SlackStreamNotDeliveredError = class extends Error {
323
322
  constructor(pendingText, slackCode) {
324
- super(`slack-stream: finalize failed with ${slackCode} before any text reached Slack (${pendingText.length} chars pending)`);
323
+ super(`slack-stream: finalize failed with ${slackCode} before buffered text reached Slack (${pendingText.length} chars pending)`);
325
324
  this.name = "SlackStreamNotDeliveredError";
326
325
  this.pendingText = pendingText;
327
326
  this.slackCode = slackCode;
@@ -404,17 +403,18 @@ async function appendSlackStream(params) {
404
403
  * After calling this the stream message becomes a normal Slack message.
405
404
  * Optionally include final text to append before stopping.
406
405
  *
407
- * If Slack's `chat.stopStream` responds with a known benign finalize error
408
- * (see {@link BENIGN_SLACK_FINALIZE_ERROR_CODES}) AND any prior `append`
409
- * has already landed on Slack, the error is swallowed and the session is
410
- * marked stopped - the already-delivered text stays visible.
406
+ * If Slack's `chat.stopStream` responds with a definitive recipient/channel
407
+ * rejection while text is still buffered locally, this function throws a
408
+ * {@link SlackStreamNotDeliveredError} carrying that pending text so the caller
409
+ * can deliver it through the normal Slack reply path. Ambiguous failures
410
+ * propagate unchanged because Slack may have committed the request.
411
411
  *
412
- * If the same benign error fires while text is still only buffered locally
413
- * (e.g. short replies that never exceeded the SDK's buffer_size), this
414
- * function throws a {@link SlackStreamNotDeliveredError} carrying that pending
415
- * text so the caller can deliver it through the normal Slack reply path.
412
+ * If Slack responds with a known benign finalize error (see
413
+ * {@link BENIGN_SLACK_FINALIZE_ERROR_CODES}) after prior `append` calls already
414
+ * landed, the error is swallowed and the session is marked stopped - the
415
+ * already-delivered text stays visible.
416
416
  *
417
- * All other errors propagate unchanged.
417
+ * Errors without buffered text propagate unchanged.
418
418
  *
419
419
  * On success, returns the finalized message's Slack `ts` (when reported) so the
420
420
  * caller can emit the `message_sent` hook with a populated `messageId`.
@@ -462,7 +462,8 @@ async function stopSlackStream(params) {
462
462
  const BENIGN_SLACK_FINALIZE_ERROR_CODES = new Set([
463
463
  "user_not_found",
464
464
  "team_not_found",
465
- "missing_recipient_user_id"
465
+ "missing_recipient_user_id",
466
+ "method_not_supported_for_channel_type"
466
467
  ]);
467
468
  function isBenignSlackFinalizeError(err) {
468
469
  const code = extractSlackErrorCode(err);
@@ -626,7 +627,7 @@ const UNICODE_TO_SLACK = {
626
627
  "🛠️": "hammer_and_wrench",
627
628
  "💻": "computer"
628
629
  };
629
- const SLACK_REASONING_TAG_RE = /<\s*(\/?)\s*(?:think(?:ing)?|thought|antthinking)\b[^<>]*>/gi;
630
+ const SLACK_REASONING_TAG_RE = /<\s*(\/?)\s*(?:(?:antml:|mm:)?(?:think(?:ing)?|thought)|antthinking)\b[^<>]*>/gi;
630
631
  const SLACK_REASONING_LABEL_PREFIX_RE = /^\s*(?:>\s*)?Reasoning:\s*/iu;
631
632
  const SLACK_THINKING_LABEL_PREFIX_RE = /^\s*(?:>\s*)?Thinking\.{0,3}(?=\s*(?:\n|_))/iu;
632
633
  function resolveSlackMessageTimestampMs(message) {
@@ -1825,6 +1826,8 @@ async function dispatchPreparedSlackMessage(prepared) {
1825
1826
  disableBlockStreaming,
1826
1827
  onModelSelected,
1827
1828
  suppressDefaultToolProgressMessages: suppressDefaultToolProgressMessages ? true : void 0,
1829
+ allowProgressCallbacksWhenSourceDeliverySuppressed: sourceReplyDeliveryMode === "message_tool_only" && statusReactionsEnabled ? true : void 0,
1830
+ allowToolLifecycleWhenProgressHidden: statusReactionsEnabled ? true : void 0,
1828
1831
  onPartialReply: useStreaming ? void 0 : !previewStreamingEnabled ? void 0 : async (payload) => {
1829
1832
  updateDraftFromPartial(payload.text);
1830
1833
  },
@@ -1850,6 +1853,7 @@ async function dispatchPreparedSlackMessage(prepared) {
1850
1853
  await pushPreviewToolProgress(buildChannelProgressDraftLineForEntry(account.config, {
1851
1854
  event: "item",
1852
1855
  itemId: payload.itemId,
1856
+ toolCallId: payload.toolCallId,
1853
1857
  itemKind: payload.kind,
1854
1858
  title: payload.title,
1855
1859
  name: payload.name,
@@ -1940,12 +1944,15 @@ async function dispatchPreparedSlackMessage(prepared) {
1940
1944
  for (const delivery of streamedDeliveries) delivery.acknowledged = true;
1941
1945
  emitAcknowledgedStreamedDeliveries(stopResult?.messageId);
1942
1946
  } catch (err) {
1943
- if (err instanceof SlackStreamNotDeliveredError) streamFallbackDelivered = await deliverPendingStreamFallback(finalStream, err);
1944
- else {
1947
+ if (err instanceof SlackStreamNotDeliveredError) {
1948
+ streamFallbackDelivered = await deliverPendingStreamFallback(finalStream, err);
1949
+ if (!streamFallbackDelivered) dispatchError ??= err;
1950
+ } else {
1945
1951
  const error = formatSlackError(err);
1946
1952
  emitAcknowledgedStreamedDeliveries();
1947
1953
  emitFailedPendingStreamedDeliveries(error);
1948
1954
  runtime.error?.(danger(`slack-stream: failed to stop stream: ${error}`));
1955
+ if (!finalStream.delivered) dispatchError ??= err;
1949
1956
  }
1950
1957
  }
1951
1958
  for (const kind of [
@@ -1982,9 +1989,9 @@ async function dispatchPreparedSlackMessage(prepared) {
1982
1989
  })();
1983
1990
  else statusReactions.restoreInitial();
1984
1991
  } else await statusReactions.restoreInitial();
1985
- if (dispatchError) throw toLintErrorObject(dispatchError, "Slack dispatch failed");
1986
1992
  const participationThreadTs = usedReplyThreadTs ?? statusThreadTs;
1987
1993
  if (anyReplyDelivered && participationThreadTs) recordSlackThreadParticipation(account.accountId, message.channel, participationThreadTs, { agentId: route.agentId });
1994
+ if (dispatchError) throw toLintErrorObject(dispatchError, "Slack dispatch failed");
1988
1995
  if (!anyReplyDelivered && !draftPreviewCommitted) {
1989
1996
  await draftStream?.clear();
1990
1997
  return;
@@ -2025,7 +2032,7 @@ const SLACK_MENTION_RESOLUTION_MAX_LOOKUPS_PER_MESSAGE = 20;
2025
2032
  const SLACK_USER_MENTION_RE$1 = /<@([A-Z0-9]+)(?:\|[^>]+)?>/gi;
2026
2033
  let slackMediaModulePromise$1;
2027
2034
  function loadSlackMediaModule$1() {
2028
- slackMediaModulePromise$1 ??= import("./actions-YkhEE5f1.js").then((n) => n.h);
2035
+ slackMediaModulePromise$1 ??= import("./actions-B2w2hCZ2.js").then((n) => n.h);
2029
2036
  return slackMediaModulePromise$1;
2030
2037
  }
2031
2038
  function collectUniqueSlackMentionIds$1(texts) {
@@ -2539,7 +2546,7 @@ function formatSlackBotStarterThreadLabel(params) {
2539
2546
  //#region extensions/slack/src/monitor/message-handler/prepare-thread-context.ts
2540
2547
  let slackMediaModulePromise;
2541
2548
  function loadSlackMediaModule() {
2542
- slackMediaModulePromise ??= import("./actions-YkhEE5f1.js").then((n) => n.h);
2549
+ slackMediaModulePromise ??= import("./actions-B2w2hCZ2.js").then((n) => n.h);
2543
2550
  return slackMediaModulePromise;
2544
2551
  }
2545
2552
  const SLACK_THREAD_CONTEXT_USER_LOOKUP_CONCURRENCY = 4;
@@ -3442,7 +3449,7 @@ async function prepareSlackMessage(params) {
3442
3449
  const preview = rawBody.replace(/\s+/g, " ").slice(0, 160);
3443
3450
  const inboundLabel = isDirectMessage ? `Slack DM from ${senderName}` : `Slack message in ${roomLabel} from ${senderName}`;
3444
3451
  const slackFrom = isDirectMessage ? `slack:${message.user}` : isRoom ? `slack:channel:${message.channel}` : `slack:group:${message.channel}`;
3445
- enqueueSystemEvent(`${inboundLabel}: ${preview}`, {
3452
+ enqueueSystemEvent(inboundLabel, {
3446
3453
  sessionKey,
3447
3454
  contextKey: `slack:message:${message.channel}:${message.ts ?? "unknown"}`
3448
3455
  });
@@ -1,4 +1,4 @@
1
- import { m as normalizeSlackSlug } from "./thread-ts-Cffag8e2.js";
1
+ import { f as normalizeSlackSlug } from "./reply-blocks-DSfujQlj.js";
2
2
  import { normalizeLowercaseStringOrEmpty } from "openclaw/plugin-sdk/string-coerce-runtime";
3
3
  import { applyChannelMatchMeta, buildChannelKeyCandidates, resolveChannelEntryMatchWithFallback } from "openclaw/plugin-sdk/channel-targets";
4
4
  import { mergePairLoopGuardConfig } from "openclaw/plugin-sdk/pair-loop-guard-runtime";
@@ -1,5 +1,5 @@
1
1
  import { t as __exportAll } from "./rolldown-runtime-D7D4PA-g.js";
2
- import { r as createSlackWebClient } from "./client-Cn2WwpcA.js";
2
+ import { r as createSlackWebClient } from "./client-DhaHONzg.js";
3
3
  import { t as formatSlackError } from "./errors-CZtmv-h0.js";
4
4
  import { withTimeout } from "openclaw/plugin-sdk/text-utility-runtime";
5
5
  //#region extensions/slack/src/probe.ts
@@ -1,13 +1,13 @@
1
1
  import { n as registerSlackHttpHandler, r as normalizeSlackWebhookPath } from "./registry-bbjH7IHX.js";
2
2
  import { a as resolveSlackAccount, d as resolveSlackBotToken, o as resolveSlackAccountAllowFrom, s as resolveSlackAccountDmPolicy, u as resolveSlackAppToken } from "./accounts-f6Xcv9Vi.js";
3
- import { F as isSlackApprovalAuthorizedSender, L as isSlackExecApprovalAuthorizedSender, b as truncateSlackText, d as normalizeAllowList, f as normalizeAllowListLower, h as resolveSlackAllowListMatch, m as normalizeSlackSlug, p as normalizeSlackAllowOwnerEntry, s as SLACK_TEXT_LIMIT, u as allowListMatches, w as isSlackAnyNativeApprovalClientEnabled } from "./thread-ts-Cffag8e2.js";
4
- import { c as resolveSlackWebClientOptions } from "./client-Cn2WwpcA.js";
3
+ import { F as isSlackExecApprovalAuthorizedSender, N as isSlackApprovalAuthorizedSender, S as isSlackAnyNativeApprovalClientEnabled, a as SLACK_TEXT_LIMIT, c as allowListMatches, d as normalizeSlackAllowOwnerEntry, f as normalizeSlackSlug, l as normalizeAllowList, p as resolveSlackAllowListMatch, u as normalizeAllowListLower, v as truncateSlackText } from "./reply-blocks-DSfujQlj.js";
4
+ import { c as resolveSlackWebClientOptions } from "./client-DhaHONzg.js";
5
5
  import { n as isSlackInteractiveRepliesEnabled, t as compileSlackInteractiveReplies } from "./interactive-replies-DrBq4Mld.js";
6
6
  import { t as getOptionalSlackRuntime } from "./runtime-BOk7xkOl.js";
7
7
  import { t as formatSlackError } from "./errors-CZtmv-h0.js";
8
- import { t as resolveSlackChannelAllowlist } from "./resolve-channels-DX2GSx9c.js";
9
- import { t as resolveSlackUserAllowlist } from "./resolve-users-DOULgUwy.js";
10
- import { n as resolveSlackChannelConfig, r as resolveSlackChannelLabel, t as isSlackChannelAllowedByPolicy } from "./policy-DT3mRh58.js";
8
+ import { t as resolveSlackChannelAllowlist } from "./resolve-channels-DNiE0Z0_.js";
9
+ import { t as resolveSlackUserAllowlist } from "./resolve-users-D_TmaIfG.js";
10
+ import { n as resolveSlackChannelConfig, r as resolveSlackChannelLabel, t as isSlackChannelAllowedByPolicy } from "./policy-Dfbxkneh.js";
11
11
  import { normalizeResolvedSecretInputString } from "openclaw/plugin-sdk/secret-input";
12
12
  import { asOptionalRecord, normalizeLowercaseStringOrEmpty, normalizeOptionalLowercaseString, normalizeOptionalString, normalizeStringEntries, normalizeStringEntriesLower, normalizeUniqueTrimmedStringList } from "openclaw/plugin-sdk/string-coerce-runtime";
13
13
  import { normalizeAccountId, normalizeMainKey, resolveAgentRoute, resolveThreadSessionKeys } from "openclaw/plugin-sdk/routing";
@@ -16,7 +16,7 @@ import { createChannelPairingChallengeIssuer } from "openclaw/plugin-sdk/channel
16
16
  import { CHANNEL_APPROVAL_NATIVE_RUNTIME_CONTEXT_CAPABILITY } from "openclaw/plugin-sdk/approval-handler-adapter-runtime";
17
17
  import { parseExecApprovalCommandText } from "openclaw/plugin-sdk/approval-reply-runtime";
18
18
  import { addAllowlistUserEntriesFromConfigEntry, buildAllowlistResolutionSummary, formatAllowlistMatchMeta, mergeAllowlist, patchAllowlistUsersInConfigEntries, summarizeMapping } from "openclaw/plugin-sdk/allow-from";
19
- import { computeBackoff, createNonExitingRuntime, danger, getChildLogger, logVerbose, shouldLogVerbose, sleepWithAbort, warn } from "openclaw/plugin-sdk/runtime-env";
19
+ import { computeBackoff, createNonExitingRuntime, createSubsystemLogger, danger, getChildLogger, logVerbose, shouldLogVerbose, sleepWithAbort, warn } from "openclaw/plugin-sdk/runtime-env";
20
20
  import { formatErrorMessage } from "openclaw/plugin-sdk/error-runtime";
21
21
  import { pruneMapToMaxSize } from "openclaw/plugin-sdk/collection-runtime";
22
22
  import { asDateTimestampMs, parseFiniteNumber, parseStrictFiniteNumber, resolveExpiresAtMsFromDurationMs, timestampMsToIsoString } from "openclaw/plugin-sdk/number-runtime";
@@ -28,7 +28,7 @@ import { resolveNativeCommandsEnabled, resolveNativeSkillsEnabled } from "opencl
28
28
  import { registerChannelRuntimeContext } from "openclaw/plugin-sdk/channel-runtime-context";
29
29
  import { DEFAULT_GROUP_HISTORY_LIMIT } from "openclaw/plugin-sdk/reply-history";
30
30
  import { installRequestBodyLimitGuard } from "openclaw/plugin-sdk/webhook-request-guards";
31
- import { getRuntimeConfig, getRuntimeConfig as getRuntimeConfig$1 } from "openclaw/plugin-sdk/runtime-config-snapshot";
31
+ import { getRuntimeConfig, getRuntimeConfig as getRuntimeConfig$1, getRuntimeConfigSnapshot } from "openclaw/plugin-sdk/runtime-config-snapshot";
32
32
  import { isDangerousNameMatchingEnabled } from "openclaw/plugin-sdk/dangerous-name-runtime";
33
33
  import { loadSessionStore, readSessionUpdatedAt, resolveSessionKey, resolveStorePath, resolveStorePath as resolveStorePath$1, updateLastRoute } from "openclaw/plugin-sdk/session-store-runtime";
34
34
  import { resolveChannelContextVisibilityMode } from "openclaw/plugin-sdk/context-visibility-runtime";
@@ -177,13 +177,13 @@ function createSlackMonitorContext(params) {
177
177
  };
178
178
  const resolveSlackSystemEventSessionKey = (p) => {
179
179
  const channelId = normalizeOptionalString(p.channelId) ?? "";
180
- if (!channelId) return params.mainKey;
180
+ const senderId = normalizeOptionalString(p.senderId) ?? "";
181
181
  const channelType = normalizeSlackChannelType(p.channelType, channelId);
182
182
  const isDirectMessage = channelType === "im";
183
+ if (!channelId && (!isDirectMessage || !senderId)) return params.mainKey;
183
184
  const isGroup = channelType === "mpim";
184
- const from = isDirectMessage ? `slack:${channelId}` : isGroup ? `slack:group:${channelId}` : `slack:channel:${channelId}`;
185
+ const from = isDirectMessage ? `slack:${channelId || senderId}` : isGroup ? `slack:group:${channelId}` : `slack:channel:${channelId}`;
185
186
  const chatType = isDirectMessage ? "direct" : isGroup ? "group" : "channel";
186
- const senderId = normalizeOptionalString(p.senderId) ?? "";
187
187
  try {
188
188
  const peerKind = isDirectMessage ? "direct" : isGroup ? "group" : "channel";
189
189
  const peerId = isDirectMessage ? senderId : channelId;
@@ -1955,6 +1955,107 @@ function registerModalLifecycleHandler(params) {
1955
1955
  });
1956
1956
  }
1957
1957
  //#endregion
1958
+ //#region extensions/slack/src/monitor/events/interactions.shortcuts.ts
1959
+ function resolveMessageThreadTs(body) {
1960
+ const threadTs = body.message.thread_ts;
1961
+ return typeof threadTs === "string" && threadTs.trim() ? threadTs.trim() : void 0;
1962
+ }
1963
+ async function handleSlackShortcut(params) {
1964
+ const { ack, body } = params.args;
1965
+ await ack();
1966
+ if (params.ctx.shouldDropMismatchedSlackEvent?.(body)) {
1967
+ params.ctx.runtime.log?.("slack:interaction drop shortcut payload (mismatched app/team)");
1968
+ return;
1969
+ }
1970
+ const callbackId = body.callback_id?.trim();
1971
+ const userId = body.user?.id?.trim();
1972
+ if (!callbackId || !userId) {
1973
+ params.ctx.runtime.log?.("slack:interaction drop shortcut reason=invalid-payload");
1974
+ return;
1975
+ }
1976
+ params.trackEvent?.();
1977
+ const isMessageShortcut = body.type === "message_action";
1978
+ const messageBody = isMessageShortcut ? body : void 0;
1979
+ const channelId = messageBody?.channel.id?.trim() || void 0;
1980
+ if (isMessageShortcut && !channelId) {
1981
+ params.ctx.runtime.log?.(`slack:interaction drop shortcut callback=${callbackId} user=${userId} reason=missing-channel`);
1982
+ return;
1983
+ }
1984
+ const threadTs = messageBody ? resolveMessageThreadTs(messageBody) : void 0;
1985
+ const auth = await authorizeSlackSystemEventSender({
1986
+ ctx: params.ctx,
1987
+ senderId: userId,
1988
+ channelId,
1989
+ channelType: isMessageShortcut ? void 0 : "im",
1990
+ expectedSenderId: userId,
1991
+ interactiveEvent: true
1992
+ });
1993
+ if (!auth.allowed) {
1994
+ params.ctx.runtime.log?.(`slack:interaction drop shortcut callback=${callbackId} user=${userId} reason=${auth.reason ?? "unauthorized"}`);
1995
+ return;
1996
+ }
1997
+ const interactionType = isMessageShortcut ? "message_shortcut" : "global_shortcut";
1998
+ const messageTs = messageBody?.message.ts || messageBody?.message_ts;
1999
+ const eventPayload = {
2000
+ interactionType,
2001
+ actionId: `shortcut:${callbackId}`,
2002
+ callbackId,
2003
+ userId,
2004
+ teamId: body.team?.id ?? body.user.team_id,
2005
+ triggerId: body.trigger_id,
2006
+ actionTs: body.action_ts,
2007
+ channelId,
2008
+ channelName: messageBody?.channel.name,
2009
+ messageTs,
2010
+ threadTs,
2011
+ messageUserId: messageBody?.message.user,
2012
+ messageText: messageBody?.message.text,
2013
+ responseUrl: messageBody?.response_url
2014
+ };
2015
+ const sessionKey = params.ctx.resolveSlackSystemEventSessionKey({
2016
+ channelId,
2017
+ channelType: auth.channelType,
2018
+ senderId: userId,
2019
+ threadTs
2020
+ });
2021
+ const contextKey = [
2022
+ "slack:interaction:shortcut",
2023
+ interactionType,
2024
+ callbackId,
2025
+ channelId,
2026
+ messageTs,
2027
+ body.action_ts
2028
+ ].filter(Boolean).join(":");
2029
+ params.ctx.runtime.log?.(`slack:interaction ${interactionType} callback=${callbackId} user=${userId} channel=${channelId ?? "direct"}`);
2030
+ if (enqueueSystemEvent(params.formatSystemEvent(eventPayload), {
2031
+ sessionKey,
2032
+ contextKey,
2033
+ deliveryContext: {
2034
+ channel: "slack",
2035
+ to: auth.channelType === "im" ? `user:${userId}` : `channel:${channelId}`,
2036
+ accountId: params.ctx.accountId,
2037
+ threadId: threadTs
2038
+ }
2039
+ })) requestHeartbeat({
2040
+ source: "hook",
2041
+ intent: "immediate",
2042
+ reason: "hook:slack-interaction",
2043
+ sessionKey,
2044
+ heartbeat: { target: "last" }
2045
+ });
2046
+ }
2047
+ function registerSlackShortcutHandler(params) {
2048
+ if (typeof params.ctx.app.shortcut !== "function") return;
2049
+ params.ctx.app.shortcut(/.+/, async (args) => {
2050
+ await handleSlackShortcut({
2051
+ ctx: params.ctx,
2052
+ trackEvent: params.trackEvent,
2053
+ args,
2054
+ formatSystemEvent: params.formatSystemEvent
2055
+ });
2056
+ });
2057
+ }
2058
+ //#endregion
1958
2059
  //#region extensions/slack/src/monitor/events/interactions.ts
1959
2060
  const SLACK_INTERACTION_EVENT_PREFIX = "Slack interaction: ";
1960
2061
  const REDACTED_INTERACTION_VALUE = "[redacted]";
@@ -2017,11 +2118,14 @@ function buildCompactSlackInteractionPayload(payload) {
2017
2118
  actionId: payload.actionId,
2018
2119
  callbackId: payload.callbackId,
2019
2120
  actionType: payload.actionType,
2121
+ actionTs: payload.actionTs,
2020
2122
  userId: payload.userId,
2021
2123
  teamId: payload.teamId,
2022
2124
  channelId: payload.channelId ?? payload.routedChannelId,
2023
2125
  messageTs: payload.messageTs,
2024
2126
  threadTs: payload.threadTs,
2127
+ messageUserId: payload.messageUserId,
2128
+ messageText: payload.messageText,
2025
2129
  viewId: payload.viewId,
2026
2130
  isCleared: payload.isCleared,
2027
2131
  selectedValues: payload.selectedValues,
@@ -2079,6 +2183,11 @@ function registerSlackInteractionEvents(params) {
2079
2183
  trackEvent,
2080
2184
  formatSystemEvent: formatSlackInteractionSystemEvent
2081
2185
  });
2186
+ registerSlackShortcutHandler({
2187
+ ctx,
2188
+ trackEvent,
2189
+ formatSystemEvent: formatSlackInteractionSystemEvent
2190
+ });
2082
2191
  if (typeof ctx.app.view !== "function") return;
2083
2192
  const modalMatcher = /.*/;
2084
2193
  registerModalLifecycleHandler({
@@ -2214,6 +2323,10 @@ function resolveSlackMessageSubtypeHandler(event) {
2214
2323
  }
2215
2324
  //#endregion
2216
2325
  //#region extensions/slack/src/monitor/events/messages.ts
2326
+ const slackInboundLog = createSubsystemLogger("gateway/channels/slack").child("inbound");
2327
+ function formatSlackInboundLogLine(params) {
2328
+ return `Inbound app_mention ${`slack:${params.workspaceId}:channel:${params.channelId}:user:${params.userId}`} -> bot:${params.botUserId} (${params.channelType}, ${params.bodyChars} chars)`;
2329
+ }
2217
2330
  function isSlackUserId(value) {
2218
2331
  return /^[UW][A-Z0-9]+$/.test(value);
2219
2332
  }
@@ -2329,6 +2442,14 @@ function registerSlackMessageEvents(params) {
2329
2442
  const mention = event;
2330
2443
  const channelType = normalizeSlackChannelType(mention.channel_type, mention.channel);
2331
2444
  if (channelType === "im" || channelType === "mpim") return;
2445
+ slackInboundLog.info(formatSlackInboundLogLine({
2446
+ workspaceId: ctx.teamId,
2447
+ channelId: mention.channel,
2448
+ channelType: channelType ?? "channel",
2449
+ userId: normalizeOptionalString(mention.user) ?? "unknown",
2450
+ botUserId: ctx.botUserId,
2451
+ bodyChars: normalizeOptionalString(mention.text)?.length ?? 0
2452
+ }));
2332
2453
  await handleSlackMessage(mention, {
2333
2454
  source: "app_mention",
2334
2455
  wasMentioned: true
@@ -2699,7 +2820,7 @@ function createSlackThreadTsResolver(params) {
2699
2820
  //#region extensions/slack/src/monitor/message-handler.ts
2700
2821
  let slackMessagePipelinePromise;
2701
2822
  function loadSlackMessagePipeline() {
2702
- slackMessagePipelinePromise ??= import("./pipeline.runtime-1FYOQOt_.js");
2823
+ slackMessagePipelinePromise ??= import("./pipeline.runtime-DQBGMhhW.js");
2703
2824
  return slackMessagePipelinePromise;
2704
2825
  }
2705
2826
  const APP_MENTION_RETRY_TTL_MS = 6e4;
@@ -2873,14 +2994,13 @@ function createSlackMessageHandler(params) {
2873
2994
  }
2874
2995
  //#endregion
2875
2996
  //#region extensions/slack/src/monitor/reconnect-policy.ts
2876
- const SLACK_AUTH_ERROR_RE = /account_inactive|invalid_auth|token_revoked|token_expired|not_authed|org_login_required|team_access_not_granted|missing_scope|cannot_find_service|invalid_token/i;
2997
+ const SLACK_AUTH_ERROR_RE = /account_inactive|invalid_auth|token_revoked|token_expired|not_authed|org_login_required|team_access_not_granted|user_removed_from_team|team_disabled|missing_scope|cannot_find_service|invalid_token/i;
2877
2998
  const NO_ERROR_DETAIL = "no error detail";
2878
2999
  const SLACK_SOCKET_RECONNECT_POLICY = {
2879
3000
  initialMs: 2e3,
2880
3001
  maxMs: 3e4,
2881
3002
  factor: 1.8,
2882
- jitter: .25,
2883
- maxAttempts: 12
3003
+ jitter: .25
2884
3004
  };
2885
3005
  function getSocketEmitter(app) {
2886
3006
  const receiver = app.receiver;
@@ -2928,9 +3048,8 @@ function waitForSlackSocketDisconnect(app, abortSignal) {
2928
3048
  });
2929
3049
  }
2930
3050
  /**
2931
- * Detect non-recoverable Slack API / auth errors that should NOT be retried.
2932
- * These indicate permanent credential problems (revoked bot, deactivated account, etc.)
2933
- * and retrying will never succeed — continuing to retry blocks the entire gateway.
3051
+ * Detect permanent Slack account and credential failures.
3052
+ * Transient request and HTTP failures stay in OpenClaw's reconnect loop.
2934
3053
  */
2935
3054
  function isNonRecoverableSlackAuthError(error) {
2936
3055
  return SLACK_AUTH_ERROR_RE.test(formatUnknownError(error, ""));
@@ -3341,7 +3460,7 @@ function loadSlashCommandsRuntime() {
3341
3460
  return slashCommandsRuntimePromise;
3342
3461
  }
3343
3462
  function loadSlashDispatchRuntime() {
3344
- slashDispatchRuntimePromise ??= import("./slash-dispatch.runtime-Dvvs747S.js");
3463
+ slashDispatchRuntimePromise ??= import("./slash-dispatch.runtime-BOl9Cbn9.js");
3345
3464
  return slashDispatchRuntimePromise;
3346
3465
  }
3347
3466
  function loadSlackPluginCommandsRuntime() {
@@ -3560,13 +3679,14 @@ function buildSlackCommandArgMenuBlocks(params) {
3560
3679
  }
3561
3680
  async function registerSlackMonitorSlashCommands(params) {
3562
3681
  const { ctx, account, trackEvent } = params;
3563
- const cfg = ctx.cfg;
3682
+ const startupCfg = ctx.cfg;
3564
3683
  const runtime = ctx.runtime;
3565
3684
  const supportsInteractiveArgMenus = typeof ctx.app.action === "function";
3566
3685
  let supportsExternalArgMenus = typeof ctx.app.options === "function";
3567
3686
  const slashCommand = resolveSlackSlashCommandConfig(ctx.slashCommand ?? account.config.slashCommand);
3568
3687
  const handleSlashCommand = async (p) => {
3569
3688
  const { command, ack, respond, body, prompt, commandArgs, commandDefinition } = p;
3689
+ const cfg = getRuntimeConfigSnapshot() ?? ctx.cfg;
3570
3690
  try {
3571
3691
  if (ctx.shouldDropMismatchedSlackEvent?.(body)) {
3572
3692
  await ack();
@@ -3879,19 +3999,19 @@ async function registerSlackMonitorSlashCommands(params) {
3879
3999
  const nativeEnabled = resolveNativeCommandsEnabled({
3880
4000
  providerId: "slack",
3881
4001
  providerSetting: account.config.commands?.native,
3882
- globalSetting: cfg.commands?.native
4002
+ globalSetting: startupCfg.commands?.native
3883
4003
  });
3884
4004
  const nativeSkillsEnabled = resolveNativeSkillsEnabled({
3885
4005
  providerId: "slack",
3886
4006
  providerSetting: account.config.commands?.nativeSkills,
3887
- globalSetting: cfg.commands?.nativeSkills
4007
+ globalSetting: startupCfg.commands?.nativeSkills
3888
4008
  });
3889
4009
  let nativeCommands = [];
3890
4010
  let slashCommandsRuntime = null;
3891
4011
  if (nativeEnabled) {
3892
4012
  slashCommandsRuntime = await loadSlashCommandsRuntime();
3893
- const skillCommands = nativeSkillsEnabled ? (await loadSlashSkillCommandsRuntime()).listSkillCommandsForAgents({ cfg }) : [];
3894
- nativeCommands = slashCommandsRuntime.listNativeCommandSpecsForConfig(cfg, {
4013
+ const skillCommands = nativeSkillsEnabled ? (await loadSlashSkillCommandsRuntime()).listSkillCommandsForAgents({ cfg: startupCfg }) : [];
4014
+ nativeCommands = slashCommandsRuntime.listNativeCommandSpecsForConfig(startupCfg, {
3895
4015
  skillCommands,
3896
4016
  provider: "slack"
3897
4017
  });
@@ -4071,15 +4191,13 @@ function resolveStableSlackUserAllowlistEntries(entries) {
4071
4191
  return resolved;
4072
4192
  }
4073
4193
  function formatSlackSocketReconnectMessage(params) {
4074
- const maxAttempts = params.maxAttempts > 0 ? String(params.maxAttempts) : "∞";
4075
4194
  const suffix = params.error ? ` (${formatUnknownError(params.error)})` : "";
4076
- return `slack socket disconnected (${params.event}); reconnecting in ${Math.round(params.delayMs / 1e3)}s (attempt ${params.attempt}/${maxAttempts})${suffix}`;
4195
+ return `slack socket disconnected (${params.event}); reconnecting in ${Math.round(params.delayMs / 1e3)}s (attempt ${params.attempt}/∞)${suffix}`;
4077
4196
  }
4078
4197
  function formatSlackSocketStartRetryMessage(params) {
4079
- const maxAttempts = params.maxAttempts > 0 ? String(params.maxAttempts) : "∞";
4080
4198
  const reason = formatUnknownError(params.error, "Slack Socket Mode start failed without error detail");
4081
4199
  const sdkContext = params.sdkContext?.trim() ? `; last SDK log: ${params.sdkContext.trim()}` : "";
4082
- return `slack socket mode failed to start; retry ${params.attempt}/${maxAttempts} in ${Math.round(params.delayMs / 1e3)}s reason="${reason}${sdkContext}"`;
4200
+ return `slack socket mode failed to start; retry ${params.attempt}/∞ in ${Math.round(params.delayMs / 1e3)}s reason="${reason}${sdkContext}"`;
4083
4201
  }
4084
4202
  function parseApiAppIdFromAppToken(raw) {
4085
4203
  const token = raw?.trim();
@@ -4199,7 +4317,7 @@ async function monitorSlackProvider(opts = {}) {
4199
4317
  let authTestFailed = false;
4200
4318
  let authTestError;
4201
4319
  try {
4202
- const auth = await app.client.auth.test({ token: botToken });
4320
+ const auth = await app.client.auth.test();
4203
4321
  botUserId = auth.user_id ?? "";
4204
4322
  botId = auth.bot_id ?? "";
4205
4323
  teamId = auth.team_id ?? "";
@@ -4415,12 +4533,10 @@ async function monitorSlackProvider(opts = {}) {
4415
4533
  throw disconnect.error instanceof Error ? disconnect.error : new Error(formatUnknownError(disconnect.error));
4416
4534
  }
4417
4535
  reconnectAttempts += 1;
4418
- if (SLACK_SOCKET_RECONNECT_POLICY.maxAttempts > 0 && reconnectAttempts >= SLACK_SOCKET_RECONNECT_POLICY.maxAttempts) throw new Error(`Slack socket mode reconnect max attempts reached (${reconnectAttempts}/${SLACK_SOCKET_RECONNECT_POLICY.maxAttempts}) after ${disconnect.event}`);
4419
4536
  const delayMs = computeBackoff(SLACK_SOCKET_RECONNECT_POLICY, reconnectAttempts);
4420
4537
  runtime.log?.(warn(formatSlackSocketReconnectMessage({
4421
4538
  event: disconnect.event,
4422
4539
  attempt: reconnectAttempts,
4423
- maxAttempts: SLACK_SOCKET_RECONNECT_POLICY.maxAttempts,
4424
4540
  delayMs,
4425
4541
  error: disconnect.error
4426
4542
  })));
@@ -4436,11 +4552,9 @@ async function monitorSlackProvider(opts = {}) {
4436
4552
  throw err;
4437
4553
  }
4438
4554
  reconnectAttempts += 1;
4439
- if (SLACK_SOCKET_RECONNECT_POLICY.maxAttempts > 0 && reconnectAttempts >= SLACK_SOCKET_RECONNECT_POLICY.maxAttempts) throw err;
4440
4555
  const delayMs = computeBackoff(SLACK_SOCKET_RECONNECT_POLICY, reconnectAttempts);
4441
4556
  runtime.error?.(formatSlackSocketStartRetryMessage({
4442
4557
  attempt: reconnectAttempts,
4443
- maxAttempts: SLACK_SOCKET_RECONNECT_POLICY.maxAttempts,
4444
4558
  delayMs,
4445
4559
  error: err,
4446
4560
  sdkContext: socketModeLogger.getLastMessage()
@@ -1,5 +1,5 @@
1
- import { r as resolveSlackReplyBlocks, s as SLACK_TEXT_LIMIT } from "./thread-ts-Cffag8e2.js";
2
- import { o as markdownToSlackMrkdwnChunks, t as sendMessageSlack } from "./send-rekB-Xjp.js";
1
+ import { a as SLACK_TEXT_LIMIT, t as resolveSlackReplyBlocks } from "./reply-blocks-DSfujQlj.js";
2
+ import { o as markdownToSlackMrkdwnChunks, t as sendMessageSlack } from "./send-EpqsWCGd.js";
3
3
  import { createReplyReferencePlanner } from "openclaw/plugin-sdk/reply-reference";
4
4
  import { formatErrorMessage } from "openclaw/plugin-sdk/error-runtime";
5
5
  import { SILENT_REPLY_TOKEN, chunkMarkdownTextWithMode, isSilentReplyText } from "openclaw/plugin-sdk/reply-chunking";
@@ -1,7 +1,7 @@
1
1
  import { a as resolveSlackAccount, i as resolveDefaultSlackAccountId, n as listSlackAccountIds, o as resolveSlackAccountAllowFrom, r as mergeSlackAccountConfig } from "./accounts-f6Xcv9Vi.js";
2
- import { r as parseSlackTarget } from "./target-parsing-C7eeWg7M.js";
3
- import "./targets-nUqxHGgg.js";
4
- import { h as isSlackPluginAccountConfigured } from "./client-Cn2WwpcA.js";
2
+ import { r as parseSlackTarget } from "./target-parsing-3jYH8LfB.js";
3
+ import "./targets-Dll4NJgs.js";
4
+ import { h as isSlackPluginAccountConfigured } from "./client-DhaHONzg.js";
5
5
  import { normalizeAccountId } from "openclaw/plugin-sdk/account-resolution";
6
6
  import { normalizeLowercaseStringOrEmpty, normalizeOptionalLowercaseString, normalizeOptionalString, normalizeStringifiedOptionalString } from "openclaw/plugin-sdk/string-coerce-runtime";
7
7
  import { normalizeMessageChannel } from "openclaw/plugin-sdk/routing";
@@ -725,15 +725,4 @@ function resolveSlackReplyBlocks(payload) {
725
725
  return blocks.length > 0 ? blocks : void 0;
726
726
  }
727
727
  //#endregion
728
- //#region extensions/slack/src/thread-ts.ts
729
- const SLACK_THREAD_TS_PATTERN = /^\d+\.\d+$/;
730
- function normalizeSlackThreadTsCandidate(value) {
731
- if (typeof value !== "string") return;
732
- const normalized = normalizeOptionalString(value);
733
- return normalized && SLACK_THREAD_TS_PATTERN.test(normalized) ? normalized : void 0;
734
- }
735
- function resolveSlackThreadTsValue(params) {
736
- return normalizeSlackThreadTsCandidate(params.replyToId) ?? normalizeSlackThreadTsCandidate(params.threadId);
737
- }
738
- //#endregion
739
- export { resolveTurnSourceSlackOriginTarget as A, resolveSlackExecApprovalTarget as B, hasSlackPluginApprovers as C, resolveSessionSlackOriginTarget as D, normalizeSlackOriginTarget as E, isSlackApprovalAuthorizedSender as F, getSlackExecApprovalApprovers as I, isSlackExecApprovalAuthorizedSender as L, shouldHandleSlackPluginViaForwardingSession as M, slackTargetsMatch as N, resolveSlackApprovalKind as O, getSlackApprovalApprovers as P, isSlackExecApprovalClientEnabled as R, SLACK_REPLY_SELECT_ACTION_ID as S, normalizeSlackForwardTarget as T, shouldSuppressLocalSlackExecApprovalPrompt as V, buildSlackInteractiveBlocks as _, parseSlackBlocksInput as a, truncateSlackText as b, resolveSlackGroupRequireMention as c, normalizeAllowList as d, normalizeAllowListLower as f, resolveSlackUserAllowed as g, resolveSlackAllowListMatch as h, SLACK_MAX_BLOCKS as i, shouldHandleSlackNativeApprovalRequest as j, resolveSlackFallbackOriginTarget as k, resolveSlackGroupToolPolicy as l, normalizeSlackSlug as m, resolveSlackThreadTsValue as n, validateSlackBlocksArray as o, normalizeSlackAllowOwnerEntry as p, resolveSlackReplyBlocks as r, SLACK_TEXT_LIMIT as s, normalizeSlackThreadTsCandidate as t, allowListMatches as u, buildSlackPresentationBlocks as v, isSlackAnyNativeApprovalClientEnabled as w, SLACK_REPLY_BUTTON_ACTION_ID as x, resolveSlackInteractiveBlockOffsets as y, normalizeSlackApproverId as z };
728
+ export { shouldHandleSlackPluginViaForwardingSession as A, normalizeSlackForwardTarget as C, resolveSlackFallbackOriginTarget as D, resolveSlackApprovalKind as E, isSlackExecApprovalAuthorizedSender as F, isSlackExecApprovalClientEnabled as I, normalizeSlackApproverId as L, getSlackApprovalApprovers as M, isSlackApprovalAuthorizedSender as N, resolveTurnSourceSlackOriginTarget as O, getSlackExecApprovalApprovers as P, resolveSlackExecApprovalTarget as R, isSlackAnyNativeApprovalClientEnabled as S, resolveSessionSlackOriginTarget as T, resolveSlackInteractiveBlockOffsets as _, SLACK_TEXT_LIMIT as a, SLACK_REPLY_SELECT_ACTION_ID as b, allowListMatches as c, normalizeSlackAllowOwnerEntry as d, normalizeSlackSlug as f, buildSlackPresentationBlocks as g, buildSlackInteractiveBlocks as h, validateSlackBlocksArray as i, slackTargetsMatch as j, shouldHandleSlackNativeApprovalRequest as k, normalizeAllowList as l, resolveSlackUserAllowed as m, SLACK_MAX_BLOCKS as n, resolveSlackGroupRequireMention as o, resolveSlackAllowListMatch as p, parseSlackBlocksInput as r, resolveSlackGroupToolPolicy as s, resolveSlackReplyBlocks as t, normalizeAllowListLower as u, truncateSlackText as v, normalizeSlackOriginTarget as w, hasSlackPluginApprovers as x, SLACK_REPLY_BUTTON_ACTION_ID as y, shouldSuppressLocalSlackExecApprovalPrompt as z };
@@ -1,5 +1,5 @@
1
1
  import { t as __exportAll } from "./rolldown-runtime-D7D4PA-g.js";
2
- import { r as createSlackWebClient } from "./client-Cn2WwpcA.js";
2
+ import { r as createSlackWebClient } from "./client-DhaHONzg.js";
3
3
  import { n as resolveSlackAllowlistEntries, t as collectSlackCursorItems } from "./resolve-allowlist-common-CP8SH0Zf.js";
4
4
  import { normalizeLowercaseStringOrEmpty } from "openclaw/plugin-sdk/string-coerce-runtime";
5
5
  //#region extensions/slack/src/resolve-channels.ts
@@ -1,5 +1,5 @@
1
1
  import { t as __exportAll } from "./rolldown-runtime-D7D4PA-g.js";
2
- import { r as createSlackWebClient } from "./client-Cn2WwpcA.js";
2
+ import { r as createSlackWebClient } from "./client-DhaHONzg.js";
3
3
  import { n as resolveSlackAllowlistEntries, t as collectSlackCursorItems } from "./resolve-allowlist-common-CP8SH0Zf.js";
4
4
  import { normalizeLowercaseStringOrEmpty, normalizeOptionalString } from "openclaw/plugin-sdk/string-coerce-runtime";
5
5
  //#region extensions/slack/src/resolve-users.ts
@@ -1,5 +1,5 @@
1
- import "./target-parsing-C7eeWg7M.js";
2
- import "./client-Cn2WwpcA.js";
1
+ import "./target-parsing-3jYH8LfB.js";
2
+ import "./client-DhaHONzg.js";
3
3
  import "./config-api-DnT9ohtE.js";
4
4
  import "openclaw/plugin-sdk/account-id";
5
5
  import { createActionGate as createActionGate$1, imageResultFromFile, jsonResult, readPositiveIntegerParam, readReactionParams, readStringParam, withNormalizedTimestamp } from "openclaw/plugin-sdk/channel-actions";