@openclaw/slack 2026.8.1 → 2026.8.33
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/{account-inspect-CN2hBsim.js → .setup/account-inspect-B86OaUEt.mjs} +5 -5
- package/dist/{accounts-Dm_H77gH.js → .setup/accounts-C1FspRF-.mjs} +1 -1
- package/dist/{accounts.runtime-DRuEK6mL.js → .setup/accounts.runtime-BpWv-6-2.mjs} +1 -1
- package/dist/{action-runtime-044ldvNL.js → .setup/action-runtime-C_G4J1MV.mjs} +52 -42
- package/dist/.setup/action-runtime.runtime-DldZIYpL.mjs +2 -0
- package/dist/{actions-BI7JkfVm.js → .setup/actions-8uuOLGDR.mjs} +20 -14
- package/dist/{approval-handler.runtime-DYv0UIZS.js → .setup/approval-handler.runtime-Bj-Kl-Ak.mjs} +7 -6
- package/dist/{channel-1vIJOzPx.js → .setup/channel-Dmbj_FF6.mjs} +43 -35
- package/dist/{channel-type-DlFSKeIZ.js → .setup/channel-type-CncPqtvr.mjs} +4 -4
- package/dist/{channel.setup-ofDi3_Pu.js → .setup/channel.setup-CTV8N2nI.mjs} +25 -24
- package/dist/{config-schema-BVIMyiDN.js → .setup/config-schema-B9GwoRlE.mjs} +5 -3
- package/dist/{conversation-binding-route-DFVLUdYF.js → .setup/conversation-binding-route-shed4O6L.mjs} +2 -2
- package/dist/{directory-config-DqfQ42OV.js → .setup/directory-config-CW4ICy0y.mjs} +6 -5
- package/dist/{directory-live-BPaNHjmP.js → .setup/directory-live-C2hI1rq1.mjs} +4 -4
- package/dist/{doctor-contract-BAy7-EUQ.js → .setup/doctor-contract-CtMUqjvk.mjs} +6 -5
- package/dist/{group-policy-BdwszjYn.js → .setup/group-policy-9pMyFFRP.mjs} +72 -41
- package/dist/{message-tool-api-CJ0kjcg5.js → .setup/message-tool-api-CBtuGn2d.mjs} +3 -3
- package/dist/{monitor-Dq5Cmrvp.js → .setup/monitor-t4yqSbLZ.mjs} +4 -4
- package/dist/{outbound-adapter-DYaI8ThX.js → .setup/outbound-adapter-CIO-lnfQ.mjs} +6 -6
- package/dist/{pipeline.runtime-Bd22U0ga.js → .setup/pipeline.runtime-xjOJ8ltM.mjs} +239 -394
- package/dist/{plugin-routes-CLp4obpN.js → .setup/plugin-routes-C3X0eVaK.mjs} +1 -1
- package/dist/{policy-CtQVbde1.js → .setup/policy-CpLMTEad.mjs} +7 -5
- package/dist/{probe-0usmAb0i.js → .setup/probe-DnWN6oBa.mjs} +115 -114
- package/dist/{provider-CN_8hFv2.js → .setup/provider-1mRMBuV5.mjs} +75 -50
- package/dist/{relay-source-BNGpsdwV.js → .setup/relay-source-DiUZ6ltP.mjs} +6 -4
- package/dist/{replies-BSiRQOJ1.js → .setup/replies-Cpng2F6w.mjs} +13 -8
- package/dist/{resolve-channels-Czheznc8.js → .setup/resolve-channels-Dpv7OyKO.mjs} +6 -5
- package/dist/{resolve-users-BAOlNimr.js → .setup/resolve-users-DmyA3D_2.mjs} +6 -5
- package/dist/.setup/runtime-setter-api-CMFvhrAr.mjs +3 -0
- package/dist/{scopes-COSlmhnH.js → .setup/scopes-Dcgl9Nme.mjs} +1 -1
- package/dist/.setup/secret-contract-api-D9UfYujm.mjs +3 -0
- package/dist/{security-audit-B_yKr7MW.js → .setup/security-audit-tCbGyCfU.mjs} +1 -1
- package/dist/{send-DS9ICrBI.js → .setup/send-CBfhmYDj.mjs} +24 -16
- package/dist/{send.runtime-D_Bb6IuH.js → .setup/send.runtime-BTyALMiN.mjs} +1 -1
- package/dist/.setup/setup-plugin-api-B1Y-kMp_.mjs +3 -0
- package/dist/{setup-surface-BGnd2pSe.js → .setup/setup-surface-BcIT0kDT.mjs} +6 -6
- package/dist/{shared-D5B-5hBg.js → .setup/shared-DWQcLrb8.mjs} +9 -9
- package/dist/{slash-dispatch.runtime-CilDmI0c.js → .setup/slash-dispatch.runtime-D5WAai-5.mjs} +1 -1
- package/dist/{target-parsing-BnMD2ZqZ.js → .setup/target-parsing-PbxGDbr9.mjs} +11 -6
- package/dist/{targets-Cx5W_n3W.js → .setup/targets-BlQcnjPc.mjs} +1 -1
- package/dist/account-inspect-api.js +1 -1
- package/dist/api.js +17 -17
- package/dist/channel-config-api.js +1 -1
- package/dist/channel-plugin-api.js +1 -1
- package/dist/configured-state.js +1 -1
- package/dist/directory-contract-api.js +1 -1
- package/dist/doctor-contract-api.js +1 -1
- package/dist/http-routes-api.js +1 -1
- package/dist/index.js +1 -1
- package/dist/message-tool-api.js +1 -1
- package/dist/runtime-api.js +13 -13
- package/dist/runtime-setter-api.js +1 -1
- package/dist/secret-contract-api.js +1 -1
- package/dist/security-contract-api.js +1 -1
- package/dist/setup-entry.js +4 -3
- package/dist/setup-plugin-api.js +1 -1
- package/node_modules/@slack/bolt/node_modules/negotiator/lib/accept.js +54 -0
- package/node_modules/@slack/bolt/node_modules/negotiator/lib/charset.js +10 -34
- package/node_modules/@slack/bolt/node_modules/negotiator/lib/encoding.js +9 -30
- package/node_modules/@slack/bolt/node_modules/negotiator/lib/language.js +15 -36
- package/node_modules/@slack/bolt/node_modules/negotiator/lib/mediaType.js +16 -134
- package/node_modules/@slack/bolt/node_modules/negotiator/node_modules/content-type/LICENSE +22 -0
- package/node_modules/@slack/bolt/node_modules/negotiator/node_modules/content-type/README.md +71 -0
- package/node_modules/@slack/bolt/node_modules/negotiator/node_modules/content-type/dist/index.d.ts +46 -0
- package/node_modules/@slack/bolt/node_modules/negotiator/node_modules/content-type/dist/index.js +176 -0
- package/node_modules/@slack/bolt/node_modules/negotiator/node_modules/content-type/dist/index.js.map +1 -0
- package/node_modules/@slack/bolt/node_modules/negotiator/node_modules/content-type/package.json +52 -0
- package/node_modules/@slack/bolt/node_modules/negotiator/package.json +16 -10
- package/node_modules/@slack/bolt/node_modules/proxy-addr/HISTORY.md +60 -54
- package/node_modules/@slack/bolt/node_modules/proxy-addr/README.md +1 -1
- package/node_modules/@slack/bolt/node_modules/proxy-addr/index.js +32 -0
- package/node_modules/@slack/bolt/node_modules/proxy-addr/package.json +8 -4
- package/node_modules/typebox/build/format/email.mjs +1 -1
- package/node_modules/typebox/build/format/idna/idn-hostname.mjs +19 -1
- package/node_modules/typebox/package.json +1 -1
- package/node_modules/undici/lib/dispatcher/balanced-pool.js +4 -2
- package/node_modules/undici/lib/dispatcher/client-h1.js +12 -4
- package/node_modules/undici/lib/dispatcher/client-h2.js +70 -14
- package/node_modules/undici/lib/dispatcher/client.js +6 -2
- package/node_modules/undici/lib/handler/cache-handler.js +21 -5
- package/node_modules/undici/lib/handler/retry-handler.js +42 -7
- package/node_modules/undici/lib/interceptor/cache.js +20 -1
- package/node_modules/undici/lib/interceptor/decompress.js +146 -14
- package/node_modules/undici/lib/interceptor/dump.js +10 -23
- package/node_modules/undici/lib/web/eventsource/eventsource-stream.js +245 -150
- package/node_modules/undici/lib/web/websocket/connection.js +1 -1
- package/node_modules/undici/lib/web/websocket/permessage-deflate.js +5 -0
- package/node_modules/undici/lib/web/websocket/stream/websocketstream.js +8 -10
- package/node_modules/undici/package.json +1 -1
- package/node_modules/undici/types/interceptors.d.ts +2 -0
- package/package.json +6 -6
- package/dist/action-runtime.runtime-BL3KzX13.js +0 -2
- package/node_modules/@slack/bolt/node_modules/negotiator/HISTORY.md +0 -114
- /package/dist/{account-configured-sUohAxZr.js → .setup/account-configured-sUohAxZr.mjs} +0 -0
- /package/dist/{cursor-pages-eX7p8Wwt.js → .setup/cursor-pages-eX7p8Wwt.mjs} +0 -0
- /package/dist/{registry-bbjH7IHX.js → .setup/registry-bbjH7IHX.mjs} +0 -0
- /package/dist/{rolldown-runtime-8H4AJuhK.js → .setup/rolldown-runtime-8H4AJuhK.mjs} +0 -0
- /package/dist/{runtime-JSVZSWAj.js → .setup/runtime-JSVZSWAj.mjs} +0 -0
- /package/dist/{secret-contract-DxmvbxBF.js → .setup/secret-contract-DxmvbxBF.mjs} +0 -0
- /package/dist/{send-results-eeOu_HYm.js → .setup/send-results-eeOu_HYm.mjs} +0 -0
- /package/dist/{slash-commands.runtime-BTTMlmwy.js → .setup/slash-commands.runtime-BTTMlmwy.mjs} +0 -0
- /package/dist/{slash-skill-commands.runtime-CD1J2ODY.js → .setup/slash-skill-commands.runtime-CD1J2ODY.mjs} +0 -0
- /package/dist/{streaming-compat-B-e0mqM0.js → .setup/streaming-compat-B-e0mqM0.mjs} +0 -0
- /package/dist/{thread-ts-DUGhaYKq.js → .setup/thread-ts-DUGhaYKq.mjs} +0 -0
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
import { a as resolveSlackAccount, l as resolveSlackOperationToken } from "./accounts-
|
|
2
|
-
import { a as parseSlackTarget, t as canonicalizeSlackApiTargetId } from "./target-parsing-
|
|
3
|
-
import { A as SLACK_MESSAGE_TEXT_HARD_LIMIT, D as renderSlackBlockFallbackText, E as buildSlackCompleteBlocksFallbackText, L as truncateSlackText, M as SLACK_TEXT_LIMIT, R as truncateSlackTextByUtf8Bytes, X as chunkSlackMrkdwnText, Z as markdownToSlackMrkdwnChunks, _ as appendSlackNativeDataPlainTextFallback, b as hasSlackNativeDataBlock, c as assertSlackDetachedTargetAllowed, j as SLACK_MESSAGE_TEXT_RECOMMENDED_LIMIT, k as SLACK_EDIT_TEXT_MAX_BYTES, q as resolveSlackQuestionActionIds, st as validateSlackBlocksArray, v as buildSlackNativeDataAccessibilityText, w as stripSlackNativeDataBlocks, x as isSlackInvalidBlocksError, y as createSlackNativeDataBaseTextConsumer, z as SLACK_QUESTION_FINALIZATION_BLOCKS } from "./group-policy-
|
|
4
|
-
import {
|
|
5
|
-
import {
|
|
6
|
-
import { t as getOptionalSlackRuntime } from "./runtime-JSVZSWAj.
|
|
1
|
+
import { a as resolveSlackAccount, l as resolveSlackOperationToken } from "./accounts-C1FspRF-.mjs";
|
|
2
|
+
import { a as parseSlackTarget, t as canonicalizeSlackApiTargetId } from "./target-parsing-PbxGDbr9.mjs";
|
|
3
|
+
import { A as SLACK_MESSAGE_TEXT_HARD_LIMIT, D as renderSlackBlockFallbackText, E as buildSlackCompleteBlocksFallbackText, L as truncateSlackText, M as SLACK_TEXT_LIMIT, R as truncateSlackTextByUtf8Bytes, X as chunkSlackMrkdwnText, Z as markdownToSlackMrkdwnChunks, _ as appendSlackNativeDataPlainTextFallback, b as hasSlackNativeDataBlock, c as assertSlackDetachedTargetAllowed, j as SLACK_MESSAGE_TEXT_RECOMMENDED_LIMIT, k as SLACK_EDIT_TEXT_MAX_BYTES, q as resolveSlackQuestionActionIds, st as validateSlackBlocksArray, v as buildSlackNativeDataAccessibilityText, w as stripSlackNativeDataBlocks, x as isSlackInvalidBlocksError, y as createSlackNativeDataBaseTextConsumer, z as SLACK_QUESTION_FINALIZATION_BLOCKS } from "./group-policy-9pMyFFRP.mjs";
|
|
4
|
+
import { c as createSlackReadClient, m as getSlackWriteClient, o as formatSlackError, u as createSlackTokenCacheKey } from "./probe-DnWN6oBa.mjs";
|
|
5
|
+
import { n as resolveSlackThreadTsValue, t as normalizeSlackThreadTsCandidate } from "./thread-ts-DUGhaYKq.mjs";
|
|
6
|
+
import { t as getOptionalSlackRuntime } from "./runtime-JSVZSWAj.mjs";
|
|
7
7
|
import { isRecord, normalizeLowercaseStringOrEmpty, normalizeOptionalString, normalizeTrimmedStringList } from "openclaw/plugin-sdk/string-coerce-runtime";
|
|
8
8
|
import { createMessageReceiptFromOutboundResults } from "openclaw/plugin-sdk/channel-outbound";
|
|
9
9
|
import { logVerbose, sleepWithAbort } from "openclaw/plugin-sdk/runtime-env";
|
|
@@ -135,7 +135,8 @@ function isSlackCustomizeScopeError(err) {
|
|
|
135
135
|
}
|
|
136
136
|
function isSlackCustomIdentityRejectedError(err) {
|
|
137
137
|
if (isSlackCustomizeScopeError(err)) return true;
|
|
138
|
-
const
|
|
138
|
+
const data = getSlackWebApiErrorData$1(err);
|
|
139
|
+
const code = normalizeLowercaseStringOrEmpty(normalizeOptionalString(data?.error));
|
|
139
140
|
return code === "invalid_arguments" || code === "invalid_arg_name";
|
|
140
141
|
}
|
|
141
142
|
function hasCustomIdentity$1(identity) {
|
|
@@ -422,7 +423,8 @@ async function uploadSlackFile(params) {
|
|
|
422
423
|
await release();
|
|
423
424
|
}
|
|
424
425
|
} catch (error) {
|
|
425
|
-
|
|
426
|
+
const outcome = uploadTimeoutSignal?.aborted ? "timed out" : "failed";
|
|
427
|
+
throw new PlatformMessageNotDispatchedError(`Slack external upload ${outcome} before completion dispatch`, { cause: buildSlackUploadFailureCause(error) });
|
|
426
428
|
} finally {
|
|
427
429
|
cleanupUploadTimeout();
|
|
428
430
|
}
|
|
@@ -531,7 +533,7 @@ const SLACK_DELIVERY_METADATA_PART_INDEX_KEY = "openclaw_delivery_part_index";
|
|
|
531
533
|
const SLACK_DELIVERY_METADATA_PART_COUNT_KEY = "openclaw_delivery_part_count";
|
|
532
534
|
const SLACK_DELIVERY_METADATA_SIGNATURE_KEY = "openclaw_delivery_signature";
|
|
533
535
|
const SLACK_RECONCILE_LOOKBACK_MS = 3e4;
|
|
534
|
-
const SLACK_RECONCILE_CLOCK_SKEW_MS =
|
|
536
|
+
const SLACK_RECONCILE_CLOCK_SKEW_MS = 3e5;
|
|
535
537
|
const SLACK_RECONCILE_LIMIT = 100;
|
|
536
538
|
const SLACK_RECONCILE_MAX_PAGES = 10;
|
|
537
539
|
const SLACK_ENTERPRISE_LISTENER_QUEUE_CREDENTIAL = "listener-scoped-enterprise";
|
|
@@ -600,16 +602,18 @@ function resolvePostedMessageThreadTs(response) {
|
|
|
600
602
|
return typeof threadTs === "string" ? normalizeSlackThreadTsCandidate(threadTs) : void 0;
|
|
601
603
|
}
|
|
602
604
|
async function updateMessageSlack(params) {
|
|
605
|
+
const cfg = requireRuntimeConfig(params.cfg, "Slack update");
|
|
603
606
|
const account = resolveSlackAccount({
|
|
604
|
-
cfg
|
|
607
|
+
cfg,
|
|
605
608
|
accountId: params.accountId
|
|
606
609
|
});
|
|
607
610
|
assertSlackDetachedTargetAllowed(account.accountId, params.teamId);
|
|
608
|
-
|
|
611
|
+
const token = resolveToken({
|
|
609
612
|
accountId: account.accountId,
|
|
610
613
|
fallbackToken: account.botToken,
|
|
611
614
|
fallbackSource: account.botTokenSource
|
|
612
|
-
})
|
|
615
|
+
});
|
|
616
|
+
await getSlackWriteClient(token, { teamId: params.teamId }).chat.update({
|
|
613
617
|
channel: params.channelId,
|
|
614
618
|
ts: params.messageTs,
|
|
615
619
|
text: truncateSlackTextByUtf8Bytes(params.text, SLACK_EDIT_TEXT_MAX_BYTES),
|
|
@@ -617,8 +621,9 @@ async function updateMessageSlack(params) {
|
|
|
617
621
|
});
|
|
618
622
|
}
|
|
619
623
|
function createSlackSendReceipt(params) {
|
|
624
|
+
const platformMessageIds = params.platformMessageIds.map((messageId) => messageId.trim()).filter((messageId) => messageId && messageId !== "unknown");
|
|
620
625
|
return createMessageReceiptFromOutboundResults({
|
|
621
|
-
results:
|
|
626
|
+
results: platformMessageIds.map((messageId) => {
|
|
622
627
|
const result = {
|
|
623
628
|
channel: "slack",
|
|
624
629
|
messageId
|
|
@@ -736,7 +741,8 @@ function resolveSlackTextChunks(params) {
|
|
|
736
741
|
...params.accountId ? { accountId: params.accountId } : {}
|
|
737
742
|
});
|
|
738
743
|
const chunkMode = resolveChunkMode(params.cfg, "slack", params.accountId);
|
|
739
|
-
|
|
744
|
+
const chunks = (chunkMode === "newline" ? chunkMarkdownTextWithMode(text, chunkLimit, chunkMode) : [text]).flatMap((markdown) => markdownToSlackMrkdwnChunks(markdown, chunkLimit, { tableMode }));
|
|
745
|
+
return resolveTextChunksWithFallback(text, chunks);
|
|
740
746
|
}
|
|
741
747
|
function createSlackSendQueueKey(params) {
|
|
742
748
|
const recipientKey = `${params.recipient.kind}:${params.recipient.id}`;
|
|
@@ -985,8 +991,9 @@ async function scanSlackConversationForDelivery(params) {
|
|
|
985
991
|
};
|
|
986
992
|
}
|
|
987
993
|
async function reconcileSlackUnknownSend(ctx) {
|
|
994
|
+
const cfg = requireRuntimeConfig(ctx.cfg, "Slack delivery reconciliation");
|
|
988
995
|
const account = resolveSlackAccount({
|
|
989
|
-
cfg
|
|
996
|
+
cfg,
|
|
990
997
|
accountId: ctx.accountId ?? void 0
|
|
991
998
|
});
|
|
992
999
|
const deliveryId = createSlackDeliveryMetadataId(ctx.queueId);
|
|
@@ -1021,8 +1028,9 @@ async function reconcileSlackUnknownSend(ctx) {
|
|
|
1021
1028
|
const readClient = createSlackReadClient(readToken, { teamId: recipient.teamId });
|
|
1022
1029
|
const writeClient = writeToken ? getSlackWriteClient(writeToken, { teamId: recipient.teamId }) : void 0;
|
|
1023
1030
|
const payloadReplyToId = ctx.payloads[0]?.replyToId;
|
|
1031
|
+
const effectiveReplyToId = Object.hasOwn(ctx, "effectiveReplyToId") ? normalizeOptionalString(ctx.effectiveReplyToId) : payloadReplyToId != null ? normalizeOptionalString(payloadReplyToId) : ctx.replyToMode === "off" ? void 0 : normalizeOptionalString(ctx.replyToId);
|
|
1024
1032
|
const threadTs = resolveSlackThreadTsValue({
|
|
1025
|
-
replyToId:
|
|
1033
|
+
replyToId: effectiveReplyToId,
|
|
1026
1034
|
threadId: ctx.threadId
|
|
1027
1035
|
});
|
|
1028
1036
|
const searchStartedAt = ctx.platformSendStartedAt ?? ctx.enqueuedAt;
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { a as updateMessageSlack, n as resolveSlackDmChannelId, r as sendMessageSlack, t as reconcileSlackUnknownSend } from "./send-
|
|
1
|
+
import { a as updateMessageSlack, n as resolveSlackDmChannelId, r as sendMessageSlack, t as reconcileSlackUnknownSend } from "./send-CBfhmYDj.mjs";
|
|
2
2
|
export { reconcileSlackUnknownSend, resolveSlackDmChannelId, sendMessageSlack, updateMessageSlack };
|
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
import { i as resolveDefaultSlackAccountId, o as resolveSlackAccountAllowFrom } from "./accounts-
|
|
2
|
-
import { t as inspectSlackAccount } from "./account-inspect-
|
|
3
|
-
import "./shared-
|
|
4
|
-
import { o as SLACK_CHANNEL, r as createSlackSetupWizardBase } from "./channel.setup-
|
|
5
|
-
import { t as resolveSlackChannelAllowlist } from "./resolve-channels-
|
|
6
|
-
import { t as resolveSlackUserAllowlist } from "./resolve-users-
|
|
1
|
+
import { i as resolveDefaultSlackAccountId, o as resolveSlackAccountAllowFrom } from "./accounts-C1FspRF-.mjs";
|
|
2
|
+
import { t as inspectSlackAccount } from "./account-inspect-B86OaUEt.mjs";
|
|
3
|
+
import "./shared-DWQcLrb8.mjs";
|
|
4
|
+
import { o as SLACK_CHANNEL, r as createSlackSetupWizardBase } from "./channel.setup-CTV8N2nI.mjs";
|
|
5
|
+
import { t as resolveSlackChannelAllowlist } from "./resolve-channels-Dpv7OyKO.mjs";
|
|
6
|
+
import { t as resolveSlackUserAllowlist } from "./resolve-users-DmyA3D_2.mjs";
|
|
7
7
|
import { normalizeStringEntries } from "openclaw/plugin-sdk/string-coerce-runtime";
|
|
8
8
|
import { resolveBasicAllowFromEntries } from "openclaw/plugin-sdk/allow-from";
|
|
9
9
|
import { createSetupTranslator, noteChannelLookupFailure, noteChannelLookupSummary, parseMentionOrPrefixedId, patchChannelConfigForAccount, promptResolvedAllowFrom, resolveEntriesWithOptionalToken, resolveSetupAccountId, splitSetupEntries } from "openclaw/plugin-sdk/setup-runtime";
|
|
@@ -1,11 +1,11 @@
|
|
|
1
|
-
import { n as isSlackPluginAccountConfigured } from "./account-configured-sUohAxZr.
|
|
2
|
-
import { n as listSlackAccountIds, o as resolveSlackAccountAllowFrom, r as mergeSlackAccountConfig, s as resolveSlackAccountDmPolicy } from "./accounts-
|
|
3
|
-
import { t as inspectSlackAccount } from "./account-inspect-
|
|
4
|
-
import { a as parseSlackTarget } from "./target-parsing-
|
|
5
|
-
import { a as slackIngressIdentity, t as probeSlack } from "./probe-
|
|
6
|
-
import { n as slackBaseConfigAdapter, t as slackSetupPlugin } from "./channel.setup-
|
|
7
|
-
import { n as normalizeCompatibilityConfig, t as legacyConfigRules } from "./doctor-contract-
|
|
8
|
-
import { n as collectRuntimeConfigAssignments, r as secretTargetRegistryEntries } from "./secret-contract-DxmvbxBF.
|
|
1
|
+
import { n as isSlackPluginAccountConfigured } from "./account-configured-sUohAxZr.mjs";
|
|
2
|
+
import { n as listSlackAccountIds, o as resolveSlackAccountAllowFrom, r as mergeSlackAccountConfig, s as resolveSlackAccountDmPolicy } from "./accounts-C1FspRF-.mjs";
|
|
3
|
+
import { t as inspectSlackAccount } from "./account-inspect-B86OaUEt.mjs";
|
|
4
|
+
import { a as parseSlackTarget } from "./target-parsing-PbxGDbr9.mjs";
|
|
5
|
+
import { a as slackIngressIdentity, t as probeSlack } from "./probe-DnWN6oBa.mjs";
|
|
6
|
+
import { n as slackBaseConfigAdapter, t as slackSetupPlugin } from "./channel.setup-CTV8N2nI.mjs";
|
|
7
|
+
import { n as normalizeCompatibilityConfig, t as legacyConfigRules } from "./doctor-contract-CtMUqjvk.mjs";
|
|
8
|
+
import { n as collectRuntimeConfigAssignments, r as secretTargetRegistryEntries } from "./secret-contract-DxmvbxBF.mjs";
|
|
9
9
|
import { DEFAULT_ACCOUNT_ID as DEFAULT_ACCOUNT_ID$1 } from "openclaw/plugin-sdk/account-id";
|
|
10
10
|
import { adaptScopedAccountAccessor, createScopedDmSecurityResolver } from "openclaw/plugin-sdk/channel-config-helpers";
|
|
11
11
|
import { createLazyRuntimeModule } from "openclaw/plugin-sdk/lazy-runtime";
|
|
@@ -71,7 +71,7 @@ const collectSlackSecurityFindings = createConditionalWarningCollector.findings(
|
|
|
71
71
|
severity: "critical",
|
|
72
72
|
title: "Slack security warning"
|
|
73
73
|
});
|
|
74
|
-
const loadSlackSecurityAuditModule = createLazyRuntimeModule(() => import("./security-audit-
|
|
74
|
+
const loadSlackSecurityAuditModule = createLazyRuntimeModule(() => import("./security-audit-tCbGyCfU.mjs").then((n) => n.n));
|
|
75
75
|
const slackSecurityAdapter = {
|
|
76
76
|
resolveDmPolicy: resolveSlackDmPolicy,
|
|
77
77
|
collectWarnings: collectSlackSecurityFindings,
|
package/dist/{slash-dispatch.runtime-CilDmI0c.js → .setup/slash-dispatch.runtime-D5WAai-5.mjs}
RENAMED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { r as deliverSlackSlashReplies$1, s as sanitizeSlackMonitorReplyPayload } from "./replies-
|
|
1
|
+
import { r as deliverSlackSlashReplies$1, s as sanitizeSlackMonitorReplyPayload } from "./replies-Cpng2F6w.mjs";
|
|
2
2
|
import { resolveAgentRoute as resolveAgentRoute$1 } from "openclaw/plugin-sdk/routing";
|
|
3
3
|
import { resolveMarkdownTableMode as resolveMarkdownTableMode$1 } from "openclaw/plugin-sdk/markdown-table-runtime";
|
|
4
4
|
import { resolveConversationLabel as resolveConversationLabel$1 } from "openclaw/plugin-sdk/conversation-runtime";
|
|
@@ -73,19 +73,24 @@ function parseSlackTarget(raw, options = {}) {
|
|
|
73
73
|
atUserErrorMessage: "Slack DMs require a user id (use user:<id> or <@id>)"
|
|
74
74
|
});
|
|
75
75
|
if (userTarget) return userTarget;
|
|
76
|
-
if (trimmed.startsWith("#"))
|
|
77
|
-
candidate
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
76
|
+
if (trimmed.startsWith("#")) {
|
|
77
|
+
const candidate = trimmed.slice(1).trim();
|
|
78
|
+
const id = ensureTargetId({
|
|
79
|
+
candidate,
|
|
80
|
+
pattern: /^[A-Z0-9]+$/i,
|
|
81
|
+
errorMessage: "Slack channels require a channel id (use channel:<id>)"
|
|
82
|
+
});
|
|
83
|
+
return buildMessagingTarget("channel", id, trimmed);
|
|
84
|
+
}
|
|
81
85
|
if (isUnambiguousSlackUserId(trimmed)) return buildMessagingTarget("user", trimmed, trimmed);
|
|
82
86
|
if (options.defaultKind) return buildMessagingTarget(options.defaultKind, trimmed, trimmed);
|
|
83
87
|
return buildMessagingTarget("channel", trimmed, trimmed);
|
|
84
88
|
}
|
|
85
89
|
function resolveSlackChannelId(raw) {
|
|
90
|
+
const target = parseSlackTarget(raw, { defaultKind: "channel" });
|
|
86
91
|
return canonicalizeSlackApiTargetId("channel", requireTargetKind({
|
|
87
92
|
platform: "Slack",
|
|
88
|
-
target
|
|
93
|
+
target,
|
|
89
94
|
kind: "channel"
|
|
90
95
|
}), raw);
|
|
91
96
|
}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { a as parseSlackTarget, s as slackTargetsMatch } from "./target-parsing-
|
|
1
|
+
import { a as parseSlackTarget, s as slackTargetsMatch } from "./target-parsing-PbxGDbr9.mjs";
|
|
2
2
|
//#region extensions/slack/src/targets.ts
|
|
3
3
|
function matchesResolvedUserTarget(target, currentMessagingTarget) {
|
|
4
4
|
const resolvedId = target.trim();
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { t as inspectSlackAccount } from "
|
|
1
|
+
import { t as inspectSlackAccount } from "./.setup/account-inspect-B86OaUEt.mjs";
|
|
2
2
|
//#region extensions/slack/account-inspect-api.ts
|
|
3
3
|
function inspectSlackReadOnlyAccount(cfg, accountId) {
|
|
4
4
|
return inspectSlackAccount({
|
package/dist/api.js
CHANGED
|
@@ -1,18 +1,18 @@
|
|
|
1
|
-
import { n as registerSlackHttpHandler, r as normalizeSlackWebhookPath, t as handleSlackHttpRequest } from "
|
|
2
|
-
import { a as resolveSlackAccount, i as resolveDefaultSlackAccountId, n as listSlackAccountIds, r as mergeSlackAccountConfig, t as listEnabledSlackAccounts } from "
|
|
3
|
-
import { r as resolveSlackReplyToMode } from "
|
|
4
|
-
import { t as inspectSlackAccount } from "
|
|
5
|
-
import { a as parseSlackTarget, i as normalizeSlackMessagingTarget, o as resolveSlackChannelId, r as looksLikeSlackTargetId } from "
|
|
6
|
-
import "
|
|
7
|
-
import { N as buildSlackInteractiveBlocks, P as buildSlackPresentationBlocks, at as SLACK_MAX_BLOCKS, i as resolveSlackGroupToolPolicy, jt as resolveSlackAutoThreadId, ot as parseSlackBlocksInput, r as resolveSlackGroupRequireMention, st as validateSlackBlocksArray } from "
|
|
8
|
-
import {
|
|
9
|
-
import { n as
|
|
10
|
-
import {
|
|
11
|
-
import { n as resolveSlackChannelType } from "
|
|
12
|
-
import { t as slackSetupPlugin } from "
|
|
13
|
-
import { c as listSlackPins, d as reactSlackMessage, f as readSlackMessages, g as unpinSlackMessage, h as sendSlackMessage, i as editSlackMessage, l as listSlackReactions, m as removeSlackReaction, n as deleteSlackMessage, o as getSlackMemberInfo, p as removeOwnSlackReactions, r as downloadSlackFile, s as listSlackEmojis, u as pinSlackMessage } from "
|
|
14
|
-
import { f as recordSlackThreadParticipation, l as hasSlackThreadParticipation, s as clearSlackThreadParticipationCache } from "
|
|
15
|
-
import { n as listSlackDirectoryGroupsFromConfig, r as listSlackDirectoryPeersFromConfig } from "
|
|
16
|
-
import { t as collectSlackSecurityAuditFindings } from "
|
|
17
|
-
import { n as resolveSlackRuntimeGroupPolicy } from "
|
|
1
|
+
import { n as registerSlackHttpHandler, r as normalizeSlackWebhookPath, t as handleSlackHttpRequest } from "./.setup/registry-bbjH7IHX.mjs";
|
|
2
|
+
import { a as resolveSlackAccount, i as resolveDefaultSlackAccountId, n as listSlackAccountIds, r as mergeSlackAccountConfig, t as listEnabledSlackAccounts } from "./.setup/accounts-C1FspRF-.mjs";
|
|
3
|
+
import { r as resolveSlackReplyToMode } from "./.setup/conversation-binding-route-shed4O6L.mjs";
|
|
4
|
+
import { t as inspectSlackAccount } from "./.setup/account-inspect-B86OaUEt.mjs";
|
|
5
|
+
import { a as parseSlackTarget, i as normalizeSlackMessagingTarget, o as resolveSlackChannelId, r as looksLikeSlackTargetId } from "./.setup/target-parsing-PbxGDbr9.mjs";
|
|
6
|
+
import "./.setup/targets-BlQcnjPc.mjs";
|
|
7
|
+
import { N as buildSlackInteractiveBlocks, P as buildSlackPresentationBlocks, at as SLACK_MAX_BLOCKS, i as resolveSlackGroupToolPolicy, jt as resolveSlackAutoThreadId, ot as parseSlackBlocksInput, r as resolveSlackGroupRequireMention, st as validateSlackBlocksArray } from "./.setup/group-policy-9pMyFFRP.mjs";
|
|
8
|
+
import { C as normalizeAllowListLower, E as resolveSlackAllowListMatch, O as resolveSlackUserAllowed, S as normalizeAllowList, T as normalizeSlackSlug, b as resolveSlackWriteClientOptions, d as createSlackWebClient, f as createSlackWriteClient, g as SLACK_WRITE_RETRY_OPTIONS, h as SLACK_DEFAULT_RETRY_OPTIONS, m as getSlackWriteClient, t as probeSlack, u as createSlackTokenCacheKey, w as normalizeSlackAllowOwnerEntry, x as allowListMatches, y as resolveSlackWebClientOptions } from "./.setup/probe-DnWN6oBa.mjs";
|
|
9
|
+
import { n as buildSlackThreadingToolContext, t as slackPlugin } from "./.setup/channel-Dmbj_FF6.mjs";
|
|
10
|
+
import { n as extractSlackToolSend, r as listSlackMessageActions } from "./.setup/message-tool-api-CBtuGn2d.mjs";
|
|
11
|
+
import { n as resolveSlackChannelType } from "./.setup/channel-type-CncPqtvr.mjs";
|
|
12
|
+
import { t as slackSetupPlugin } from "./.setup/channel.setup-CTV8N2nI.mjs";
|
|
13
|
+
import { c as listSlackPins, d as reactSlackMessage, f as readSlackMessages, g as unpinSlackMessage, h as sendSlackMessage, i as editSlackMessage, l as listSlackReactions, m as removeSlackReaction, n as deleteSlackMessage, o as getSlackMemberInfo, p as removeOwnSlackReactions, r as downloadSlackFile, s as listSlackEmojis, u as pinSlackMessage } from "./.setup/actions-8uuOLGDR.mjs";
|
|
14
|
+
import { f as recordSlackThreadParticipation, l as hasSlackThreadParticipation, s as clearSlackThreadParticipationCache } from "./.setup/send-CBfhmYDj.mjs";
|
|
15
|
+
import { n as listSlackDirectoryGroupsFromConfig, r as listSlackDirectoryPeersFromConfig } from "./.setup/directory-config-CW4ICy0y.mjs";
|
|
16
|
+
import { t as collectSlackSecurityAuditFindings } from "./.setup/security-audit-tCbGyCfU.mjs";
|
|
17
|
+
import { n as resolveSlackRuntimeGroupPolicy } from "./.setup/provider-1mRMBuV5.mjs";
|
|
18
18
|
export { SLACK_DEFAULT_RETRY_OPTIONS, SLACK_MAX_BLOCKS, SLACK_WRITE_RETRY_OPTIONS, allowListMatches, buildSlackInteractiveBlocks, buildSlackPresentationBlocks, buildSlackThreadingToolContext, clearSlackThreadParticipationCache, collectSlackSecurityAuditFindings, createSlackTokenCacheKey, createSlackWebClient, createSlackWriteClient, deleteSlackMessage, downloadSlackFile, editSlackMessage, extractSlackToolSend, getSlackMemberInfo, getSlackWriteClient, handleSlackHttpRequest, hasSlackThreadParticipation, inspectSlackAccount, listEnabledSlackAccounts, listSlackAccountIds, listSlackDirectoryGroupsFromConfig, listSlackDirectoryPeersFromConfig, listSlackEmojis, listSlackMessageActions, listSlackPins, listSlackReactions, looksLikeSlackTargetId, mergeSlackAccountConfig, normalizeAllowList, normalizeAllowListLower, normalizeSlackAllowOwnerEntry, normalizeSlackMessagingTarget, normalizeSlackSlug, normalizeSlackWebhookPath, parseSlackBlocksInput, 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,2 +1,2 @@
|
|
|
1
|
-
import { t as SlackChannelConfigSchema } from "
|
|
1
|
+
import { t as SlackChannelConfigSchema } from "./.setup/config-schema-B9GwoRlE.mjs";
|
|
2
2
|
export { SlackChannelConfigSchema };
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { t as slackPlugin } from "
|
|
1
|
+
import { t as slackPlugin } from "./.setup/channel-Dmbj_FF6.mjs";
|
|
2
2
|
export { slackPlugin };
|
package/dist/configured-state.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { t as hasSlackAccountCredentials } from "
|
|
1
|
+
import { t as hasSlackAccountCredentials } from "./.setup/account-configured-sUohAxZr.mjs";
|
|
2
2
|
import { DEFAULT_ACCOUNT_ID, hasConfiguredAccountValue, mergeAccountConfig } from "openclaw/plugin-sdk/account-core";
|
|
3
3
|
//#region extensions/slack/configured-state.ts
|
|
4
4
|
function hasConfiguredSlackAccount(account, env) {
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { n as listSlackDirectoryGroupsFromConfig, r as listSlackDirectoryPeersFromConfig } from "
|
|
1
|
+
import { n as listSlackDirectoryGroupsFromConfig, r as listSlackDirectoryPeersFromConfig } from "./.setup/directory-config-CW4ICy0y.mjs";
|
|
2
2
|
export { listSlackDirectoryGroupsFromConfig, listSlackDirectoryPeersFromConfig };
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { n as normalizeCompatibilityConfig, t as legacyConfigRules } from "
|
|
1
|
+
import { n as normalizeCompatibilityConfig, t as legacyConfigRules } from "./.setup/doctor-contract-CtMUqjvk.mjs";
|
|
2
2
|
export { legacyConfigRules, normalizeCompatibilityConfig };
|
package/dist/http-routes-api.js
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { t as registerSlackPluginHttpRoutes } from "
|
|
1
|
+
import { t as registerSlackPluginHttpRoutes } from "./.setup/plugin-routes-C3X0eVaK.mjs";
|
|
2
2
|
export { registerSlackPluginHttpRoutes };
|
package/dist/index.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { t as registerSlackPluginHttpRoutes } from "
|
|
1
|
+
import { t as registerSlackPluginHttpRoutes } from "./.setup/plugin-routes-C3X0eVaK.mjs";
|
|
2
2
|
import "./http-routes-api.js";
|
|
3
3
|
import { defineBundledChannelEntry } from "openclaw/plugin-sdk/channel-entry-contract";
|
|
4
4
|
//#region extensions/slack/index.ts
|
package/dist/message-tool-api.js
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { t as describeSlackMessageTool } from "
|
|
1
|
+
import { t as describeSlackMessageTool } from "./.setup/message-tool-api-CBtuGn2d.mjs";
|
|
2
2
|
export { describeSlackMessageTool as describeMessageTool };
|
package/dist/runtime-api.js
CHANGED
|
@@ -1,14 +1,14 @@
|
|
|
1
|
-
import { t as registerSlackPluginHttpRoutes } from "
|
|
2
|
-
import { a as resolveSlackAccount, d as resolveSlackAppToken, f as resolveSlackBotToken, i as resolveDefaultSlackAccountId, n as listSlackAccountIds, t as listEnabledSlackAccounts } from "
|
|
3
|
-
import { i as resolveSlackGroupToolPolicy, r as resolveSlackGroupRequireMention } from "
|
|
4
|
-
import { t as probeSlack } from "
|
|
5
|
-
import { r as setSlackRuntime } from "
|
|
6
|
-
import { c as listSlackPins, d as reactSlackMessage, f as readSlackMessages, g as unpinSlackMessage, h as sendSlackMessage, i as editSlackMessage, l as listSlackReactions, m as removeSlackReaction, n as deleteSlackMessage, o as getSlackMemberInfo, p as removeOwnSlackReactions, s as listSlackEmojis, u as pinSlackMessage } from "
|
|
7
|
-
import { r as sendMessageSlack } from "
|
|
8
|
-
import { t as resolveSlackChannelAllowlist } from "
|
|
9
|
-
import { t as resolveSlackUserAllowlist } from "
|
|
10
|
-
import { t as monitorSlackProvider } from "
|
|
11
|
-
import { n as slackActionRuntime, t as handleSlackAction } from "
|
|
12
|
-
import { n as listSlackDirectoryGroupsLive, r as listSlackDirectoryPeersLive } from "
|
|
13
|
-
import "
|
|
1
|
+
import { t as registerSlackPluginHttpRoutes } from "./.setup/plugin-routes-C3X0eVaK.mjs";
|
|
2
|
+
import { a as resolveSlackAccount, d as resolveSlackAppToken, f as resolveSlackBotToken, i as resolveDefaultSlackAccountId, n as listSlackAccountIds, t as listEnabledSlackAccounts } from "./.setup/accounts-C1FspRF-.mjs";
|
|
3
|
+
import { i as resolveSlackGroupToolPolicy, r as resolveSlackGroupRequireMention } from "./.setup/group-policy-9pMyFFRP.mjs";
|
|
4
|
+
import { t as probeSlack } from "./.setup/probe-DnWN6oBa.mjs";
|
|
5
|
+
import { r as setSlackRuntime } from "./.setup/runtime-JSVZSWAj.mjs";
|
|
6
|
+
import { c as listSlackPins, d as reactSlackMessage, f as readSlackMessages, g as unpinSlackMessage, h as sendSlackMessage, i as editSlackMessage, l as listSlackReactions, m as removeSlackReaction, n as deleteSlackMessage, o as getSlackMemberInfo, p as removeOwnSlackReactions, s as listSlackEmojis, u as pinSlackMessage } from "./.setup/actions-8uuOLGDR.mjs";
|
|
7
|
+
import { r as sendMessageSlack } from "./.setup/send-CBfhmYDj.mjs";
|
|
8
|
+
import { t as resolveSlackChannelAllowlist } from "./.setup/resolve-channels-Dpv7OyKO.mjs";
|
|
9
|
+
import { t as resolveSlackUserAllowlist } from "./.setup/resolve-users-DmyA3D_2.mjs";
|
|
10
|
+
import { t as monitorSlackProvider } from "./.setup/provider-1mRMBuV5.mjs";
|
|
11
|
+
import { n as slackActionRuntime, t as handleSlackAction } from "./.setup/action-runtime-C_G4J1MV.mjs";
|
|
12
|
+
import { n as listSlackDirectoryGroupsLive, r as listSlackDirectoryPeersLive } from "./.setup/directory-live-C2hI1rq1.mjs";
|
|
13
|
+
import "./.setup/monitor-t4yqSbLZ.mjs";
|
|
14
14
|
export { deleteSlackMessage, editSlackMessage, getSlackMemberInfo, handleSlackAction, listEnabledSlackAccounts, listSlackAccountIds, listSlackDirectoryGroupsLive, listSlackDirectoryPeersLive, listSlackEmojis, listSlackPins, listSlackReactions, monitorSlackProvider, pinSlackMessage, probeSlack, reactSlackMessage, readSlackMessages, registerSlackPluginHttpRoutes, removeOwnSlackReactions, removeSlackReaction, resolveDefaultSlackAccountId, resolveSlackAccount, resolveSlackAppToken, resolveSlackBotToken, resolveSlackChannelAllowlist, resolveSlackGroupRequireMention, resolveSlackGroupToolPolicy, resolveSlackUserAllowlist, sendMessageSlack, sendSlackMessage, setSlackRuntime, slackActionRuntime, unpinSlackMessage };
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { r as setSlackRuntime } from "
|
|
1
|
+
import { r as setSlackRuntime } from "./.setup/runtime-JSVZSWAj.mjs";
|
|
2
2
|
export { setSlackRuntime };
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { n as collectRuntimeConfigAssignments, r as secretTargetRegistryEntries, t as channelSecrets } from "
|
|
1
|
+
import { n as collectRuntimeConfigAssignments, r as secretTargetRegistryEntries, t as channelSecrets } from "./.setup/secret-contract-DxmvbxBF.mjs";
|
|
2
2
|
export { channelSecrets, collectRuntimeConfigAssignments, secretTargetRegistryEntries };
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { t as collectSlackSecurityAuditFindings } from "
|
|
1
|
+
import { t as collectSlackSecurityAuditFindings } from "./.setup/security-audit-tCbGyCfU.mjs";
|
|
2
2
|
export { collectSlackSecurityAuditFindings };
|
package/dist/setup-entry.js
CHANGED
|
@@ -1,17 +1,18 @@
|
|
|
1
1
|
import { defineBundledChannelSetupEntry } from "openclaw/plugin-sdk/channel-entry-contract";
|
|
2
|
+
import { fileURLToPath } from "node:url";
|
|
2
3
|
//#region extensions/slack/setup-entry.ts
|
|
3
4
|
var setup_entry_default = defineBundledChannelSetupEntry({
|
|
4
5
|
importMetaUrl: import.meta.url,
|
|
5
6
|
plugin: {
|
|
6
|
-
specifier: "
|
|
7
|
+
specifier: fileURLToPath(new URL(".setup/setup-plugin-api-B1Y-kMp_.mjs", import.meta.url).href),
|
|
7
8
|
exportName: "slackSetupPlugin"
|
|
8
9
|
},
|
|
9
10
|
secrets: {
|
|
10
|
-
specifier: "
|
|
11
|
+
specifier: fileURLToPath(new URL(".setup/secret-contract-api-D9UfYujm.mjs", import.meta.url).href),
|
|
11
12
|
exportName: "channelSecrets"
|
|
12
13
|
},
|
|
13
14
|
runtime: {
|
|
14
|
-
specifier: "
|
|
15
|
+
specifier: fileURLToPath(new URL(".setup/runtime-setter-api-CMFvhrAr.mjs", import.meta.url).href),
|
|
15
16
|
exportName: "setSlackRuntime"
|
|
16
17
|
}
|
|
17
18
|
});
|
package/dist/setup-plugin-api.js
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { t as slackSetupPlugin } from "
|
|
1
|
+
import { t as slackSetupPlugin } from "./.setup/channel.setup-CTV8N2nI.mjs";
|
|
2
2
|
export { slackSetupPlugin };
|
|
@@ -0,0 +1,54 @@
|
|
|
1
|
+
/*!
|
|
2
|
+
* negotiator
|
|
3
|
+
* Copyright(c) 2026 Blake Embrey
|
|
4
|
+
* MIT Licensed
|
|
5
|
+
*/
|
|
6
|
+
|
|
7
|
+
'use strict';
|
|
8
|
+
|
|
9
|
+
var contentType = require('content-type');
|
|
10
|
+
|
|
11
|
+
/**
|
|
12
|
+
* Module exports.
|
|
13
|
+
* @private
|
|
14
|
+
*/
|
|
15
|
+
|
|
16
|
+
module.exports = parseAccept;
|
|
17
|
+
|
|
18
|
+
/**
|
|
19
|
+
* Parse an Accept-style header.
|
|
20
|
+
* @private
|
|
21
|
+
*/
|
|
22
|
+
|
|
23
|
+
function parseAccept(header) {
|
|
24
|
+
var values = [];
|
|
25
|
+
var index = 0;
|
|
26
|
+
|
|
27
|
+
while (index < header.length) {
|
|
28
|
+
var start = skipOptionalWhitespace(header, index);
|
|
29
|
+
var parsed = contentType.parse(header, { comma: true, start: start });
|
|
30
|
+
|
|
31
|
+
// `content-type` normalizes the type, but accept methods return original casing.
|
|
32
|
+
parsed.type = header.slice(start, start + parsed.type.length);
|
|
33
|
+
values.push(parsed);
|
|
34
|
+
|
|
35
|
+
index = parsed.index + 1;
|
|
36
|
+
}
|
|
37
|
+
|
|
38
|
+
return values;
|
|
39
|
+
}
|
|
40
|
+
|
|
41
|
+
/**
|
|
42
|
+
* Skip optional whitespace.
|
|
43
|
+
* @private
|
|
44
|
+
*/
|
|
45
|
+
|
|
46
|
+
function skipOptionalWhitespace(header, index) {
|
|
47
|
+
var cursor = index;
|
|
48
|
+
|
|
49
|
+
while (header.charCodeAt(cursor) === 0x20 || header.charCodeAt(cursor) === 0x09) {
|
|
50
|
+
cursor++;
|
|
51
|
+
}
|
|
52
|
+
|
|
53
|
+
return cursor;
|
|
54
|
+
}
|
|
@@ -8,6 +8,8 @@
|
|
|
8
8
|
|
|
9
9
|
'use strict';
|
|
10
10
|
|
|
11
|
+
var parseAccept = require('./accept');
|
|
12
|
+
|
|
11
13
|
/**
|
|
12
14
|
* Module exports.
|
|
13
15
|
* @public
|
|
@@ -21,55 +23,29 @@ module.exports.preferredCharsets = preferredCharsets;
|
|
|
21
23
|
* @private
|
|
22
24
|
*/
|
|
23
25
|
|
|
24
|
-
var simpleCharsetRegExp = /^\s*([^\s;]+)\s*(?:;(.*))?$/;
|
|
25
|
-
|
|
26
|
-
/**
|
|
27
|
-
* Parse the Accept-Charset header.
|
|
28
|
-
* @private
|
|
29
|
-
*/
|
|
30
|
-
|
|
31
26
|
function parseAcceptCharset(accept) {
|
|
32
|
-
var accepts = accept
|
|
27
|
+
var accepts = parseAccept(accept);
|
|
33
28
|
|
|
34
29
|
for (var i = 0, j = 0; i < accepts.length; i++) {
|
|
35
|
-
var charset =
|
|
36
|
-
|
|
37
|
-
if (charset) {
|
|
38
|
-
accepts[j++] = charset;
|
|
39
|
-
}
|
|
30
|
+
var charset = formatCharset(accepts[i], i);
|
|
31
|
+
if (charset) accepts[j++] = charset;
|
|
40
32
|
}
|
|
41
33
|
|
|
42
|
-
// trim accepts
|
|
43
34
|
accepts.length = j;
|
|
44
|
-
|
|
45
35
|
return accepts;
|
|
46
36
|
}
|
|
47
37
|
|
|
48
38
|
/**
|
|
49
|
-
*
|
|
39
|
+
* Format a parsed charset for negotiation.
|
|
50
40
|
* @private
|
|
51
41
|
*/
|
|
52
42
|
|
|
53
|
-
function
|
|
54
|
-
|
|
55
|
-
if (!match) return null;
|
|
56
|
-
|
|
57
|
-
var charset = match[1];
|
|
58
|
-
var q = 1;
|
|
59
|
-
if (match[2]) {
|
|
60
|
-
var params = match[2].split(';')
|
|
61
|
-
for (var j = 0; j < params.length; j++) {
|
|
62
|
-
var p = params[j].trim().split('=');
|
|
63
|
-
if (p[0] === 'q') {
|
|
64
|
-
q = parseFloat(p[1]);
|
|
65
|
-
break;
|
|
66
|
-
}
|
|
67
|
-
}
|
|
68
|
-
}
|
|
43
|
+
function formatCharset(parsed, i) {
|
|
44
|
+
if (!parsed.type) return null;
|
|
69
45
|
|
|
70
46
|
return {
|
|
71
|
-
charset:
|
|
72
|
-
q: q,
|
|
47
|
+
charset: parsed.type,
|
|
48
|
+
q: parsed.parameters.q ? parseFloat(parsed.parameters.q) : 1,
|
|
73
49
|
i: i
|
|
74
50
|
};
|
|
75
51
|
}
|
|
@@ -8,6 +8,8 @@
|
|
|
8
8
|
|
|
9
9
|
'use strict';
|
|
10
10
|
|
|
11
|
+
var parseAccept = require('./accept');
|
|
12
|
+
|
|
11
13
|
/**
|
|
12
14
|
* Module exports.
|
|
13
15
|
* @public
|
|
@@ -21,20 +23,13 @@ module.exports.preferredEncodings = preferredEncodings;
|
|
|
21
23
|
* @private
|
|
22
24
|
*/
|
|
23
25
|
|
|
24
|
-
var simpleEncodingRegExp = /^\s*([^\s;]+)\s*(?:;(.*))?$/;
|
|
25
|
-
|
|
26
|
-
/**
|
|
27
|
-
* Parse the Accept-Encoding header.
|
|
28
|
-
* @private
|
|
29
|
-
*/
|
|
30
|
-
|
|
31
26
|
function parseAcceptEncoding(accept) {
|
|
32
|
-
var accepts = accept
|
|
27
|
+
var accepts = parseAccept(accept);
|
|
33
28
|
var hasIdentity = false;
|
|
34
29
|
var minQuality = 1;
|
|
35
30
|
|
|
36
31
|
for (var i = 0, j = 0; i < accepts.length; i++) {
|
|
37
|
-
var encoding =
|
|
32
|
+
var encoding = formatEncoding(accepts[i], i);
|
|
38
33
|
|
|
39
34
|
if (encoding) {
|
|
40
35
|
accepts[j++] = encoding;
|
|
@@ -55,37 +50,21 @@ function parseAcceptEncoding(accept) {
|
|
|
55
50
|
};
|
|
56
51
|
}
|
|
57
52
|
|
|
58
|
-
// trim accepts
|
|
59
53
|
accepts.length = j;
|
|
60
|
-
|
|
61
54
|
return accepts;
|
|
62
55
|
}
|
|
63
56
|
|
|
64
57
|
/**
|
|
65
|
-
*
|
|
58
|
+
* Format a parsed encoding for negotiation.
|
|
66
59
|
* @private
|
|
67
60
|
*/
|
|
68
61
|
|
|
69
|
-
function
|
|
70
|
-
|
|
71
|
-
if (!match) return null;
|
|
72
|
-
|
|
73
|
-
var encoding = match[1];
|
|
74
|
-
var q = 1;
|
|
75
|
-
if (match[2]) {
|
|
76
|
-
var params = match[2].split(';');
|
|
77
|
-
for (var j = 0; j < params.length; j++) {
|
|
78
|
-
var p = params[j].trim().split('=');
|
|
79
|
-
if (p[0] === 'q') {
|
|
80
|
-
q = parseFloat(p[1]);
|
|
81
|
-
break;
|
|
82
|
-
}
|
|
83
|
-
}
|
|
84
|
-
}
|
|
62
|
+
function formatEncoding(parsed, i) {
|
|
63
|
+
if (!parsed.type) return null;
|
|
85
64
|
|
|
86
65
|
return {
|
|
87
|
-
encoding:
|
|
88
|
-
q: q,
|
|
66
|
+
encoding: parsed.type,
|
|
67
|
+
q: parsed.parameters.q ? parseFloat(parsed.parameters.q) : 1,
|
|
89
68
|
i: i
|
|
90
69
|
};
|
|
91
70
|
}
|