@openclaw/slack 2026.7.2-beta.1 → 2026.7.2-beta.2
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/{action-runtime-p6M2ULpv.js → action-runtime-Cee2ih0s.js} +9 -6
- package/dist/action-runtime.runtime-DZfd7IFr.js +2 -0
- package/dist/{actions-DkTcWmpT.js → actions-BZiuSTIq.js} +4 -8
- package/dist/{actions.runtime-BSxpwgUc.js → actions.runtime-DoD0-gxw.js} +1 -1
- package/dist/api.js +9 -9
- package/dist/{approval-handler.runtime-UGbnz9OC.js → approval-handler.runtime-CUPtIM4k.js} +2 -2
- package/dist/{channel-B0_j6C6z.js → channel-DaIiGUOp.js} +20 -18
- package/dist/channel-config-api.js +1 -1
- package/dist/channel-plugin-api.js +1 -1
- package/dist/{channel-type-BpeTezY4.js → channel-type-Cfm6_6n1.js} +2 -2
- package/dist/{channel.setup-BQFut21T.js → channel.setup-C-mLz50O.js} +3 -3
- package/dist/{client-D2F6m8CP.js → client-WIPAS3Yr.js} +9 -1
- package/dist/{config-schema-DYI01PV2.js → config-schema-xPSnK2VK.js} +12 -0
- package/dist/{directory-live-DX7yFsM-.js → directory-live-D_yZhjgp.js} +1 -1
- package/dist/{group-policy-C-b2ZnSl.js → group-policy-85UWiriS.js} +28 -15
- package/dist/{monitor-BN_uuvrQ.js → monitor-CalGciTs.js} +3 -3
- package/dist/{outbound-adapter-ECl0go7d.js → outbound-adapter-BiLKcnyH.js} +2 -2
- package/dist/{pipeline.runtime-f0eJJoJL.js → pipeline.runtime-DofAvTtb.js} +176 -54
- package/dist/{policy-f8b0edSi.js → policy-BVs4LiSa.js} +7 -7
- package/dist/{probe-CfALk0l4.js → probe-CN0ssfLN.js} +2 -2
- package/dist/{provider-Ds-y-imP.js → provider-CmeoUiIM.js} +282 -47
- package/dist/{relay-source-B-6LFUdz.js → relay-source-DMmgtvg4.js} +1 -1
- package/dist/{replies-BMvf3ihj.js → replies-CJJCp6qz.js} +3 -3
- package/dist/{resolve-channels-DOMgNCWb.js → resolve-channels-Rfts6POK.js} +1 -1
- package/dist/{resolve-users-aL6-Ssee.js → resolve-users-y6wAxR8E.js} +1 -1
- package/dist/{runtime-CauEvswP.js → runtime-JSVZSWAj.js} +2 -2
- package/dist/{runtime-api-CVb6CQjX.js → runtime-api-BGDyOt1D.js} +1 -1
- package/dist/runtime-api.js +11 -11
- package/dist/runtime-setter-api.js +1 -1
- package/dist/{scopes-Dw8wbU0j.js → scopes-CuxNQZ6v.js} +2 -2
- package/dist/{send-NEfJ0GvM.js → send-DYp8ca-l.js} +4 -4
- package/dist/{send.runtime-BkKpitPu.js → send.runtime-CJLxAt26.js} +1 -1
- package/dist/{setup-core-fGd6Gquy.js → setup-core-CkwVLzFO.js} +15 -21
- package/dist/setup-plugin-api.js +1 -1
- package/dist/{setup-surface-BN2WeG5c.js → setup-surface-oSd3NX9J.js} +4 -4
- package/dist/{shared-BLnB9R1T.js → shared-D9yz5Otg.js} +12 -35
- package/dist/{slash-dispatch.runtime-C0Otuf_T.js → slash-dispatch.runtime-CSja9VuD.js} +1 -1
- package/npm-shrinkwrap.json +3 -3
- package/openclaw.plugin.json +68 -0
- package/package.json +5 -7
- package/dist/action-runtime.runtime-DQstDkHG.js +0 -2
- package/dist/configured-state.js +0 -11
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { a as resolveSlackChannelId, i as parseSlackTarget } from "./target-parsing-N6lHogYZ.js";
|
|
2
2
|
import { t as slackContextTargetsMatch } from "./targets-KmjP2E8s.js";
|
|
3
|
-
import {
|
|
4
|
-
import { a as readPositiveIntegerParam, c as withNormalizedTimestamp, n as imageResultFromFile, o as readReactionParams, r as jsonResult, s as readStringParam, t as createActionGate } from "./runtime-api-
|
|
5
|
-
import { n as resolveSlackChannelConfig, t as isSlackChannelAllowedByPolicy } from "./policy-
|
|
3
|
+
import { Z as parseSlackBlocksInput, w as hasSlackNativeDataBlock } from "./group-policy-85UWiriS.js";
|
|
4
|
+
import { a as readPositiveIntegerParam, c as withNormalizedTimestamp, n as imageResultFromFile, o as readReactionParams, r as jsonResult, s as readStringParam, t as createActionGate } from "./runtime-api-BGDyOt1D.js";
|
|
5
|
+
import { n as resolveSlackChannelConfig, t as isSlackChannelAllowedByPolicy } from "./policy-BVs4LiSa.js";
|
|
6
6
|
import { normalizeAccountId } from "openclaw/plugin-sdk/account-resolution";
|
|
7
7
|
import { normalizeOptionalLowercaseString } from "openclaw/plugin-sdk/string-coerce-runtime";
|
|
8
8
|
import { createLazyRuntimeModule } from "openclaw/plugin-sdk/lazy-runtime";
|
|
@@ -24,9 +24,9 @@ const pinActions = /* @__PURE__ */ new Set([
|
|
|
24
24
|
"unpinMessage",
|
|
25
25
|
"listPins"
|
|
26
26
|
]);
|
|
27
|
-
const loadSlackActionsRuntime = createLazyRuntimeModule(() => import("./actions.runtime-
|
|
27
|
+
const loadSlackActionsRuntime = createLazyRuntimeModule(() => import("./actions.runtime-DoD0-gxw.js"));
|
|
28
28
|
const loadSlackAccountsRuntime = createLazyRuntimeModule(() => import("./accounts.runtime-KvftRRek.js"));
|
|
29
|
-
const loadSlackChannelTypeRuntime = createLazyRuntimeModule(() => import("./channel-type-
|
|
29
|
+
const loadSlackChannelTypeRuntime = createLazyRuntimeModule(() => import("./channel-type-Cfm6_6n1.js").then((n) => n.t));
|
|
30
30
|
function createLazySlackAction(key) {
|
|
31
31
|
return (async (...args) => {
|
|
32
32
|
const action = (await loadSlackActionsRuntime())[key];
|
|
@@ -447,9 +447,12 @@ async function handleSlackAction(params, cfg, context) {
|
|
|
447
447
|
threadId: threadId ?? void 0,
|
|
448
448
|
messageId: messageId ?? void 0
|
|
449
449
|
});
|
|
450
|
+
const messages = result.messages.map((message) => withNormalizedTimestamp(message, message.ts));
|
|
450
451
|
return jsonResult({
|
|
451
452
|
ok: true,
|
|
452
|
-
|
|
453
|
+
channelId,
|
|
454
|
+
...threadId ? { threadId } : {},
|
|
455
|
+
messages,
|
|
453
456
|
hasMore: result.hasMore
|
|
454
457
|
});
|
|
455
458
|
}
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { t as __exportAll } from "./rolldown-runtime-D7D4PA-g.js";
|
|
2
2
|
import { a as resolveSlackAccount, p as resolveSlackBotToken } from "./accounts-BOJJiHSr.js";
|
|
3
|
-
import { A as
|
|
4
|
-
import {
|
|
5
|
-
import { l as buildSlackNativeDataDeliveryPlan, r as sendMessageSlack } from "./send-
|
|
3
|
+
import { A as buildSlackBlocksFallbackText, B as truncateSlackText, E as stripSlackNativeDataBlocks, M as renderSlackBlockFallbackText, P as SLACK_EDIT_TEXT_LIMIT, Q as validateSlackBlocksArray, T as isSlackInvalidBlocksError, b as appendSlackNativeDataFallbackText, j as buildSlackCompleteBlocksFallbackText, q as escapeSlackMrkdwn, w as hasSlackNativeDataBlock, x as appendSlackNativeDataPlainTextFallback } from "./group-policy-85UWiriS.js";
|
|
4
|
+
import { c as getSlackWriteClient, n as createSlackLookupClient } from "./client-WIPAS3Yr.js";
|
|
5
|
+
import { l as buildSlackNativeDataDeliveryPlan, r as sendMessageSlack } from "./send-DYp8ca-l.js";
|
|
6
6
|
import { normalizeLowercaseStringOrEmpty, normalizeOptionalLowercaseString, normalizeOptionalString } from "openclaw/plugin-sdk/string-coerce-runtime";
|
|
7
7
|
import { logVerbose, logVerbose as logVerbose$1 } from "openclaw/plugin-sdk/runtime-env";
|
|
8
8
|
import { pruneMapToMaxSize } from "openclaw/plugin-sdk/collection-runtime";
|
|
@@ -40,9 +40,6 @@ function formatSlackFileReferenceList(files) {
|
|
|
40
40
|
return files.map((file) => formatSlackFileReference(file)).join(", ");
|
|
41
41
|
}
|
|
42
42
|
//#endregion
|
|
43
|
-
//#region extensions/slack/src/monitor/media-types.ts
|
|
44
|
-
const MAX_SLACK_MEDIA_FILES = 8;
|
|
45
|
-
//#endregion
|
|
46
43
|
//#region extensions/slack/src/monitor/block-text.ts
|
|
47
44
|
function readSlackBlockType(block) {
|
|
48
45
|
return block && typeof block === "object" && !Array.isArray(block) ? block.type : void 0;
|
|
@@ -227,7 +224,6 @@ async function resolveSlackThreadHistory(params) {
|
|
|
227
224
|
//#endregion
|
|
228
225
|
//#region extensions/slack/src/monitor/media.ts
|
|
229
226
|
var media_exports = /* @__PURE__ */ __exportAll({
|
|
230
|
-
MAX_SLACK_MEDIA_FILES: () => 8,
|
|
231
227
|
SLACK_MEDIA_READ_IDLE_TIMEOUT_MS: () => SLACK_MEDIA_READ_IDLE_TIMEOUT_MS,
|
|
232
228
|
resetSlackThreadStarterCacheForTest: () => resetSlackThreadStarterCacheForTest,
|
|
233
229
|
resolveSlackAttachmentContent: () => resolveSlackAttachmentContent,
|
|
@@ -901,4 +897,4 @@ async function downloadSlackFile(fileId, opts) {
|
|
|
901
897
|
}))?.[0] ?? null;
|
|
902
898
|
}
|
|
903
899
|
//#endregion
|
|
904
|
-
export { buildSlackEditTextPayload as
|
|
900
|
+
export { buildSlackEditTextPayload as S, resolveSlackThreadHistory as _, listSlackEmojis as a, resolveSlackBlocksText as b, pinSlackMessage as c, removeOwnSlackReactions as d, removeSlackReaction as f, media_exports as g, unpinSlackMessage as h, getSlackMemberInfo as i, reactSlackMessage as l, sendSlackMessage as m, downloadSlackFile as n, listSlackPins as o, resolveSlackConversationName as p, editSlackMessage as r, listSlackReactions as s, deleteSlackMessage as t, readSlackMessages as u, resolveSlackThreadStarter as v, formatSlackFileReference as x, chooseSlackPrimaryText as y };
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { a as listSlackEmojis, c as pinSlackMessage, d as removeOwnSlackReactions, f as removeSlackReaction, h as unpinSlackMessage, i as getSlackMemberInfo, l as reactSlackMessage, m as sendSlackMessage, n as downloadSlackFile, o as listSlackPins, p as resolveSlackConversationName, r as editSlackMessage, s as listSlackReactions, t as deleteSlackMessage, u as readSlackMessages } from "./actions-
|
|
1
|
+
import { a as listSlackEmojis, c as pinSlackMessage, d as removeOwnSlackReactions, f as removeSlackReaction, h as unpinSlackMessage, i as getSlackMemberInfo, l as reactSlackMessage, m as sendSlackMessage, n as downloadSlackFile, o as listSlackPins, p as resolveSlackConversationName, r as editSlackMessage, s as listSlackReactions, t as deleteSlackMessage, u as readSlackMessages } from "./actions-BZiuSTIq.js";
|
|
2
2
|
export { deleteSlackMessage, downloadSlackFile, editSlackMessage, getSlackMemberInfo, listSlackEmojis, listSlackPins, listSlackReactions, pinSlackMessage, reactSlackMessage, readSlackMessages, removeOwnSlackReactions, removeSlackReaction, resolveSlackConversationName, sendSlackMessage, unpinSlackMessage };
|
package/dist/api.js
CHANGED
|
@@ -3,17 +3,17 @@ import { a as resolveSlackAccount, i as resolveDefaultSlackAccountId, n as listS
|
|
|
3
3
|
import { t as inspectSlackAccount } from "./account-inspect-Di7ditqZ.js";
|
|
4
4
|
import { a as resolveSlackChannelId, i as parseSlackTarget, n as looksLikeSlackTargetId, r as normalizeSlackMessagingTarget } from "./target-parsing-N6lHogYZ.js";
|
|
5
5
|
import "./targets-KmjP2E8s.js";
|
|
6
|
-
import { n as buildSlackThreadingToolContext, r as resolveSlackAutoThreadId, t as slackPlugin } from "./channel-
|
|
7
|
-
import {
|
|
6
|
+
import { n as buildSlackThreadingToolContext, r as resolveSlackAutoThreadId, t as slackPlugin } from "./channel-DaIiGUOp.js";
|
|
7
|
+
import { L as buildSlackInteractiveBlocks, Q as validateSlackBlocksArray, R as buildSlackPresentationBlocks, X as SLACK_MAX_BLOCKS, Z as parseSlackBlocksInput, c as normalizeAllowListLower, d as resolveSlackAllowListMatch, f as resolveSlackUserAllowed, l as normalizeSlackAllowOwnerEntry, n as resolveSlackGroupRequireMention, o as allowListMatches, r as resolveSlackGroupToolPolicy, s as normalizeAllowList, u as normalizeSlackSlug } from "./group-policy-85UWiriS.js";
|
|
8
8
|
import { n as extractSlackToolSend, r as listSlackMessageActions } from "./message-tool-api-CA9jZrCY.js";
|
|
9
9
|
import { n as isSlackInteractiveRepliesEnabled, r as parseSlackOptionsLine, t as compileSlackInteractiveReplies } from "./interactive-replies-BilWUdcI.js";
|
|
10
|
-
import { a as
|
|
11
|
-
import { n as resetSlackChannelTypeCacheForTest, r as resolveSlackChannelType } from "./channel-type-
|
|
12
|
-
import { t as slackSetupPlugin } from "./channel.setup-
|
|
13
|
-
import { a as listSlackEmojis, c as pinSlackMessage, d as removeOwnSlackReactions, f as removeSlackReaction, h as unpinSlackMessage, i as getSlackMemberInfo, l as reactSlackMessage, m as sendSlackMessage, n as downloadSlackFile, o as listSlackPins, r as editSlackMessage, s as listSlackReactions, t as deleteSlackMessage, u as readSlackMessages } from "./actions-
|
|
14
|
-
import { a as clearSlackThreadParticipationCache, c as recordSlackThreadParticipation, o as hasSlackThreadParticipation } from "./send-
|
|
10
|
+
import { a as createSlackWebClient, c as getSlackWriteClient, d as resolveSlackWebClientOptions, f as resolveSlackWriteClientOptions, i as createSlackTokenCacheKey, l as SLACK_DEFAULT_RETRY_OPTIONS, o as createSlackWriteClient, t as clearSlackWriteClientCacheForTest, u as SLACK_WRITE_RETRY_OPTIONS } from "./client-WIPAS3Yr.js";
|
|
11
|
+
import { n as resetSlackChannelTypeCacheForTest, r as resolveSlackChannelType } from "./channel-type-Cfm6_6n1.js";
|
|
12
|
+
import { t as slackSetupPlugin } from "./channel.setup-C-mLz50O.js";
|
|
13
|
+
import { a as listSlackEmojis, c as pinSlackMessage, d as removeOwnSlackReactions, f as removeSlackReaction, h as unpinSlackMessage, i as getSlackMemberInfo, l as reactSlackMessage, m as sendSlackMessage, n as downloadSlackFile, o as listSlackPins, r as editSlackMessage, s as listSlackReactions, t as deleteSlackMessage, u as readSlackMessages } from "./actions-BZiuSTIq.js";
|
|
14
|
+
import { a as clearSlackThreadParticipationCache, c as recordSlackThreadParticipation, o as hasSlackThreadParticipation } from "./send-DYp8ca-l.js";
|
|
15
15
|
import { n as listSlackDirectoryGroupsFromConfig, r as listSlackDirectoryPeersFromConfig } from "./directory-config-DRkFujwG.js";
|
|
16
|
-
import { t as probeSlack } from "./probe-
|
|
16
|
+
import { t as probeSlack } from "./probe-CN0ssfLN.js";
|
|
17
17
|
import { t as collectSlackSecurityAuditFindings } from "./security-audit-CikQhBUY.js";
|
|
18
|
-
import { n as resolveSlackRuntimeGroupPolicy } from "./provider-
|
|
18
|
+
import { n as resolveSlackRuntimeGroupPolicy } from "./provider-CmeoUiIM.js";
|
|
19
19
|
export { SLACK_DEFAULT_RETRY_OPTIONS, SLACK_MAX_BLOCKS, SLACK_WRITE_RETRY_OPTIONS, resetSlackChannelTypeCacheForTest as __resetSlackChannelTypeCacheForTest, resetSlackChannelTypeCacheForTest, allowListMatches, buildSlackInteractiveBlocks, buildSlackPresentationBlocks, buildSlackThreadingToolContext, clearSlackThreadParticipationCache, clearSlackWriteClientCacheForTest, collectSlackSecurityAuditFindings, compileSlackInteractiveReplies, createSlackTokenCacheKey, createSlackWebClient, createSlackWriteClient, deleteSlackMessage, downloadSlackFile, editSlackMessage, extractSlackToolSend, getSlackMemberInfo, getSlackWriteClient, handleSlackHttpRequest, hasSlackThreadParticipation, inspectSlackAccount, isSlackInteractiveRepliesEnabled, listEnabledSlackAccounts, listSlackAccountIds, listSlackDirectoryGroupsFromConfig, listSlackDirectoryPeersFromConfig, listSlackEmojis, listSlackMessageActions, listSlackPins, listSlackReactions, looksLikeSlackTargetId, mergeSlackAccountConfig, normalizeAllowList, normalizeAllowListLower, normalizeSlackAllowOwnerEntry, normalizeSlackMessagingTarget, normalizeSlackSlug, normalizeSlackWebhookPath, parseSlackBlocksInput, parseSlackOptionsLine, parseSlackTarget, pinSlackMessage, probeSlack, reactSlackMessage, readSlackMessages, recordSlackThreadParticipation, registerSlackHttpHandler, removeOwnSlackReactions, removeSlackReaction, resolveDefaultSlackAccountId, resolveSlackAccount, resolveSlackAllowListMatch, resolveSlackAutoThreadId, resolveSlackChannelId, resolveSlackChannelType, resolveSlackGroupRequireMention, resolveSlackGroupToolPolicy, resolveSlackReplyToMode, resolveSlackRuntimeGroupPolicy, resolveSlackUserAllowed, resolveSlackWebClientOptions, resolveSlackWriteClientOptions, sendSlackMessage, slackPlugin, slackSetupPlugin, unpinSlackMessage, validateSlackBlocksArray };
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import { r as sendMessageSlack } from "./send-
|
|
1
|
+
import { B as truncateSlackText, et as isSlackAnyNativeApprovalClientEnabled, g as resolveSlackReplyBlocks, mt as normalizeSlackApproverId, ot as shouldHandleSlackNativeApprovalRequest } from "./group-policy-85UWiriS.js";
|
|
2
|
+
import { r as sendMessageSlack } from "./send-DYp8ca-l.js";
|
|
3
3
|
import { normalizeOptionalString } from "openclaw/plugin-sdk/string-coerce-runtime";
|
|
4
4
|
import { buildChannelApprovalNativeTargetKey } from "openclaw/plugin-sdk/approval-native-runtime";
|
|
5
5
|
import { buildApprovalPresentationFromActionDescriptors } from "openclaw/plugin-sdk/approval-reply-runtime";
|
|
@@ -1,16 +1,16 @@
|
|
|
1
1
|
import { a as resolveSlackAccount, i as resolveDefaultSlackAccountId, l as resolveSlackOperationToken, n as listSlackAccountIds, o as resolveSlackAccountAllowFrom, r as mergeSlackAccountConfig, u as resolveSlackReplyToMode } from "./accounts-BOJJiHSr.js";
|
|
2
2
|
import { a as resolveSlackChannelId, i as parseSlackTarget, n as looksLikeSlackTargetId, r as normalizeSlackMessagingTarget, t as canonicalizeSlackApiTargetId } from "./target-parsing-N6lHogYZ.js";
|
|
3
3
|
import { t as slackContextTargetsMatch } from "./targets-KmjP2E8s.js";
|
|
4
|
-
import { $ as
|
|
4
|
+
import { $ as hasSlackPluginApprovers, I as SLACK_TEXT_LIMIT, K as renderSlackMessagePresentationFallbackText, P as SLACK_EDIT_TEXT_LIMIT, R as buildSlackPresentationBlocks, Y as SLACK_PRESENTATION_CAPABILITIES, _ as resolveSlackReplyDeliveryMessages, a as assertSlackDirectSendAllowed, at as resolveTurnSourceSlackOriginTarget, ct as slackTargetsMatch, dt as getSlackExecApprovalApprovers, et as isSlackAnyNativeApprovalClientEnabled, ft as isSlackExecApprovalAuthorizedSender, g as resolveSlackReplyBlocks, gt as shouldSuppressLocalSlackExecApprovalPrompt, h as resolveSlackReplyBlockResolution, ht as resolveSlackExecApprovalTarget, i as formatSlackError, it as resolveSlackFallbackOriginTarget, lt as getSlackApprovalApprovers, n as resolveSlackGroupRequireMention, nt as normalizeSlackOriginTarget, ot as shouldHandleSlackNativeApprovalRequest, pt as isSlackExecApprovalClientEnabled, r as resolveSlackGroupToolPolicy, rt as resolveSessionSlackOriginTarget, st as shouldHandleSlackPluginViaForwardingSession, tt as normalizeSlackForwardTarget, ut as isSlackApprovalAuthorizedSender, z as canRenderSlackPresentation } from "./group-policy-85UWiriS.js";
|
|
5
5
|
import { t as isSlackPluginAccountConfigured } from "./account-configured-DzC407uv.js";
|
|
6
6
|
import { n as resolveSlackThreadTsValue, t as normalizeSlackThreadTsCandidate } from "./thread-ts-DUGhaYKq.js";
|
|
7
7
|
import { n as extractSlackToolSend, t as describeSlackMessageTool } from "./message-tool-api-CA9jZrCY.js";
|
|
8
8
|
import { n as isSlackInteractiveRepliesEnabled, t as compileSlackInteractiveReplies } from "./interactive-replies-BilWUdcI.js";
|
|
9
|
-
import {
|
|
10
|
-
import { i as resolveSlackConversationInfo, r as resolveSlackChannelType } from "./channel-type-
|
|
11
|
-
import { t as getOptionalSlackRuntime } from "./runtime-
|
|
12
|
-
import { n as slackConfigAdapter, r as slackSecurityAdapter, t as createSlackPluginBase } from "./shared-
|
|
13
|
-
import { i as SLACK_CHANNEL, n as createSlackSetupWizardProxy, r as slackSetupAdapter } from "./setup-core-
|
|
9
|
+
import { _ as resolveConfiguredFromRequiredCredentialStatuses, a as createSlackWebClient, g as projectCredentialSnapshotFields, m as PAIRING_APPROVED_MESSAGE, p as DEFAULT_ACCOUNT_ID$1 } from "./client-WIPAS3Yr.js";
|
|
10
|
+
import { i as resolveSlackConversationInfo, r as resolveSlackChannelType } from "./channel-type-Cfm6_6n1.js";
|
|
11
|
+
import { t as getOptionalSlackRuntime } from "./runtime-JSVZSWAj.js";
|
|
12
|
+
import { n as slackConfigAdapter, r as slackSecurityAdapter, t as createSlackPluginBase } from "./shared-D9yz5Otg.js";
|
|
13
|
+
import { i as SLACK_CHANNEL, n as createSlackSetupWizardProxy, r as slackSetupAdapter } from "./setup-core-CkwVLzFO.js";
|
|
14
14
|
import { normalizeAccountId } from "openclaw/plugin-sdk/account-resolution";
|
|
15
15
|
import { normalizeLowercaseStringOrEmpty, normalizeOptionalLowercaseString, normalizeOptionalString } from "openclaw/plugin-sdk/string-coerce-runtime";
|
|
16
16
|
import { adaptScopedAccountAccessor } from "openclaw/plugin-sdk/channel-config-helpers";
|
|
@@ -138,7 +138,7 @@ const baseSlackApprovalCapability = createApproverRestrictedNativeApprovalCapabi
|
|
|
138
138
|
approvalKind,
|
|
139
139
|
request
|
|
140
140
|
}),
|
|
141
|
-
load: async () => (await import("./approval-handler.runtime-
|
|
141
|
+
load: async () => (await import("./approval-handler.runtime-CUPtIM4k.js")).slackApprovalNativeRuntime
|
|
142
142
|
})
|
|
143
143
|
});
|
|
144
144
|
const baseSlackNativeAdapter = baseSlackApprovalCapability.native;
|
|
@@ -401,7 +401,7 @@ const SLACK_TOOL_DELIVERY_ACTIONS = /* @__PURE__ */ new Set([
|
|
|
401
401
|
"unpinMessage",
|
|
402
402
|
"uploadFile"
|
|
403
403
|
]);
|
|
404
|
-
const loadSlackActionRuntime$1 = createLazyRuntimeModule(() => import("./action-runtime.runtime-
|
|
404
|
+
const loadSlackActionRuntime$1 = createLazyRuntimeModule(() => import("./action-runtime.runtime-DZfd7IFr.js"));
|
|
405
405
|
function resolveSlackActionContext(params) {
|
|
406
406
|
if (!params.toolContext && !params.mediaLocalRoots && !params.mediaReadFile && !params.conversationReadOrigin && !params.requesterAccountId && !params.requesterSenderId) return;
|
|
407
407
|
return {
|
|
@@ -471,9 +471,9 @@ const EXTENSION_SHARED_MODULE_ID = "openclaw/plugin-sdk/extension-shared";
|
|
|
471
471
|
const TARGET_RESOLVER_RUNTIME_MODULE_ID = "openclaw/plugin-sdk/target-resolver-runtime";
|
|
472
472
|
const loadExtensionSharedSdk = createLazyRuntimeModule(() => import(EXTENSION_SHARED_MODULE_ID));
|
|
473
473
|
const loadTargetResolverRuntimeSdk = createLazyRuntimeModule(() => import(TARGET_RESOLVER_RUNTIME_MODULE_ID));
|
|
474
|
-
const loadSlackSetupSurfaceModule = createLazyRuntimeModule(() => import("./setup-surface-
|
|
475
|
-
const loadSlackScopesModule = createLazyRuntimeModule(() => import("./scopes-
|
|
476
|
-
const loadSlackOutboundAdapterModule = createLazyRuntimeModule(() => import("./outbound-adapter-
|
|
474
|
+
const loadSlackSetupSurfaceModule = createLazyRuntimeModule(() => import("./setup-surface-oSd3NX9J.js"));
|
|
475
|
+
const loadSlackScopesModule = createLazyRuntimeModule(() => import("./scopes-CuxNQZ6v.js"));
|
|
476
|
+
const loadSlackOutboundAdapterModule = createLazyRuntimeModule(() => import("./outbound-adapter-BiLKcnyH.js"));
|
|
477
477
|
async function resolveSlackHandleAction() {
|
|
478
478
|
return getOptionalSlackRuntime()?.channel?.slack?.handleSlackAction ?? (await loadSlackActionRuntime()).handleSlackAction;
|
|
479
479
|
}
|
|
@@ -481,13 +481,13 @@ function shouldTreatSlackDeliveredTextAsVisible(params) {
|
|
|
481
481
|
return params.kind === "block" && typeof params.text === "string" && params.text.trim().length > 0;
|
|
482
482
|
}
|
|
483
483
|
const loadSlackDirectoryConfigModule = createLazyRuntimeModule(() => import("./directory-config-DRkFujwG.js").then((n) => n.t));
|
|
484
|
-
const loadSlackResolveChannelsModule = createLazyRuntimeModule(() => import("./resolve-channels-
|
|
485
|
-
const loadSlackResolveUsersModule = createLazyRuntimeModule(() => import("./resolve-users-
|
|
486
|
-
const loadSlackActionRuntime = createLazyRuntimeModule(() => import("./action-runtime.runtime-
|
|
487
|
-
const loadSlackSendRuntime = createLazyRuntimeModule(() => import("./send.runtime-
|
|
488
|
-
const loadSlackProbeModule = createLazyRuntimeModule(() => import("./probe-
|
|
489
|
-
const loadSlackMonitorModule = createLazyRuntimeModule(() => import("./monitor-
|
|
490
|
-
const loadSlackDirectoryLiveModule = createLazyRuntimeModule(() => import("./directory-live-
|
|
484
|
+
const loadSlackResolveChannelsModule = createLazyRuntimeModule(() => import("./resolve-channels-Rfts6POK.js").then((n) => n.n));
|
|
485
|
+
const loadSlackResolveUsersModule = createLazyRuntimeModule(() => import("./resolve-users-y6wAxR8E.js").then((n) => n.n));
|
|
486
|
+
const loadSlackActionRuntime = createLazyRuntimeModule(() => import("./action-runtime.runtime-DZfd7IFr.js"));
|
|
487
|
+
const loadSlackSendRuntime = createLazyRuntimeModule(() => import("./send.runtime-CJLxAt26.js"));
|
|
488
|
+
const loadSlackProbeModule = createLazyRuntimeModule(() => import("./probe-CN0ssfLN.js").then((n) => n.n));
|
|
489
|
+
const loadSlackMonitorModule = createLazyRuntimeModule(() => import("./monitor-CalGciTs.js").then((n) => n.t));
|
|
490
|
+
const loadSlackDirectoryLiveModule = createLazyRuntimeModule(() => import("./directory-live-D_yZhjgp.js").then((n) => n.t));
|
|
491
491
|
async function resolveSlackSendContext(params) {
|
|
492
492
|
const account = resolveSlackAccount({
|
|
493
493
|
cfg: params.cfg,
|
|
@@ -842,6 +842,8 @@ const slackPlugin = createChatChannelPlugin({
|
|
|
842
842
|
} },
|
|
843
843
|
messaging: {
|
|
844
844
|
targetPrefixes: ["slack"],
|
|
845
|
+
directTargetStyle: "user-prefixed",
|
|
846
|
+
targetIdComparison: "lowercase",
|
|
845
847
|
normalizeTarget: normalizeSlackMessagingTarget,
|
|
846
848
|
resolveDeliveryTarget: ({ conversationId, parentConversationId }) => {
|
|
847
849
|
const parent = parentConversationId?.trim();
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { t as SlackChannelConfigSchema } from "./config-schema-
|
|
1
|
+
import { t as SlackChannelConfigSchema } from "./config-schema-xPSnK2VK.js";
|
|
2
2
|
export { SlackChannelConfigSchema };
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { t as slackPlugin } from "./channel-
|
|
1
|
+
import { t as slackPlugin } from "./channel-DaIiGUOp.js";
|
|
2
2
|
export { slackPlugin };
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { t as __exportAll } from "./rolldown-runtime-D7D4PA-g.js";
|
|
2
2
|
import { a as resolveSlackAccount, l as resolveSlackOperationToken } from "./accounts-BOJJiHSr.js";
|
|
3
|
-
import {
|
|
4
|
-
import {
|
|
3
|
+
import { c as normalizeAllowListLower } from "./group-policy-85UWiriS.js";
|
|
4
|
+
import { a as createSlackWebClient } from "./client-WIPAS3Yr.js";
|
|
5
5
|
import { normalizeLowercaseStringOrEmpty, normalizeOptionalString } from "openclaw/plugin-sdk/string-coerce-runtime";
|
|
6
6
|
import { createHash } from "node:crypto";
|
|
7
7
|
import { pruneMapToMaxSize } from "openclaw/plugin-sdk/collection-runtime";
|
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
import { a as resolveSlackAccount, c as resolveSlackConfigAccessorAccount, i as resolveDefaultSlackAccountId, n as listSlackAccountIds } from "./accounts-BOJJiHSr.js";
|
|
2
|
-
import { a as describeSlackSetupAccount, i as SLACK_CHANNEL, n as createSlackSetupWizardProxy, o as isSlackSetupAccountConfigured, r as slackSetupAdapter } from "./setup-core-
|
|
3
|
-
import { t as SlackChannelConfigSchema } from "./config-schema-
|
|
2
|
+
import { a as describeSlackSetupAccount, i as SLACK_CHANNEL, n as createSlackSetupWizardProxy, o as isSlackSetupAccountConfigured, r as slackSetupAdapter } from "./setup-core-CkwVLzFO.js";
|
|
3
|
+
import { t as SlackChannelConfigSchema } from "./config-schema-xPSnK2VK.js";
|
|
4
4
|
import { adaptScopedAccountAccessor, createScopedChannelConfigAdapter } from "openclaw/plugin-sdk/channel-config-helpers";
|
|
5
5
|
import { formatAllowFromLowercase } from "openclaw/plugin-sdk/allow-from";
|
|
6
6
|
//#region extensions/slack/src/channel.setup.ts
|
|
7
|
-
const slackSetupWizard = createSlackSetupWizardProxy(async () => ({ slackSetupWizard: (await import("./setup-surface-
|
|
7
|
+
const slackSetupWizard = createSlackSetupWizardProxy(async () => ({ slackSetupWizard: (await import("./setup-surface-oSd3NX9J.js")).slackSetupWizard }));
|
|
8
8
|
const slackSetupConfigAdapter = createScopedChannelConfigAdapter({
|
|
9
9
|
sectionKey: SLACK_CHANNEL,
|
|
10
10
|
listAccountIds: listSlackAccountIds,
|
|
@@ -93,6 +93,14 @@ let slackListenerUploadCompletionClientCache = /* @__PURE__ */ new WeakMap();
|
|
|
93
93
|
function createSlackWebClient(token, options = {}) {
|
|
94
94
|
return new WebClient(token, resolveSlackWebClientOptions(options));
|
|
95
95
|
}
|
|
96
|
+
function createSlackStartupAuthClient(token, options = {}) {
|
|
97
|
+
return createSlackWebClient(token, {
|
|
98
|
+
...options,
|
|
99
|
+
rejectRateLimitedCalls: true,
|
|
100
|
+
retryConfig: { retries: 0 },
|
|
101
|
+
timeout: 1e4
|
|
102
|
+
});
|
|
103
|
+
}
|
|
96
104
|
function createSlackLookupClient(token, options = {}) {
|
|
97
105
|
return new WebClient(token, resolveSlackLookupClientOptions(options));
|
|
98
106
|
}
|
|
@@ -149,4 +157,4 @@ function clearSlackWriteClientCacheForTest() {
|
|
|
149
157
|
slackListenerUploadCompletionClientCache = /* @__PURE__ */ new WeakMap();
|
|
150
158
|
}
|
|
151
159
|
//#endregion
|
|
152
|
-
export {
|
|
160
|
+
export { resolveConfiguredFromRequiredCredentialStatuses as _, createSlackWebClient as a, getSlackWriteClient as c, resolveSlackWebClientOptions as d, resolveSlackWriteClientOptions as f, projectCredentialSnapshotFields as g, getChatChannelMeta as h, createSlackTokenCacheKey as i, SLACK_DEFAULT_RETRY_OPTIONS as l, PAIRING_APPROVED_MESSAGE as m, createSlackLookupClient as n, createSlackWriteClient as o, DEFAULT_ACCOUNT_ID$1 as p, createSlackStartupAuthClient as r, getSlackListenerUploadCompletionClient as s, clearSlackWriteClientCacheForTest as t, SLACK_WRITE_RETRY_OPTIONS as u };
|
|
@@ -105,6 +105,18 @@ const SlackChannelConfigSchema = buildChannelConfigSchema(SlackConfigSchema, { u
|
|
|
105
105
|
label: "Slack Exec Approvals",
|
|
106
106
|
help: "Slack-native exec approval routing and approver authorization. When unset, OpenClaw auto-enables DM-first native approvals if approvers can be resolved for this workspace account."
|
|
107
107
|
},
|
|
108
|
+
presenceEvents: {
|
|
109
|
+
label: "Slack Presence Events",
|
|
110
|
+
help: "Poll observed human participants and wake the routed agent on away-to-active transitions. Default: \"off\"."
|
|
111
|
+
},
|
|
112
|
+
"presenceEvents.mode": {
|
|
113
|
+
label: "Slack Presence Event Mode",
|
|
114
|
+
help: "\"off\" disables polling; \"auto\" covers DMs, MPIMs, and recent threads with up to 8 observed people; \"on\" also covers larger threads and top-level channels."
|
|
115
|
+
},
|
|
116
|
+
"channels.*.presenceEvents.mode": {
|
|
117
|
+
label: "Slack Channel Presence Event Mode",
|
|
118
|
+
help: "Override presence events for one Slack channel. Use \"on\" to include large threads or top-level channel sessions."
|
|
119
|
+
},
|
|
108
120
|
"execApprovals.enabled": {
|
|
109
121
|
label: "Slack Exec Approvals Enabled",
|
|
110
122
|
help: "Controls Slack native exec approvals for this account: unset or \"auto\" enables DM-first native approvals when approvers can be resolved, true forces native approvals on, and false disables them."
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { t as __exportAll } from "./rolldown-runtime-D7D4PA-g.js";
|
|
2
2
|
import { a as resolveSlackAccount } from "./accounts-BOJJiHSr.js";
|
|
3
|
-
import { n as createSlackLookupClient } from "./client-
|
|
3
|
+
import { n as createSlackLookupClient } from "./client-WIPAS3Yr.js";
|
|
4
4
|
import { normalizeLowercaseStringOrEmpty, normalizeOptionalLowercaseString, normalizeOptionalString } from "openclaw/plugin-sdk/string-coerce-runtime";
|
|
5
5
|
//#region extensions/slack/src/directory-live.ts
|
|
6
6
|
var directory_live_exports = /* @__PURE__ */ __exportAll({
|
|
@@ -2300,28 +2300,41 @@ function formatSlackError(error, fallback = NO_ERROR_DETAIL) {
|
|
|
2300
2300
|
}
|
|
2301
2301
|
//#endregion
|
|
2302
2302
|
//#region extensions/slack/src/group-policy.ts
|
|
2303
|
-
function
|
|
2304
|
-
const
|
|
2305
|
-
const tree = { scopes:
|
|
2306
|
-
const
|
|
2307
|
-
const
|
|
2308
|
-
const key = [
|
|
2309
|
-
channelId,
|
|
2310
|
-
channelName ? `#${channelName}` : void 0,
|
|
2311
|
-
channelName,
|
|
2312
|
-
normalizeHyphenSlug(channelName)
|
|
2313
|
-
].filter((candidate) => Boolean(candidate)).find((candidate) => Object.hasOwn(tree.scopes, candidate)) ?? (Object.hasOwn(tree.scopes, "*") ? "*" : void 0);
|
|
2303
|
+
function buildSlackChannelPolicyScope(params) {
|
|
2304
|
+
const channels = params.channels ?? {};
|
|
2305
|
+
const tree = { scopes: channels };
|
|
2306
|
+
const matchKey = params.candidates.find((candidate) => candidate !== "*" && Object.hasOwn(tree.scopes, candidate)) ?? (Object.hasOwn(tree.scopes, "*") ? "*" : void 0);
|
|
2307
|
+
const matchSource = matchKey === void 0 ? void 0 : matchKey === "*" ? "wildcard" : "direct";
|
|
2314
2308
|
return {
|
|
2315
2309
|
tree,
|
|
2316
|
-
path:
|
|
2310
|
+
path: matchKey ? [matchKey] : [],
|
|
2311
|
+
entry: matchKey ? channels[matchKey] : void 0,
|
|
2312
|
+
wildcardEntry: channels["*"],
|
|
2313
|
+
matchKey,
|
|
2314
|
+
matchSource
|
|
2317
2315
|
};
|
|
2318
2316
|
}
|
|
2317
|
+
function resolveSlackGroupPolicyScope(params) {
|
|
2318
|
+
const accountId = normalizeAccountId(params.accountId ?? resolveDefaultSlackAccountId(params.cfg));
|
|
2319
|
+
const channels = mergeSlackAccountConfig(params.cfg, accountId).channels;
|
|
2320
|
+
const channelId = params.groupId?.trim();
|
|
2321
|
+
const channelName = params.groupChannel?.replace(/^#/, "");
|
|
2322
|
+
return buildSlackChannelPolicyScope({
|
|
2323
|
+
channels,
|
|
2324
|
+
candidates: [
|
|
2325
|
+
channelId,
|
|
2326
|
+
channelName ? `#${channelName}` : void 0,
|
|
2327
|
+
channelName,
|
|
2328
|
+
normalizeHyphenSlug(channelName)
|
|
2329
|
+
].filter((candidate) => Boolean(candidate))
|
|
2330
|
+
});
|
|
2331
|
+
}
|
|
2319
2332
|
function resolveSlackGroupRequireMention(params) {
|
|
2320
|
-
return resolveScopeRequireMention(
|
|
2333
|
+
return resolveScopeRequireMention(resolveSlackGroupPolicyScope(params));
|
|
2321
2334
|
}
|
|
2322
2335
|
function resolveSlackGroupToolPolicy(params) {
|
|
2323
2336
|
return resolveScopeToolsPolicy({
|
|
2324
|
-
...
|
|
2337
|
+
...resolveSlackGroupPolicyScope(params),
|
|
2325
2338
|
senderId: params.senderId,
|
|
2326
2339
|
senderName: params.senderName,
|
|
2327
2340
|
senderUsername: params.senderUsername,
|
|
@@ -2329,4 +2342,4 @@ function resolveSlackGroupToolPolicy(params) {
|
|
|
2329
2342
|
});
|
|
2330
2343
|
}
|
|
2331
2344
|
//#endregion
|
|
2332
|
-
export {
|
|
2345
|
+
export { hasSlackPluginApprovers as $, buildSlackBlocksFallbackText as A, truncateSlackText as B, createSlackNativeDataBaseTextConsumer as C, chunkSlackMrkdwnText as D, stripSlackNativeDataBlocks as E, SLACK_MESSAGE_TEXT_HARD_LIMIT as F, isSlackCallbackActionId as G, SLACK_REPLY_LINK_ACTION_ID as H, SLACK_TEXT_LIMIT as I, decodeSlackApprovalAction as J, renderSlackMessagePresentationFallbackText as K, buildSlackInteractiveBlocks as L, renderSlackBlockFallbackText as M, resolveSlackAuthoredTextPlacement as N, markdownToSlackMrkdwnChunks as O, SLACK_EDIT_TEXT_LIMIT as P, validateSlackBlocksArray as Q, buildSlackPresentationBlocks as R, buildSlackNativeDataAccessibilityText as S, isSlackInvalidBlocksError as T, SLACK_REPLY_SELECT_ACTION_ID as U, SLACK_REPLY_BUTTON_ACTION_ID as V, isSlackApprovalActionId as W, SLACK_MAX_BLOCKS as X, SLACK_PRESENTATION_CAPABILITIES as Y, parseSlackBlocksInput as Z, resolveSlackReplyDeliveryMessages as _, assertSlackDirectSendAllowed as a, resolveTurnSourceSlackOriginTarget as at, appendSlackNativeDataFallbackText as b, normalizeAllowListLower as c, slackTargetsMatch as ct, resolveSlackAllowListMatch as d, getSlackExecApprovalApprovers as dt, isSlackAnyNativeApprovalClientEnabled as et, resolveSlackUserAllowed as f, isSlackExecApprovalAuthorizedSender as ft, resolveSlackReplyBlocks as g, shouldSuppressLocalSlackExecApprovalPrompt as gt, resolveSlackReplyBlockResolution as h, resolveSlackExecApprovalTarget as ht, formatSlackError as i, resolveSlackFallbackOriginTarget as it, buildSlackCompleteBlocksFallbackText as j, normalizeSlackOutboundText as k, normalizeSlackAllowOwnerEntry as l, getSlackApprovalApprovers as lt, parseSlackReplyBlockSegments as m, normalizeSlackApproverId as mt, resolveSlackGroupRequireMention as n, normalizeSlackOriginTarget as nt, allowListMatches as o, shouldHandleSlackNativeApprovalRequest as ot, hasSlackReplyStructuredContent as p, isSlackExecApprovalClientEnabled as pt, escapeSlackMrkdwn as q, resolveSlackGroupToolPolicy as r, resolveSessionSlackOriginTarget as rt, normalizeAllowList as s, shouldHandleSlackPluginViaForwardingSession as st, buildSlackChannelPolicyScope as t, normalizeSlackForwardTarget as tt, normalizeSlackSlug as u, isSlackApprovalAuthorizedSender as ut, resolveSlackReplyRenderPlan as v, hasSlackNativeDataBlock as w, appendSlackNativeDataPlainTextFallback as x, SLACK_MALFORMED_NATIVE_DATA_FALLBACK as y, canRenderSlackPresentation as z };
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { t as __exportAll } from "./rolldown-runtime-D7D4PA-g.js";
|
|
2
|
-
import { C as buildSlackSlashCommandMatcher, t as monitorSlackProvider } from "./provider-
|
|
3
|
-
import { t as isSlackChannelAllowedByPolicy } from "./policy-
|
|
4
|
-
import { o as resolveSlackThreadTs } from "./replies-
|
|
2
|
+
import { C as buildSlackSlashCommandMatcher, t as monitorSlackProvider } from "./provider-CmeoUiIM.js";
|
|
3
|
+
import { t as isSlackChannelAllowedByPolicy } from "./policy-BVs4LiSa.js";
|
|
4
|
+
import { o as resolveSlackThreadTs } from "./replies-CJJCp6qz.js";
|
|
5
5
|
//#region extensions/slack/src/monitor.ts
|
|
6
6
|
var monitor_exports = /* @__PURE__ */ __exportAll({
|
|
7
7
|
buildSlackSlashCommandMatcher: () => buildSlackSlashCommandMatcher,
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { I as SLACK_TEXT_LIMIT, N as resolveSlackAuthoredTextPlacement, Y as SLACK_PRESENTATION_CAPABILITIES, _ as resolveSlackReplyDeliveryMessages, h as resolveSlackReplyBlockResolution, m as parseSlackReplyBlockSegments } from "./group-policy-85UWiriS.js";
|
|
2
2
|
import { n as resolveSlackThreadTsValue } from "./thread-ts-DUGhaYKq.js";
|
|
3
3
|
import { n as isSlackInteractiveRepliesEnabled, t as compileSlackInteractiveReplies } from "./interactive-replies-BilWUdcI.js";
|
|
4
4
|
import { normalizeOptionalString } from "openclaw/plugin-sdk/string-coerce-runtime";
|
|
@@ -9,7 +9,7 @@ import { resolvePayloadMediaUrls, sendPayloadMediaSequenceAndFinalize, sendTextM
|
|
|
9
9
|
import { attachChannelToResult, createAttachedChannelResultAdapter } from "openclaw/plugin-sdk/channel-send-result";
|
|
10
10
|
//#region extensions/slack/src/outbound-adapter.ts
|
|
11
11
|
const SLACK_RENDERED_PRESENTATION_PROVENANCE = Object.freeze({});
|
|
12
|
-
const loadSlackSendRuntime = createLazyRuntimeModule(() => import("./send.runtime-
|
|
12
|
+
const loadSlackSendRuntime = createLazyRuntimeModule(() => import("./send.runtime-CJLxAt26.js"));
|
|
13
13
|
function resolveSlackSendIdentity(identity) {
|
|
14
14
|
if (!identity) return;
|
|
15
15
|
const username = normalizeOptionalString(identity.name);
|