@openclaw/discord 2026.5.16-beta.2 → 2026.5.16-beta.4

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 (74) hide show
  1. package/dist/api.js +12 -12
  2. package/dist/{approval-handler.runtime-CS97g4S1.js → approval-handler.runtime-B5Dd-jlK.js} +1 -1
  3. package/dist/{channel-ngFtP-WD.js → channel-DeO4mqqA.js} +13 -13
  4. package/dist/{channel-actions-0dOFg3Mu.js → channel-actions--MV0t13k.js} +14 -7
  5. package/dist/{channel-actions.runtime-BB30vneH.js → channel-actions.runtime-G9ARNi7H.js} +29 -8
  6. package/dist/channel-config-api.js +1 -1
  7. package/dist/channel-plugin-api.js +1 -1
  8. package/dist/{channel.setup-BwmvzHMR.js → channel.setup-DMqaeOeB.js} +3 -3
  9. package/dist/contract-api.js +7 -7
  10. package/dist/{conversation-identity-Dh8wIQ_K.js → conversation-identity-Bpwp-7uO.js} +1 -1
  11. package/dist/directory-contract-api.js +1 -1
  12. package/dist/{doctor-CWTWiBru.js → doctor-DfHqek8h.js} +3 -3
  13. package/dist/{doctor-contract-ftWAMvBl.js → doctor-contract-AkgUZQHW.js} +1 -1
  14. package/dist/doctor-contract-api.js +1 -1
  15. package/dist/inbound-event-delivery-D8zHG9Lz.js +65 -0
  16. package/dist/{manager.runtime-D8sDxzBv.js → manager.runtime-BsOZkg8V.js} +2 -2
  17. package/dist/{message-handler-D-Nboii4.js → message-handler-B-SLojCO.js} +6 -6
  18. package/dist/{message-handler.preflight-BMgBVbmR.js → message-handler.preflight-DPcejg12.js} +26 -12
  19. package/dist/{message-handler.process-Dfu_aSv1.js → message-handler.process-B9kCtqjZ.js} +55 -18
  20. package/dist/{message-utils-CY91O2k2.js → message-utils-BZoXOhcI.js} +2 -2
  21. package/dist/{outbound-adapter-Fe4Ee_GO.js → outbound-adapter-DyTqAH35.js} +11 -2
  22. package/dist/{preflight-audio-DFGpAvzi.js → preflight-audio-B0keJeQe.js} +1 -1
  23. package/dist/{probe.runtime-9hi1GYNU.js → probe.runtime-CvMZb8ZL.js} +1 -1
  24. package/dist/{provider-B81nXBRc.js → provider-BYIVfxV_.js} +215 -28
  25. package/dist/{provider-session.runtime-C7p_WbqZ.js → provider-session.runtime-B-8Gitv9.js} +3 -3
  26. package/dist/provider.runtime-BZj7ZoKH.js +2 -0
  27. package/dist/{resolve-channels-u7_agBcm.js → resolve-channels-CerN-VOT.js} +1 -1
  28. package/dist/{resolve-users-Bc25I6OP.js → resolve-users-DIG4uHLS.js} +1 -1
  29. package/dist/runtime-api.actions.js +1 -1
  30. package/dist/runtime-api.js +15 -15
  31. package/dist/runtime-api.lookup.js +4 -4
  32. package/dist/runtime-api.monitor-DJZRR16k.js +5 -0
  33. package/dist/runtime-api.monitor.js +5 -5
  34. package/dist/runtime-api.threads.js +5 -5
  35. package/dist/secret-contract-api.js +1 -1
  36. package/dist/{security-audit-CLPZKYi4.js → security-audit-Dx3j4a0l.js} +1 -1
  37. package/dist/security-audit-contract-api.js +1 -1
  38. package/dist/{security-audit.runtime-CCm9leFJ.js → security-audit.runtime-C5nnf0k8.js} +1 -1
  39. package/dist/security-contract-api.js +1 -1
  40. package/dist/session-key-api.js +1 -1
  41. package/dist/setup-plugin-api.js +1 -1
  42. package/dist/{shared-LuaeDRhK.js → shared-CpwVKWm5.js} +7 -7
  43. package/dist/{subagent-hooks-vwV-pjIA.js → subagent-hooks-DguyFWsd.js} +1 -1
  44. package/dist/subagent-hooks-api.js +1 -1
  45. package/dist/test-api.js +4 -4
  46. package/dist/{thread-bindings-BwcE40jS.js → thread-bindings-CqKojFDg.js} +4 -4
  47. package/dist/{thread-bindings.discord-api-BtXi8-Fz.js → thread-bindings.discord-api-BQJf05t-.js} +1 -1
  48. package/dist/{thread-bindings.manager-BL5QlX3G.js → thread-bindings.manager-kjSGaifo.js} +2 -2
  49. package/dist/{thread-bindings.session-updates-ZnRRzzgf.js → thread-bindings.session-updates-CgOqEOPe.js} +1 -1
  50. package/dist/timeouts.js +1 -1
  51. package/dist/{typing-C_8U8J7E.js → typing-DudlJ-Fv.js} +1 -1
  52. package/package.json +4 -4
  53. package/dist/provider.runtime-B_3TYTb7.js +0 -2
  54. package/dist/runtime-api.monitor-DJQdXyzE.js +0 -5
  55. /package/dist/{agent-components.runtime-CEMbMQcQ.js → agent-components.runtime-BIemD2Iz.js} +0 -0
  56. /package/dist/{audit-BZOw16KT.js → audit-CPAL0IL6.js} +0 -0
  57. /package/dist/{config-schema-D0eb2vPJ.js → config-schema-B6sPhXLp.js} +0 -0
  58. /package/dist/{directory-config-CW_JusGS.js → directory-config-mr3WFi1h.js} +0 -0
  59. /package/dist/{handle-action.guild-admin-DOW3XfEG.js → handle-action.guild-admin-DUVD8LGs.js} +0 -0
  60. /package/dist/{inbound-context-BdfOEkhj.js → inbound-context-CzEAvKgx.js} +0 -0
  61. /package/dist/{pluralkit-B2AqgTHV.js → pluralkit-BHV93ojA.js} +0 -0
  62. /package/dist/{preflight-audio.runtime-Drc-OFcp.js → preflight-audio.runtime-DT1Hmhsq.js} +0 -0
  63. /package/dist/{preview-streaming-CXTZydhx.js → preview-streaming-nClS_TQx.js} +0 -0
  64. /package/dist/{probe-CiBYm-vD.js → probe-DW9lJUZB.js} +0 -0
  65. /package/dist/{resolve-allowlist-common-DybgkAjk.js → resolve-allowlist-common-COuUtNM8.js} +0 -0
  66. /package/dist/{secret-config-contract-B3347_eU.js → secret-config-contract-57_WV6qt.js} +0 -0
  67. /package/dist/{security-contract-DyCRvz_Q.js → security-contract-BWDASKVo.js} +0 -0
  68. /package/dist/{security-doctor-Cp-NqNdS.js → security-doctor-DepqtNCI.js} +0 -0
  69. /package/dist/{sender-identity-BTGL3VbF.js → sender-identity-DC0FdEcU.js} +0 -0
  70. /package/dist/{session-contract-ugfEa9Xc.js → session-contract-Dwhw3RTY.js} +0 -0
  71. /package/dist/{session-key-normalization-B7h83qD2.js → session-key-normalization-DnCXUKGA.js} +0 -0
  72. /package/dist/{system-events-Bnit0zkQ.js → system-events-CEehp53f.js} +0 -0
  73. /package/dist/{thread-bindings.state-BdBeo7Rx.js → thread-bindings.state-CSphZOiL.js} +0 -0
  74. /package/dist/{timeouts-snXNwR4m.js → timeouts-CEwuGaWT.js} +0 -0
@@ -4,14 +4,15 @@ import { N as createDiscordRestClient, P as createDiscordRuntimeAccountContext,
4
4
  import { S as resolveTimestampMs, a as normalizeDiscordSlug, r as normalizeDiscordAllowList } from "./allow-list-CBI-M84K.js";
5
5
  import { a as removeReactionDiscord, f as editMessageDiscord, r as reactMessageDiscord } from "./send-CvXckvRn.js";
6
6
  import "./targets-DwW6OieO.js";
7
- import { t as resolveDiscordConversationIdentity } from "./conversation-identity-Dh8wIQ_K.js";
8
- import { t as DISCORD_TEXT_CHUNK_LIMIT } from "./outbound-adapter-Fe4Ee_GO.js";
9
- import { t as resolveDiscordPreviewStreamMode } from "./preview-streaming-CXTZydhx.js";
10
- import { n as DISCORD_ATTACHMENT_TOTAL_TIMEOUT_MS, t as DISCORD_ATTACHMENT_IDLE_TIMEOUT_MS } from "./timeouts-snXNwR4m.js";
11
- import { a as resolveReplyContext, i as buildGuildLabel, n as deliverDiscordReply, r as buildDirectLabel, x as resolveDiscordThreadStarter, y as resolveDiscordAutoThreadReplyPlan } from "./provider-B81nXBRc.js";
12
- import { a as resolveForwardedMediaList, o as resolveMediaList, r as resolveDiscordMessageText, s as resolveReferencedReplyMediaList } from "./message-utils-CY91O2k2.js";
13
- import { t as sendTyping } from "./typing-C_8U8J7E.js";
14
- import { n as buildDiscordInboundAccessContext, r as createDiscordSupplementalContextAccessChecker } from "./inbound-context-BdfOEkhj.js";
7
+ import { t as resolveDiscordConversationIdentity } from "./conversation-identity-Bpwp-7uO.js";
8
+ import { t as beginDiscordInboundEventDeliveryCorrelation } from "./inbound-event-delivery-D8zHG9Lz.js";
9
+ import { t as DISCORD_TEXT_CHUNK_LIMIT } from "./outbound-adapter-DyTqAH35.js";
10
+ import { t as resolveDiscordPreviewStreamMode } from "./preview-streaming-nClS_TQx.js";
11
+ import { n as DISCORD_ATTACHMENT_TOTAL_TIMEOUT_MS, t as DISCORD_ATTACHMENT_IDLE_TIMEOUT_MS } from "./timeouts-CEwuGaWT.js";
12
+ import { a as resolveReplyContext, i as buildGuildLabel, n as deliverDiscordReply, r as buildDirectLabel, x as resolveDiscordThreadStarter, y as resolveDiscordAutoThreadReplyPlan } from "./provider-BYIVfxV_.js";
13
+ import { a as resolveForwardedMediaList, o as resolveMediaList, r as resolveDiscordMessageText, s as resolveReferencedReplyMediaList } from "./message-utils-BZoXOhcI.js";
14
+ import { t as sendTyping } from "./typing-DudlJ-Fv.js";
15
+ import { n as buildDiscordInboundAccessContext, r as createDiscordSupplementalContextAccessChecker } from "./inbound-context-CzEAvKgx.js";
15
16
  import { buildAgentSessionKey, normalizeAccountId, resolveAccountEntry, resolveThreadSessionKeys } from "openclaw/plugin-sdk/routing";
16
17
  import { MessageFlags } from "discord-api-types/v10";
17
18
  import { evaluateSupplementalContextVisibility } from "openclaw/plugin-sdk/security-runtime";
@@ -29,12 +30,12 @@ import { EmbeddedBlockChunker, formatReasoningMessage, resolveAckReaction, resol
29
30
  import { truncateUtf16Safe } from "openclaw/plugin-sdk/text-utility-runtime";
30
31
  import { isDangerousNameMatchingEnabled } from "openclaw/plugin-sdk/dangerous-name-runtime";
31
32
  import { readSessionUpdatedAt, resolveStorePath } from "openclaw/plugin-sdk/session-store-runtime";
32
- import { buildChannelTurnContext, formatInboundEnvelope, resolveEnvelopeFormatOptions, toInboundMediaFacts } from "openclaw/plugin-sdk/channel-inbound";
33
+ import { buildChannelInboundEventContext, formatInboundEnvelope, resolveEnvelopeFormatOptions, toHistoryMediaEntries, toInboundMediaFacts } from "openclaw/plugin-sdk/channel-inbound";
33
34
  import { createFinalizableDraftLifecycle } from "openclaw/plugin-sdk/channel-lifecycle";
34
35
  import { hasFinalInboundReplyDispatch, recordChannelBotPairLoopAndCheckSuppression, runPreparedInboundReplyTurn } from "openclaw/plugin-sdk/inbound-reply-dispatch";
35
36
  import { DEFAULT_TIMING, createStatusReactionController, logAckFailure, logTypingFailure, shouldAckReaction } from "openclaw/plugin-sdk/channel-feedback";
36
- import { resolveChannelContextVisibilityMode } from "openclaw/plugin-sdk/context-visibility-runtime";
37
37
  import { createChannelHistoryWindow } from "openclaw/plugin-sdk/reply-history";
38
+ import { resolveChannelContextVisibilityMode } from "openclaw/plugin-sdk/context-visibility-runtime";
38
39
  //#region extensions/discord/src/monitor/ack-reactions.ts
39
40
  function createDiscordAckReactionContext(params) {
40
41
  return {
@@ -136,6 +137,7 @@ async function buildDiscordMessageProcessContext(params) {
136
137
  sessionKey: route.sessionKey
137
138
  });
138
139
  const channelHistory = createChannelHistoryWindow({ historyMap: guildHistories });
140
+ const isRoomEvent = ctx.inboundEventKind === "room_event";
139
141
  let combinedBody = formatInboundEnvelope({
140
142
  channel: "Discord",
141
143
  from: fromLabel,
@@ -146,7 +148,7 @@ async function buildDiscordMessageProcessContext(params) {
146
148
  previousTimestamp,
147
149
  envelope: envelopeOptions
148
150
  });
149
- const shouldIncludeChannelHistory = !isDirectMessage && !(isGuildMessage && channelConfig?.autoThread && !threadChannel);
151
+ const shouldIncludeChannelHistory = !isDirectMessage && (isRoomEvent || !(isGuildMessage && channelConfig?.autoThread && !threadChannel));
150
152
  if (shouldIncludeChannelHistory) combinedBody = channelHistory.buildPendingContext({
151
153
  historyKey: messageChannelId,
152
154
  limit: historyLimit,
@@ -238,7 +240,7 @@ async function buildDiscordMessageProcessContext(params) {
238
240
  message,
239
241
  messageChannelId,
240
242
  isGuildMessage,
241
- channelConfig,
243
+ channelConfig: isRoomEvent ? null : channelConfig,
242
244
  threadChannel,
243
245
  channelType: channelInfo?.type,
244
246
  channelName: channelInfo?.name,
@@ -276,7 +278,7 @@ async function buildDiscordMessageProcessContext(params) {
276
278
  storePath,
277
279
  sessionKey: effectiveSessionKey
278
280
  });
279
- const ctxPayload = buildChannelTurnContext({
281
+ const ctxPayload = buildChannelInboundEventContext({
280
282
  channel: "discord",
281
283
  provider: "discord",
282
284
  surface: "discord",
@@ -317,6 +319,7 @@ async function buildDiscordMessageProcessContext(params) {
317
319
  originatingTo
318
320
  },
319
321
  message: {
322
+ inboundEventKind: ctx.inboundEventKind,
320
323
  body: combinedBody,
321
324
  rawBody: preflightAudioTranscript ?? baseText,
322
325
  bodyForAgent: preflightAudioTranscript ?? baseText ?? text,
@@ -367,6 +370,18 @@ async function buildDiscordMessageProcessContext(params) {
367
370
  }
368
371
  });
369
372
  const persistedSessionKey = ctxPayload.SessionKey ?? route.sessionKey;
373
+ if (isRoomEvent && shouldIncludeChannelHistory) await channelHistory.recordWithMedia({
374
+ historyKey: messageChannelId,
375
+ limit: historyLimit,
376
+ entry: {
377
+ sender: senderName,
378
+ body: text,
379
+ timestamp: resolveTimestampMs(message.timestamp),
380
+ messageId: message.id
381
+ },
382
+ media: toHistoryMediaEntries(mediaList, { messageId: message.id }),
383
+ messageId: message.id
384
+ });
370
385
  if (shouldLogVerbose()) {
371
386
  const preview = truncateUtf16Safe(combinedBody, 200).replace(/\n/g, "\\n");
372
387
  logVerbose(`discord inbound: channel=${messageChannelId} deliver=${deliverTarget} from=${ctxPayload.From} preview="${preview}"`);
@@ -527,7 +542,8 @@ function createDiscordDraftPreviewController(params) {
527
542
  const discordStreamMode = resolveDiscordPreviewStreamMode(params.discordConfig);
528
543
  const draftMaxChars = Math.min(params.textLimit, 2e3);
529
544
  const accountBlockStreamingEnabled = resolveChannelStreamingBlockEnabled(params.discordConfig) ?? params.cfg.agents?.defaults?.blockStreamingDefault === "on";
530
- const draftStream = !params.sourceRepliesAreToolOnly && discordStreamMode !== "off" && !accountBlockStreamingEnabled ? createDiscordDraftStream({
545
+ const canStreamProgressDraftForToolOnlySource = params.sourceRepliesAreToolOnly && discordStreamMode === "progress";
546
+ const draftStream = (!params.sourceRepliesAreToolOnly || canStreamProgressDraftForToolOnlySource) && discordStreamMode !== "off" && !accountBlockStreamingEnabled ? createDiscordDraftStream({
531
547
  rest: params.deliveryRest,
532
548
  channelId: params.deliverChannelId,
533
549
  maxChars: draftMaxChars,
@@ -824,7 +840,10 @@ async function processDiscordMessage(ctx, observer) {
824
840
  const { createReplyDispatcherWithTyping, dispatchInboundMessage, settleReplyDispatcher } = await loadReplyRuntime();
825
841
  const sourceReplyDeliveryMode = resolveChannelMessageSourceReplyDeliveryMode({
826
842
  cfg,
827
- ctx: { ChatType: isGuildMessage ? "channel" : void 0 }
843
+ ctx: {
844
+ ChatType: isDirectMessage ? "direct" : isGroupDm ? "group" : isGuildMessage ? "channel" : void 0,
845
+ InboundEventKind: ctx.inboundEventKind
846
+ }
828
847
  });
829
848
  const sourceRepliesAreToolOnly = sourceReplyDeliveryMode === "message_tool_only";
830
849
  const ackReaction = resolveAckReaction(cfg, route.agentId, {
@@ -833,7 +852,8 @@ async function processDiscordMessage(ctx, observer) {
833
852
  });
834
853
  const removeAckAfterReply = cfg.messages?.removeAckAfterReply ?? false;
835
854
  const mediaLocalRoots = getAgentScopedMediaLocalRoots(cfg, route.agentId);
836
- const shouldAckReaction$1 = () => Boolean(ackReaction && shouldAckReaction({
855
+ const isRoomEvent = ctx.inboundEventKind === "room_event";
856
+ const shouldAckReaction$1 = () => Boolean(!isRoomEvent && ackReaction && shouldAckReaction({
837
857
  scope: ackReactionScope,
838
858
  isDirect: isDirectMessage,
839
859
  isGroup: isGuildMessage || isGroupDm,
@@ -845,7 +865,7 @@ async function processDiscordMessage(ctx, observer) {
845
865
  }));
846
866
  const shouldSendAckReaction = shouldAckReaction$1();
847
867
  const statusReactionsExplicitlyEnabled = cfg.messages?.statusReactions?.enabled === true;
848
- const statusReactionsEnabled = shouldSendAckReaction && cfg.messages?.statusReactions?.enabled !== false && (!sourceRepliesAreToolOnly || statusReactionsExplicitlyEnabled);
868
+ const statusReactionsEnabled = !isRoomEvent && shouldSendAckReaction && cfg.messages?.statusReactions?.enabled !== false && (!sourceRepliesAreToolOnly || statusReactionsExplicitlyEnabled);
849
869
  const feedbackRest = createDiscordRestClient({
850
870
  cfg,
851
871
  token,
@@ -993,6 +1013,19 @@ async function processDiscordMessage(ctx, observer) {
993
1013
  accountId
994
1014
  });
995
1015
  const chunkMode = resolveChunkMode(cfg, "discord", accountId);
1016
+ const clearGroupHistory = () => {
1017
+ if (isDirectMessage) return;
1018
+ createChannelHistoryWindow({ historyMap: guildHistories }).clear({
1019
+ historyKey: messageChannelId,
1020
+ limit: historyLimit
1021
+ });
1022
+ };
1023
+ const beginDeliveryCorrelation = () => isRoomEvent ? beginDiscordInboundEventDeliveryCorrelation(ctxPayload.SessionKey, {
1024
+ outboundTo: messageChannelId,
1025
+ outboundAccountId: route.accountId,
1026
+ markInboundEventDelivered: clearGroupHistory
1027
+ }, { inboundEventKind: ctxPayload.InboundEventKind }) : () => {};
1028
+ const endDiscordInboundEventDeliveryCorrelation = beginDeliveryCorrelation();
996
1029
  const deliverChannelId = deliverTarget.startsWith("channel:") ? deliverTarget.slice(8) : messageChannelId;
997
1030
  const draftPreview = createDiscordDraftPreviewController({
998
1031
  cfg,
@@ -1166,7 +1199,7 @@ async function processDiscordMessage(ctx, observer) {
1166
1199
  ctxPayload,
1167
1200
  recordInboundSession,
1168
1201
  record: turn.record,
1169
- history: {
1202
+ history: isRoomEvent ? void 0 : {
1170
1203
  isGroup: isGuildMessage,
1171
1204
  historyKey: messageChannelId,
1172
1205
  historyMap: guildHistories,
@@ -1182,6 +1215,9 @@ async function processDiscordMessage(ctx, observer) {
1182
1215
  abortSignal,
1183
1216
  skillFilter: channelConfig?.skills,
1184
1217
  sourceReplyDeliveryMode,
1218
+ queuedDeliveryCorrelations: isRoomEvent ? [{ begin: beginDeliveryCorrelation }] : void 0,
1219
+ suppressTyping: isRoomEvent ? true : void 0,
1220
+ allowProgressCallbacksWhenSourceDeliverySuppressed: sourceRepliesAreToolOnly && draftPreview.draftStream && draftPreview.isProgressMode ? true : void 0,
1185
1221
  disableBlockStreaming: sourceRepliesAreToolOnly ? true : draftPreview.disableBlockStreamingForDraft ?? (typeof resolvedBlockStreamingEnabled === "boolean" ? !resolvedBlockStreamingEnabled : void 0),
1186
1222
  onPartialReply: draftPreview.draftStream ? (payload) => draftPreview.updateFromPartial(payload.text) : void 0,
1187
1223
  onAssistantMessageStart: draftPreview.draftStream ? () => draftPreview.handleAssistantMessageBoundary() : void 0,
@@ -1289,6 +1325,7 @@ async function processDiscordMessage(ctx, observer) {
1289
1325
  dispatchError = true;
1290
1326
  throw err;
1291
1327
  } finally {
1328
+ endDiscordInboundEventDeliveryCorrelation();
1292
1329
  try {
1293
1330
  await draftPreview.cleanup();
1294
1331
  } finally {
@@ -1,5 +1,5 @@
1
- import { u as resolveDiscordChannelInfoSafe } from "./thread-bindings.discord-api-BtXi8-Fz.js";
2
- import { a as mergeAbortSignals } from "./timeouts-snXNwR4m.js";
1
+ import { u as resolveDiscordChannelInfoSafe } from "./thread-bindings.discord-api-BQJf05t-.js";
2
+ import { a as mergeAbortSignals } from "./timeouts-CEwuGaWT.js";
3
3
  import { normalizeLowercaseStringOrEmpty, normalizeOptionalString, normalizeOptionalStringifiedId } from "openclaw/plugin-sdk/string-coerce-runtime";
4
4
  import { ComponentType, StickerFormatType } from "discord-api-types/v10";
5
5
  import { saveRemoteMedia } from "openclaw/plugin-sdk/media-runtime";
@@ -1,6 +1,7 @@
1
1
  import { S as DiscordError, o as normalizeDiscordOutboundTarget, s as chunkDiscordTextWithMode, t as createDiscordSendReceipt } from "./send.receipt-nKLxvA1s.js";
2
2
  import { s as resolveDiscordAccount } from "./accounts-DnNVBDfc.js";
3
3
  import { d as readDiscordComponentSpec } from "./components-Cgm7XT8-.js";
4
+ import { n as notifyDiscordInboundEventOutboundPayloadSuccess } from "./inbound-event-delivery-D8zHG9Lz.js";
4
5
  import { normalizeLowercaseStringOrEmpty, normalizeOptionalString, normalizeOptionalStringifiedId } from "openclaw/plugin-sdk/string-coerce-runtime";
5
6
  import { resolvePayloadMediaUrls, sendPayloadMediaSequenceOrFallback, sendTextMediaPayload } from "openclaw/plugin-sdk/reply-payload";
6
7
  import { resolveRetryConfig, retryAsync } from "openclaw/plugin-sdk/retry-runtime";
@@ -313,7 +314,7 @@ function stripDiscordInternalRuntimeScaffolding(text) {
313
314
  }
314
315
  let discordThreadBindingsPromise;
315
316
  function loadDiscordThreadBindings() {
316
- discordThreadBindingsPromise ??= import("./thread-bindings-BwcE40jS.js").then((n) => n.t);
317
+ discordThreadBindingsPromise ??= import("./thread-bindings-CqKojFDg.js").then((n) => n.t);
317
318
  return discordThreadBindingsPromise;
318
319
  }
319
320
  function resolveDiscordWebhookIdentity(params) {
@@ -496,7 +497,15 @@ const discordOutbound = {
496
497
  })
497
498
  })
498
499
  }),
499
- afterDeliverPayload: async ({ target }) => {
500
+ afterDeliverPayload: async ({ target, payload }) => {
501
+ notifyDiscordInboundEventOutboundPayloadSuccess({
502
+ payload,
503
+ to: resolveDiscordOutboundTarget({
504
+ to: target.to,
505
+ threadId: target.threadId
506
+ }),
507
+ accountId: target.accountId
508
+ });
500
509
  const threadId = normalizeOptionalStringifiedId(target.threadId);
501
510
  if (!threadId) return;
502
511
  const { getThreadBindingManager } = await loadDiscordThreadBindings();
@@ -4,7 +4,7 @@ import { getFileExtension } from "openclaw/plugin-sdk/media-mime";
4
4
  //#region extensions/discord/src/monitor/preflight-audio.ts
5
5
  let discordPreflightAudioRuntimePromise;
6
6
  function loadDiscordPreflightAudioRuntime() {
7
- discordPreflightAudioRuntimePromise ??= import("./preflight-audio.runtime-Drc-OFcp.js");
7
+ discordPreflightAudioRuntimePromise ??= import("./preflight-audio.runtime-DT1Hmhsq.js");
8
8
  return discordPreflightAudioRuntimePromise;
9
9
  }
10
10
  const AUDIO_ATTACHMENT_MIME_BY_EXT = new Map([
@@ -1,2 +1,2 @@
1
- import { a as resolveDiscordPrivilegedIntentsFromFlags, i as probeDiscord, n as fetchDiscordApplicationSummary, r as parseApplicationIdFromToken, t as fetchDiscordApplicationId } from "./probe-CiBYm-vD.js";
1
+ import { a as resolveDiscordPrivilegedIntentsFromFlags, i as probeDiscord, n as fetchDiscordApplicationSummary, r as parseApplicationIdFromToken, t as fetchDiscordApplicationId } from "./probe-DW9lJUZB.js";
2
2
  export { fetchDiscordApplicationId, fetchDiscordApplicationSummary, parseApplicationIdFromToken, probeDiscord, resolveDiscordPrivilegedIntentsFromFlags };