@openclaw/slack 2026.8.1-beta.2 → 2026.8.1

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 (246) hide show
  1. package/dist/account-configured-sUohAxZr.js +33 -0
  2. package/dist/account-inspect-CN2hBsim.js +87 -0
  3. package/dist/account-inspect-api.js +1 -1
  4. package/dist/{accounts-CK4AVI2_.js → accounts-Dm_H77gH.js} +12 -11
  5. package/dist/{accounts.runtime-Cb7QwWBz.js → accounts.runtime-DRuEK6mL.js} +1 -1
  6. package/dist/{action-runtime-BkGe7ny_.js → action-runtime-044ldvNL.js} +80 -79
  7. package/dist/action-runtime.runtime-BL3KzX13.js +2 -0
  8. package/dist/{actions-BTDXwwE3.js → actions-BI7JkfVm.js} +273 -263
  9. package/dist/api.js +14 -14
  10. package/dist/{approval-handler.runtime-CJaNzAq2.js → approval-handler.runtime-DYv0UIZS.js} +53 -174
  11. package/dist/{channel-D_tovcUL.js → channel-1vIJOzPx.js} +134 -160
  12. package/dist/channel-config-api.js +1 -1
  13. package/dist/channel-plugin-api.js +1 -1
  14. package/dist/{channel-type-B9MSdoGN.js → channel-type-DlFSKeIZ.js} +3 -7
  15. package/dist/{channel.setup-Bch9dYmA.js → channel.setup-ofDi3_Pu.js} +34 -49
  16. package/dist/{config-schema-xto5jFIx.js → config-schema-BVIMyiDN.js} +42 -19
  17. package/dist/configured-state.js +34 -0
  18. package/dist/conversation-binding-route-DFVLUdYF.js +115 -0
  19. package/dist/{directory-config-CNBz8lJa.js → directory-config-DqfQ42OV.js} +1 -1
  20. package/dist/directory-contract-api.js +1 -1
  21. package/dist/{directory-live-CFKUtW9E.js → directory-live-BPaNHjmP.js} +2 -2
  22. package/dist/{group-policy-c4RP9bjc.js → group-policy-BdwszjYn.js} +625 -773
  23. package/dist/{message-tool-api-BykQB4AU.js → message-tool-api-CJ0kjcg5.js} +23 -5
  24. package/dist/message-tool-api.js +1 -1
  25. package/dist/{monitor-1nF1NtqT.js → monitor-Dq5Cmrvp.js} +3 -3
  26. package/dist/{outbound-adapter-S81tsswN.js → outbound-adapter-DYaI8ThX.js} +101 -66
  27. package/dist/{pipeline.runtime-BvYsM5JO.js → pipeline.runtime-Bd22U0ga.js} +494 -474
  28. package/dist/{policy-TapwbeaT.js → policy-CtQVbde1.js} +2 -1
  29. package/dist/{probe-HoEg_WxB.js → probe-0usmAb0i.js} +209 -22
  30. package/dist/{provider-CDNvBXUi.js → provider-CN_8hFv2.js} +296 -178
  31. package/dist/{relay-source-C9leF11u.js → relay-source-BNGpsdwV.js} +1 -1
  32. package/dist/{replies-CeOfv82I.js → replies-BSiRQOJ1.js} +48 -27
  33. package/dist/{resolve-channels-CNPrxaXY.js → resolve-channels-Czheznc8.js} +1 -1
  34. package/dist/{resolve-users-Dzomuwnr.js → resolve-users-BAOlNimr.js} +1 -1
  35. package/dist/runtime-api.js +11 -11
  36. package/dist/{scopes-cYXKkrRD.js → scopes-COSlmhnH.js} +1 -1
  37. package/dist/security-contract-api.js +1 -1
  38. package/dist/{send-Nor0iBwY.js → send-DS9ICrBI.js} +88 -100
  39. package/dist/send-results-eeOu_HYm.js +23 -0
  40. package/dist/{send.runtime-BmgNe6S9.js → send.runtime-D_Bb6IuH.js} +1 -1
  41. package/dist/setup-plugin-api.js +1 -1
  42. package/dist/{setup-surface-CbX1-Knh.js → setup-surface-BGnd2pSe.js} +6 -6
  43. package/dist/{shared-zdT5AMp-.js → shared-D5B-5hBg.js} +35 -9
  44. package/dist/{slash-dispatch.runtime-Bnr9GR1S.js → slash-dispatch.runtime-CilDmI0c.js} +2 -2
  45. package/node_modules/@slack/bolt/node_modules/@types/node/README.md +1 -1
  46. package/node_modules/@slack/bolt/node_modules/@types/node/child_process.d.ts +0 -1
  47. package/node_modules/@slack/bolt/node_modules/@types/node/crypto.d.ts +6 -6
  48. package/node_modules/@slack/bolt/node_modules/@types/node/dns/promises.d.ts +5 -5
  49. package/node_modules/@slack/bolt/node_modules/@types/node/dns.d.ts +5 -5
  50. package/node_modules/@slack/bolt/node_modules/@types/node/fs.d.ts +7 -0
  51. package/node_modules/@slack/bolt/node_modules/@types/node/http.d.ts +30 -0
  52. package/node_modules/@slack/bolt/node_modules/@types/node/http2.d.ts +4 -4
  53. package/node_modules/@slack/bolt/node_modules/@types/node/os.d.ts +30 -30
  54. package/node_modules/@slack/bolt/node_modules/@types/node/package.json +2 -2
  55. package/node_modules/@slack/bolt/node_modules/@types/node/perf_hooks.d.ts +2 -1
  56. package/node_modules/@slack/bolt/node_modules/@types/node/process.d.ts +42 -43
  57. package/node_modules/@slack/bolt/node_modules/@types/node/quic.d.ts +1049 -84
  58. package/node_modules/@slack/bolt/node_modules/@types/node/sqlite.d.ts +14 -1
  59. package/node_modules/@slack/bolt/node_modules/@types/node/stream/iter.d.ts +3 -2
  60. package/node_modules/@slack/bolt/node_modules/@types/node/test.d.ts +61 -0
  61. package/node_modules/@slack/bolt/node_modules/@types/node/v8.d.ts +20 -23
  62. package/node_modules/@slack/bolt/node_modules/body-parser/node_modules/content-type/README.md +2 -0
  63. package/node_modules/@slack/bolt/node_modules/body-parser/node_modules/content-type/dist/index.d.ts +20 -0
  64. package/node_modules/@slack/bolt/node_modules/body-parser/node_modules/content-type/dist/index.js +20 -14
  65. package/node_modules/@slack/bolt/node_modules/body-parser/node_modules/content-type/dist/index.js.map +1 -1
  66. package/node_modules/@slack/bolt/node_modules/body-parser/node_modules/content-type/package.json +1 -1
  67. package/node_modules/@slack/bolt/node_modules/type-is/node_modules/content-type/README.md +2 -0
  68. package/node_modules/@slack/bolt/node_modules/type-is/node_modules/content-type/dist/index.d.ts +20 -0
  69. package/node_modules/@slack/bolt/node_modules/type-is/node_modules/content-type/dist/index.js +20 -14
  70. package/node_modules/@slack/bolt/node_modules/type-is/node_modules/content-type/dist/index.js.map +1 -1
  71. package/node_modules/@slack/bolt/node_modules/type-is/node_modules/content-type/package.json +1 -1
  72. package/node_modules/@slack/socket-mode/node_modules/@types/node/README.md +1 -1
  73. package/node_modules/@slack/socket-mode/node_modules/@types/node/child_process.d.ts +0 -1
  74. package/node_modules/@slack/socket-mode/node_modules/@types/node/crypto.d.ts +6 -6
  75. package/node_modules/@slack/socket-mode/node_modules/@types/node/dns/promises.d.ts +5 -5
  76. package/node_modules/@slack/socket-mode/node_modules/@types/node/dns.d.ts +5 -5
  77. package/node_modules/@slack/socket-mode/node_modules/@types/node/fs.d.ts +7 -0
  78. package/node_modules/@slack/socket-mode/node_modules/@types/node/http.d.ts +30 -0
  79. package/node_modules/@slack/socket-mode/node_modules/@types/node/http2.d.ts +4 -4
  80. package/node_modules/@slack/socket-mode/node_modules/@types/node/os.d.ts +30 -30
  81. package/node_modules/@slack/socket-mode/node_modules/@types/node/package.json +2 -2
  82. package/node_modules/@slack/socket-mode/node_modules/@types/node/perf_hooks.d.ts +2 -1
  83. package/node_modules/@slack/socket-mode/node_modules/@types/node/process.d.ts +42 -43
  84. package/node_modules/@slack/socket-mode/node_modules/@types/node/quic.d.ts +1049 -84
  85. package/node_modules/@slack/socket-mode/node_modules/@types/node/sqlite.d.ts +14 -1
  86. package/node_modules/@slack/socket-mode/node_modules/@types/node/stream/iter.d.ts +3 -2
  87. package/node_modules/@slack/socket-mode/node_modules/@types/node/test.d.ts +61 -0
  88. package/node_modules/@slack/socket-mode/node_modules/@types/node/v8.d.ts +20 -23
  89. package/node_modules/@slack/web-api/node_modules/@types/node/README.md +1 -1
  90. package/node_modules/@slack/web-api/node_modules/@types/node/child_process.d.ts +0 -1
  91. package/node_modules/@slack/web-api/node_modules/@types/node/crypto.d.ts +6 -6
  92. package/node_modules/@slack/web-api/node_modules/@types/node/dns/promises.d.ts +5 -5
  93. package/node_modules/@slack/web-api/node_modules/@types/node/dns.d.ts +5 -5
  94. package/node_modules/@slack/web-api/node_modules/@types/node/fs.d.ts +7 -0
  95. package/node_modules/@slack/web-api/node_modules/@types/node/http.d.ts +30 -0
  96. package/node_modules/@slack/web-api/node_modules/@types/node/http2.d.ts +4 -4
  97. package/node_modules/@slack/web-api/node_modules/@types/node/os.d.ts +30 -30
  98. package/node_modules/@slack/web-api/node_modules/@types/node/package.json +2 -2
  99. package/node_modules/@slack/web-api/node_modules/@types/node/perf_hooks.d.ts +2 -1
  100. package/node_modules/@slack/web-api/node_modules/@types/node/process.d.ts +42 -43
  101. package/node_modules/@slack/web-api/node_modules/@types/node/quic.d.ts +1049 -84
  102. package/node_modules/@slack/web-api/node_modules/@types/node/sqlite.d.ts +14 -1
  103. package/node_modules/@slack/web-api/node_modules/@types/node/stream/iter.d.ts +3 -2
  104. package/node_modules/@slack/web-api/node_modules/@types/node/test.d.ts +61 -0
  105. package/node_modules/@slack/web-api/node_modules/@types/node/v8.d.ts +20 -23
  106. package/node_modules/typebox/build/format/date.d.mts +1 -1
  107. package/node_modules/typebox/build/format/date.mjs +1 -1
  108. package/node_modules/typebox/build/format/date_time.d.mts +2 -2
  109. package/node_modules/typebox/build/format/date_time.mjs +3 -3
  110. package/node_modules/typebox/build/format/email.d.mts +1 -1
  111. package/node_modules/typebox/build/format/email.mjs +2 -2
  112. package/node_modules/typebox/build/format/hostname.mjs +2 -10
  113. package/node_modules/typebox/build/format/idn_email.d.mts +1 -1
  114. package/node_modules/typebox/build/format/idn_email.mjs +3 -3
  115. package/node_modules/typebox/build/format/idn_hostname.d.mts +1 -0
  116. package/node_modules/typebox/build/format/idn_hostname.mjs +3 -11
  117. package/node_modules/typebox/build/format/idna/format/bidi.d.mts +3 -0
  118. package/node_modules/typebox/build/format/idna/format/bidi.mjs +98 -0
  119. package/node_modules/typebox/build/format/idna/format/puny.d.mts +3 -0
  120. package/node_modules/typebox/build/format/idna/format/puny.mjs +144 -0
  121. package/node_modules/typebox/build/format/idna/hostname.d.mts +1 -0
  122. package/node_modules/typebox/build/format/idna/hostname.mjs +16 -0
  123. package/node_modules/typebox/build/format/idna/idn-hostname.d.mts +1 -0
  124. package/node_modules/typebox/build/format/idna/idn-hostname.mjs +23 -0
  125. package/node_modules/typebox/build/format/idna/index.d.mts +2 -0
  126. package/node_modules/typebox/build/format/idna/index.mjs +2 -0
  127. package/node_modules/typebox/build/format/idna/label/ascii.d.mts +1 -0
  128. package/node_modules/typebox/build/format/idna/label/ascii.mjs +9 -0
  129. package/node_modules/typebox/build/format/idna/label/puny.d.mts +1 -0
  130. package/node_modules/typebox/build/format/idna/label/puny.mjs +28 -0
  131. package/node_modules/typebox/build/format/idna/label/unicode.d.mts +1 -0
  132. package/node_modules/typebox/build/format/idna/label/unicode.mjs +106 -0
  133. package/node_modules/typebox/build/format/idna/pattern/pattern.d.mts +30 -0
  134. package/node_modules/typebox/build/format/idna/pattern/pattern.mjs +70 -0
  135. package/node_modules/typebox/build/format/ipv4.d.mts +0 -1
  136. package/node_modules/typebox/build/format/ipv4.mjs +2 -32
  137. package/node_modules/typebox/build/format/ipv6.mjs +2 -61
  138. package/node_modules/typebox/build/format/iri.d.mts +2 -2
  139. package/node_modules/typebox/build/format/iri.mjs +26 -8
  140. package/node_modules/typebox/build/format/iri_reference.d.mts +2 -2
  141. package/node_modules/typebox/build/format/iri_reference.mjs +9 -55
  142. package/node_modules/typebox/build/format/regex.d.mts +1 -2
  143. package/node_modules/typebox/build/format/regex.mjs +2 -6
  144. package/node_modules/typebox/build/format/time.d.mts +2 -2
  145. package/node_modules/typebox/build/format/time.mjs +19 -14
  146. package/node_modules/typebox/build/format/uri.d.mts +1 -1
  147. package/node_modules/typebox/build/format/uri.mjs +3 -130
  148. package/node_modules/typebox/build/format/uri_reference.d.mts +1 -1
  149. package/node_modules/typebox/build/format/uri_reference.mjs +2 -3
  150. package/node_modules/typebox/build/format/uri_template.d.mts +2 -3
  151. package/node_modules/typebox/build/format/uri_template.mjs +4 -5
  152. package/node_modules/typebox/build/format/url.d.mts +3 -3
  153. package/node_modules/typebox/build/format/url.mjs +4 -5
  154. package/node_modules/typebox/build/guard/emit.d.mts +3 -1
  155. package/node_modules/typebox/build/guard/emit.mjs +12 -5
  156. package/node_modules/typebox/build/guard/guard.d.mts +8 -2
  157. package/node_modules/typebox/build/guard/guard.mjs +25 -4
  158. package/node_modules/typebox/build/guard/string.d.mts +2 -2
  159. package/node_modules/typebox/build/guard/string.mjs +7 -7
  160. package/node_modules/typebox/build/schema/engine/_context.mjs +3 -3
  161. package/node_modules/typebox/build/schema/engine/_functions.mjs +1 -2
  162. package/node_modules/typebox/build/schema/engine/_regexp.d.mts +2 -0
  163. package/node_modules/typebox/build/schema/engine/_regexp.mjs +4 -0
  164. package/node_modules/typebox/build/schema/engine/_stack.mjs +12 -13
  165. package/node_modules/typebox/build/schema/engine/additionalItems.mjs +17 -7
  166. package/node_modules/typebox/build/schema/engine/additionalProperties.mjs +4 -3
  167. package/node_modules/typebox/build/schema/engine/contains.mjs +18 -6
  168. package/node_modules/typebox/build/schema/engine/enum.mjs +1 -1
  169. package/node_modules/typebox/build/schema/engine/items.mjs +26 -6
  170. package/node_modules/typebox/build/schema/engine/maxContains.mjs +3 -3
  171. package/node_modules/typebox/build/schema/engine/minContains.mjs +14 -4
  172. package/node_modules/typebox/build/schema/engine/not.mjs +4 -2
  173. package/node_modules/typebox/build/schema/engine/oneOf.mjs +7 -6
  174. package/node_modules/typebox/build/schema/engine/pattern.mjs +3 -2
  175. package/node_modules/typebox/build/schema/engine/patternProperties.mjs +4 -3
  176. package/node_modules/typebox/build/schema/engine/ref.mjs +1 -7
  177. package/node_modules/typebox/build/schema/engine/schema.mjs +13 -4
  178. package/node_modules/typebox/build/schema/engine/type.mjs +1 -1
  179. package/node_modules/typebox/build/schema/resolve/resolve.d.mts +4 -1
  180. package/node_modules/typebox/build/schema/resolve/resolve.mjs +202 -1
  181. package/node_modules/typebox/build/schema/static/propertyNames.d.mts +5 -0
  182. package/node_modules/typebox/build/schema/static/propertyNames.mjs +3 -0
  183. package/node_modules/typebox/build/schema/static/schema.d.mts +3 -0
  184. package/node_modules/typebox/build/schema/types/index.d.mts +0 -2
  185. package/node_modules/typebox/build/schema/types/index.mjs +0 -2
  186. package/node_modules/typebox/build/system/memory/clone.mjs +14 -11
  187. package/node_modules/typebox/build/system/memory/discard.mjs +6 -5
  188. package/node_modules/typebox/build/system/settings/settings.d.mts +9 -0
  189. package/node_modules/typebox/build/system/settings/settings.mjs +2 -0
  190. package/node_modules/typebox/build/type/engine/call/distribute_arguments.d.mts +6 -1
  191. package/node_modules/typebox/build/type/engine/call/distribute_arguments.mjs +16 -3
  192. package/node_modules/typebox/build/type/engine/call/instantiate.mjs +34 -4
  193. package/node_modules/typebox/build/type/engine/evaluate/broaden.d.mts +5 -5
  194. package/node_modules/typebox/build/type/engine/evaluate/broaden.mjs +20 -26
  195. package/node_modules/typebox/build/type/engine/evaluate/compare.d.mts +6 -10
  196. package/node_modules/typebox/build/type/engine/evaluate/compare.mjs +9 -13
  197. package/node_modules/typebox/build/type/engine/evaluate/composite.d.mts +7 -4
  198. package/node_modules/typebox/build/type/engine/evaluate/composite.mjs +12 -19
  199. package/node_modules/typebox/build/type/engine/evaluate/distribute.d.mts +4 -20
  200. package/node_modules/typebox/build/type/engine/evaluate/distribute.mjs +8 -20
  201. package/node_modules/typebox/build/type/engine/evaluate/evaluate.d.mts +4 -4
  202. package/node_modules/typebox/build/type/engine/evaluate/evaluate.mjs +11 -8
  203. package/node_modules/typebox/build/type/engine/evaluate/flatten.d.mts +1 -1
  204. package/node_modules/typebox/build/type/engine/evaluate/flatten.mjs +3 -4
  205. package/node_modules/typebox/build/type/engine/evaluate/narrow.d.mts +17 -2
  206. package/node_modules/typebox/build/type/engine/evaluate/narrow.mjs +26 -6
  207. package/node_modules/typebox/build/type/engine/exclude/operation.mjs +3 -4
  208. package/node_modules/typebox/build/type/engine/extract/operation.d.mts +1 -1
  209. package/node_modules/typebox/build/type/engine/extract/operation.mjs +3 -4
  210. package/node_modules/typebox/build/type/engine/priority/priority.d.mts +2 -2
  211. package/node_modules/typebox/build/type/engine/priority/priority.mjs +3 -4
  212. package/node_modules/typebox/build/type/script/mapping.d.mts +32 -29
  213. package/node_modules/typebox/build/type/script/mapping.mjs +18 -25
  214. package/node_modules/typebox/build/type/script/parser.d.mts +19 -25
  215. package/node_modules/typebox/build/type/script/parser.mjs +27 -23
  216. package/node_modules/typebox/build/value/errors/errors.d.mts +2 -2
  217. package/node_modules/typebox/build/value/errors/errors.mjs +1 -1
  218. package/node_modules/typebox/package.json +27 -27
  219. package/node_modules/typebox/readme.md +79 -82
  220. package/node_modules/ws/lib/permessage-deflate.js +3 -1
  221. package/node_modules/ws/package.json +1 -1
  222. package/openclaw.plugin.json +57 -7
  223. package/package.json +9 -9
  224. package/dist/account-configured-BwfXBo_F.js +0 -14
  225. package/dist/account-inspect-Drw2gAiN.js +0 -89
  226. package/dist/account-reply-mode-DrUXogvO.js +0 -14
  227. package/dist/action-runtime.runtime-D9I6uc0Q.js +0 -2
  228. package/dist/actions.runtime-DLFyUkvg.js +0 -2
  229. package/dist/block-text-YtiNkqmx.js +0 -79
  230. package/dist/runtime-api-Cj9nxBNv.js +0 -10
  231. package/node_modules/p-map/index.d.ts +0 -155
  232. package/node_modules/p-map/index.js +0 -285
  233. package/node_modules/p-map/license +0 -9
  234. package/node_modules/p-map/package.json +0 -57
  235. package/node_modules/p-map/readme.md +0 -190
  236. package/node_modules/typebox/build/format/_idna.d.mts +0 -2
  237. package/node_modules/typebox/build/format/_idna.mjs +0 -246
  238. package/node_modules/typebox/build/format/_puny.d.mts +0 -1
  239. package/node_modules/typebox/build/format/_puny.mjs +0 -77
  240. package/node_modules/typebox/build/schema/resolve/ref.d.mts +0 -3
  241. package/node_modules/typebox/build/schema/resolve/ref.mjs +0 -146
  242. package/node_modules/typebox/build/schema/types/contentEncoding.d.mts +0 -9
  243. package/node_modules/typebox/build/schema/types/contentEncoding.mjs +0 -13
  244. package/node_modules/typebox/build/schema/types/contentMediaType.d.mts +0 -9
  245. package/node_modules/typebox/build/schema/types/contentMediaType.mjs +0 -13
  246. package/dist/{security-audit-DR097212.js → security-audit-B_yKr7MW.js} +1 -1
@@ -1,5 +1,5 @@
1
- import { n as listSlackAccountIds } from "./accounts-CK4AVI2_.js";
2
- import { t as inspectSlackAccount } from "./account-inspect-Drw2gAiN.js";
1
+ import { n as listSlackAccountIds } from "./accounts-Dm_H77gH.js";
2
+ import { t as inspectSlackAccount } from "./account-inspect-CN2hBsim.js";
3
3
  import { n as resolveSlackThreadTsValue, t as normalizeSlackThreadTsCandidate } from "./thread-ts-DUGhaYKq.js";
4
4
  import { createActionGate } from "openclaw/plugin-sdk/channel-actions";
5
5
  import { extractToolSend } from "openclaw/plugin-sdk/tool-send";
@@ -24,6 +24,7 @@ function listSlackMessageActions(cfg, accountId) {
24
24
  actions.add("reactions");
25
25
  }
26
26
  if (isActionEnabled("messages")) {
27
+ actions.add("conversation-open");
27
28
  actions.add("read");
28
29
  actions.add("edit");
29
30
  actions.add("delete");
@@ -71,8 +72,9 @@ const SLACK_MESSAGE_ID_ACTIONS = [
71
72
  function createSlackFileActionSchema() {
72
73
  return { fileId: Type.Optional(Type.String({ description: "Slack file id, starting with \"F\" (for example F0B0LTT8M36). Required for action=\"download-file\". Read it from inbound Slack file metadata at event.files[].id. This is not the Slack message timestamp/messageId." })) };
73
74
  }
74
- function createSlackReactionEmojiSchema() {
75
- return { emoji: Type.Optional(Type.String({ description: "Slack emoji shortcode name (for example \"white_check_mark\" or \"+1\") or common emoji character (for example \"✅\"). Colons are optional around shortcodes." })) };
75
+ function createSlackReactionEmojiSchema(emojiListAvailable) {
76
+ const discoveryHint = emojiListAvailable ? " Discover workspace custom emoji with action:\"emoji-list\"." : "";
77
+ return { emoji: Type.Optional(Type.String({ description: "Slack standard or workspace custom emoji shortcode (for example \"white_check_mark\" or \"+1\") or common emoji character (for example \"✅\"). Colons are optional." + discoveryHint })) };
76
78
  }
77
79
  function createSlackForcedMediaSchema() {
78
80
  const description = "Preserve original image bytes without image optimization. Slack still uploads a regular file; this does not convert it into a Slack document.";
@@ -105,6 +107,22 @@ function describeSlackMessageTool({ cfg, accountId }) {
105
107
  const actions = listSlackMessageActions(cfg, accountId);
106
108
  const capabilities = /* @__PURE__ */ new Set();
107
109
  const schema = [];
110
+ if (actions.includes("conversation-open")) schema.push({
111
+ actions: ["conversation-open"],
112
+ visibility: "all-configured",
113
+ properties: {
114
+ userIds: Type.Optional(Type.Array(Type.String({ pattern: "^[UW][A-Z0-9]+$" }), {
115
+ minItems: 1,
116
+ maxItems: 8,
117
+ uniqueItems: true,
118
+ description: "Slack conversation-open: 1-8 other member IDs. One opens a DM; multiple open or reuse a group DM. Exclude the calling account. Use the returned target with action=\"send\"."
119
+ })),
120
+ teamId: Type.Optional(Type.String({
121
+ pattern: "^T[A-Z0-9]+$",
122
+ description: "Slack workspace for conversation-open. Defaults to the trusted current workspace for the selected account; required for detached Enterprise operations."
123
+ }))
124
+ }
125
+ });
108
126
  if (actions.includes("send")) capabilities.add("presentation");
109
127
  if (actions.includes("download-file")) schema.push({
110
128
  properties: createSlackFileActionSchema(),
@@ -119,7 +137,7 @@ function describeSlackMessageTool({ cfg, accountId }) {
119
137
  actions: ["upload-file"]
120
138
  });
121
139
  if (actions.includes("react")) schema.push({
122
- properties: createSlackReactionEmojiSchema(),
140
+ properties: createSlackReactionEmojiSchema(actions.includes("emoji-list")),
123
141
  actions: ["react", "reactions"]
124
142
  });
125
143
  const messageIdActions = [];
@@ -1,2 +1,2 @@
1
- import { t as describeSlackMessageTool } from "./message-tool-api-BykQB4AU.js";
1
+ import { t as describeSlackMessageTool } from "./message-tool-api-CJ0kjcg5.js";
2
2
  export { describeSlackMessageTool as describeMessageTool };
@@ -1,7 +1,7 @@
1
1
  import { t as __exportAll } from "./rolldown-runtime-8H4AJuhK.js";
2
- import { E as buildSlackSlashCommandMatcher, t as monitorSlackProvider } from "./provider-CDNvBXUi.js";
3
- import { t as isSlackChannelAllowedByPolicy } from "./policy-TapwbeaT.js";
4
- import { o as resolveSlackThreadTs } from "./replies-CeOfv82I.js";
2
+ import { T as buildSlackSlashCommandMatcher, t as monitorSlackProvider } from "./provider-CN_8hFv2.js";
3
+ import { t as isSlackChannelAllowedByPolicy } from "./policy-CtQVbde1.js";
4
+ import { o as resolveSlackThreadTs } from "./replies-BSiRQOJ1.js";
5
5
  //#region extensions/slack/src/monitor.ts
6
6
  var monitor_exports = /* @__PURE__ */ __exportAll({
7
7
  buildSlackSlashCommandMatcher: () => buildSlackSlashCommandMatcher,
@@ -1,15 +1,27 @@
1
+ import { a as resolveSlackAccount, l as resolveSlackOperationToken } from "./accounts-Dm_H77gH.js";
1
2
  import { a as parseSlackTarget } from "./target-parsing-BnMD2ZqZ.js";
2
- import { B as SLACK_TEXT_LIMIT, I as resolveSlackAuthoredTextPlacement, at as escapeSlackMrkdwn, g as resolveSlackReplyBlockResolution, h as parseSlackReplyBlockSegments, q as SLACK_QUESTION_FINALIZATION_BLOCKS, st as SLACK_PRESENTATION_CAPABILITIES, tt as resolveSlackQuestionActionIds, v as resolveSlackReplyDeliveryMessages } from "./group-policy-c4RP9bjc.js";
3
+ import { M as SLACK_TEXT_LIMIT, O as resolveSlackAuthoredTextPlacement, c as assertSlackDetachedTargetAllowed, d as resolveSlackReplyBlockResolution, et as escapeSlackMrkdwn, p as resolveSlackReplyDeliveryMessages, q as resolveSlackQuestionActionIds, rt as SLACK_PRESENTATION_CAPABILITIES, u as parseSlackReplyBlockSegments, z as SLACK_QUESTION_FINALIZATION_BLOCKS } from "./group-policy-BdwszjYn.js";
3
4
  import { n as resolveSlackThreadTsValue } from "./thread-ts-DUGhaYKq.js";
5
+ import { t as mergeSlackSendResults } from "./send-results-eeOu_HYm.js";
4
6
  import { normalizeOptionalString } from "openclaw/plugin-sdk/string-coerce-runtime";
5
7
  import { resolveOutboundSendDep } from "openclaw/plugin-sdk/channel-outbound";
6
8
  import { createLazyRuntimeModule } from "openclaw/plugin-sdk/lazy-runtime";
7
9
  import { normalizeMessagePresentation, resolveLegacyInteractiveTextFallback } from "openclaw/plugin-sdk/interactive-runtime";
10
+ import { resolvePayloadMediaUrls, sendPayloadMediaSequenceAndFinalize, sendTextMediaPayload } from "openclaw/plugin-sdk/reply-payload";
8
11
  import { questionGatewayRuntime } from "openclaw/plugin-sdk/question-gateway-runtime";
9
12
  import { createHmac, randomBytes, timingSafeEqual } from "node:crypto";
10
- import { resolvePayloadMediaUrls, sendPayloadMediaSequenceAndFinalize, sendTextMediaPayload } from "openclaw/plugin-sdk/reply-payload";
11
- import { attachChannelToResult, createAttachedChannelResultAdapter } from "openclaw/plugin-sdk/channel-send-result";
13
+ import { attachChannelToResult } from "openclaw/plugin-sdk/channel-send-result";
12
14
  //#region extensions/slack/src/outbound-adapter.ts
15
+ function toSlackOutboundResult(result) {
16
+ const { channelId, ...delivery } = result;
17
+ return attachChannelToResult("slack", channelId === void 0 ? delivery : {
18
+ ...delivery,
19
+ target: {
20
+ kind: "channel",
21
+ id: channelId
22
+ }
23
+ });
24
+ }
13
25
  const SLACK_RENDERED_PRESENTATION_PROVENANCE_KEY = randomBytes(32);
14
26
  function createSlackRenderedPresentationProvenance(resolution) {
15
27
  return createHmac("sha256", SLACK_RENDERED_PRESENTATION_PROVENANCE_KEY).update(JSON.stringify([resolution.authoredTextPlacement, resolution.segments])).digest("base64url");
@@ -39,7 +51,7 @@ function readSlackRenderedPresentation(slackData) {
39
51
  return;
40
52
  }
41
53
  }
42
- const loadSlackSendRuntime = createLazyRuntimeModule(() => import("./send.runtime-BmgNe6S9.js"));
54
+ const loadSlackSendRuntime = createLazyRuntimeModule(() => import("./send.runtime-D_Bb6IuH.js"));
43
55
  function resolveSlackSendIdentity(identity) {
44
56
  if (!identity) return;
45
57
  const username = normalizeOptionalString(identity.name);
@@ -87,43 +99,45 @@ function withSlackRenderedPresentation(payload, slackData, resolution) {
87
99
  function readSlackAuthoredTextPlacement(value) {
88
100
  return value === "none" || value === "blocks" || value === "outside-blocks" ? value : void 0;
89
101
  }
90
- async function sendSlackOutboundMessage(params) {
91
- const send = resolveOutboundSendDep(params.deps, "slack") ?? (await loadSlackSendRuntime()).sendMessageSlack;
92
- const slackIdentity = resolveSlackSendIdentity(params.identity);
93
- const threadTs = resolveSlackThreadTsValue({
94
- replyToId: params.replyToId,
95
- threadId: params.threadId
102
+ async function prepareSlackOutboundSend(ctx) {
103
+ const account = resolveSlackAccount({
104
+ cfg: ctx.cfg,
105
+ accountId: ctx.accountId
96
106
  });
97
- const sendOptions = {
98
- cfg: params.cfg,
99
- threadTs,
100
- accountId: params.accountId ?? void 0,
101
- ...params.mediaUrl ? {
102
- mediaUrl: params.mediaUrl,
103
- mediaAccess: params.mediaAccess,
104
- mediaLocalRoots: params.mediaLocalRoots,
105
- mediaReadFile: params.mediaReadFile,
106
- ...params.forceDocument ? { forceDocument: true } : {}
107
- } : {},
108
- ...params.blocks ? { blocks: params.blocks } : {},
109
- ...params.authoredTextPlacement ? { authoredTextPlacement: params.authoredTextPlacement } : {},
110
- ...Object.hasOwn(params, "nativeDataFallbackBaseText") ? { nativeDataFallbackBaseText: params.nativeDataFallbackBaseText } : {},
111
- ...params.textIsSlackPlainText ? { textIsSlackPlainText: true } : {},
112
- ...slackIdentity ? { identity: slackIdentity } : {},
113
- ...params.deliveryQueueId ? { deliveryQueueId: params.deliveryQueueId } : {},
114
- ...params.onPlatformSendDispatch ? { onPlatformSendDispatch: params.onPlatformSendDispatch } : {},
115
- ...params.onDeliveryResult ? { onDeliveryResult: async (progress) => {
116
- await params.onDeliveryResult?.(attachChannelToResult("slack", progress));
117
- } } : {}
107
+ const target = parseSlackTarget(ctx.to, { defaultKind: "channel" });
108
+ assertSlackDetachedTargetAllowed(account.accountId, target?.teamId);
109
+ const send = resolveOutboundSendDep(ctx.deps, "slack") ?? (await loadSlackSendRuntime()).sendMessageSlack;
110
+ const token = resolveSlackOperationToken(account, "write");
111
+ const botToken = account.botToken?.trim();
112
+ const tokenOverride = token && token !== botToken ? token : void 0;
113
+ return async (params) => {
114
+ const slackIdentity = resolveSlackSendIdentity(params.identity);
115
+ const threadTs = resolveSlackThreadTsValue(params);
116
+ const sendOptions = {
117
+ cfg: params.cfg,
118
+ ...tokenOverride ? { token: tokenOverride } : {},
119
+ threadTs,
120
+ accountId: params.accountId ?? void 0,
121
+ ...params.mediaUrl ? {
122
+ mediaUrl: params.mediaUrl,
123
+ mediaAccess: params.mediaAccess,
124
+ mediaLocalRoots: params.mediaLocalRoots,
125
+ mediaReadFile: params.mediaReadFile,
126
+ ...params.forceDocument ? { forceDocument: true } : {}
127
+ } : {},
128
+ ...params.blocks ? { blocks: params.blocks } : {},
129
+ ...params.authoredTextPlacement ? { authoredTextPlacement: params.authoredTextPlacement } : {},
130
+ ...Object.hasOwn(params, "nativeDataFallbackBaseText") ? { nativeDataFallbackBaseText: params.nativeDataFallbackBaseText } : {},
131
+ ...params.textIsSlackPlainText ? { textIsSlackPlainText: true } : {},
132
+ ...slackIdentity ? { identity: slackIdentity } : {},
133
+ ...params.deliveryQueueId ? { deliveryQueueId: params.deliveryQueueId } : {},
134
+ ...params.onPlatformSendDispatch ? { onPlatformSendDispatch: params.onPlatformSendDispatch } : {},
135
+ ...params.onDeliveryResult ? { onDeliveryResult: async (progress) => {
136
+ await params.onDeliveryResult?.(toSlackOutboundResult(progress));
137
+ } } : {}
138
+ };
139
+ return await send(params.to, params.text, sendOptions);
118
140
  };
119
- return await send(params.to, params.text, sendOptions);
120
- }
121
- function createSlackAttachedSendAdapter() {
122
- return createAttachedChannelResultAdapter({
123
- channel: "slack",
124
- sendText: sendSlackOutboundMessage,
125
- sendMedia: sendSlackOutboundMessage
126
- });
127
141
  }
128
142
  const slackOutbound = {
129
143
  deliveryMode: "direct",
@@ -136,11 +150,19 @@ const slackOutbound = {
136
150
  return resolution.segments.length > 0 ? withSlackRenderedPresentation(payload, slackData, resolution) : null;
137
151
  },
138
152
  sendPayload: async (ctx) => {
153
+ const send = await prepareSlackOutboundSend(ctx);
154
+ const { mediaUrl: _mediaUrl, ...commonCtx } = ctx;
155
+ const preparedCtx = {
156
+ ...commonCtx,
157
+ replyToId: resolveSlackThreadTsValue(ctx),
158
+ threadId: null,
159
+ deliveryQueueId: void 0
160
+ };
139
161
  const payload = {
140
- ...ctx.payload,
162
+ ...preparedCtx.payload,
141
163
  text: resolveLegacyInteractiveTextFallback({
142
- text: ctx.payload.text,
143
- interactive: ctx.payload.interactive
164
+ text: preparedCtx.payload.text,
165
+ interactive: preparedCtx.payload.interactive
144
166
  }) ?? ""
145
167
  };
146
168
  const slackData = payload.channelData?.slack;
@@ -148,43 +170,48 @@ const slackOutbound = {
148
170
  let resolution;
149
171
  if (renderedResolution) resolution = renderedResolution;
150
172
  else resolution = resolveSlackOutboundBlockResolution(payload);
151
- if (resolution.segments.length === 0) return await sendTextMediaPayload({
152
- channel: "slack",
153
- ctx: {
154
- ...ctx,
155
- payload
156
- },
157
- adapter: slackOutbound
158
- });
173
+ if (resolution.segments.length === 0) {
174
+ const sendPart = async (part) => toSlackOutboundResult(await send(part));
175
+ return await sendTextMediaPayload({
176
+ channel: "slack",
177
+ ctx: {
178
+ ...preparedCtx,
179
+ payload
180
+ },
181
+ adapter: {
182
+ sendText: sendPart,
183
+ sendMedia: sendPart
184
+ }
185
+ });
186
+ }
159
187
  const mediaUrls = resolvePayloadMediaUrls(payload);
160
188
  const deliveryMessages = resolveSlackReplyDeliveryMessages({
161
189
  authoredTextPlacement: resolution.authoredTextPlacement,
162
190
  segments: resolution.segments,
163
191
  text: payload.text
164
192
  });
165
- const useSingleDeliveryMarker = mediaUrls.length === 0 && deliveryMessages.length === 1;
166
- return attachChannelToResult("slack", await sendPayloadMediaSequenceAndFinalize({
193
+ const sentResults = [];
194
+ return toSlackOutboundResult(await sendPayloadMediaSequenceAndFinalize({
167
195
  text: "",
168
196
  mediaUrls,
169
- send: async ({ text, mediaUrl }) => await sendSlackOutboundMessage({
170
- ...ctx,
197
+ send: async ({ text, mediaUrl }) => await send({
198
+ ...preparedCtx,
171
199
  text,
172
- mediaUrl,
173
- deliveryQueueId: useSingleDeliveryMarker ? ctx.deliveryQueueId : void 0
200
+ mediaUrl
174
201
  }),
202
+ onResult: (result) => {
203
+ sentResults.push(result);
204
+ },
175
205
  finalize: async () => {
176
- let lastResult;
177
- for (const message of deliveryMessages) lastResult = await sendSlackOutboundMessage({
178
- ...ctx,
206
+ for (const message of deliveryMessages) sentResults.push(await send({
207
+ ...preparedCtx,
179
208
  text: message.text,
180
209
  ...message.blocks ? { blocks: message.blocks } : {},
181
210
  ...message.authoredTextPlacement ? { authoredTextPlacement: message.authoredTextPlacement } : {},
182
211
  ...message.nativeDataFallbackBaseText ? { nativeDataFallbackBaseText: message.nativeDataFallbackBaseText } : {},
183
- ...message.textIsSlackPlainText ? { textIsSlackPlainText: true } : {},
184
- deliveryQueueId: useSingleDeliveryMarker ? ctx.deliveryQueueId : void 0
185
- });
186
- if (!lastResult) throw new Error("Slack rendered presentation produced no deliverable segment");
187
- return lastResult;
212
+ ...message.textIsSlackPlainText ? { textIsSlackPlainText: true } : {}
213
+ }));
214
+ return mergeSlackSendResults(sentResults);
188
215
  }
189
216
  }));
190
217
  },
@@ -203,7 +230,7 @@ const slackOutbound = {
203
230
  const result = results.find(({ channel, meta }) => channel === "slack" && Array.isArray(meta?.slackQuestionActionIds) && meta.slackQuestionActionIds.some((actionId) => typeof actionId === "string" && questionActionIds.includes(actionId)));
204
231
  const deliveredDisplayBlocks = (result?.meta)?.[SLACK_QUESTION_FINALIZATION_BLOCKS];
205
232
  if (!deliveryMessage || !deliveredDisplayBlocks || !result?.messageId) return;
206
- const channelId = result.channelId;
233
+ const channelId = result.target?.kind === "channel" ? result.target.id : void 0;
207
234
  if (!channelId) return;
208
235
  const teamId = parseSlackTarget(target.to, { defaultKind: "channel" })?.teamId;
209
236
  const questionMessageId = typeof result.meta?.slackQuestionMessageId === "string" ? result.meta.slackQuestionMessageId : result.messageId;
@@ -232,7 +259,15 @@ const slackOutbound = {
232
259
  }
233
260
  });
234
261
  },
235
- ...createSlackAttachedSendAdapter()
262
+ sendText: async (ctx) => {
263
+ return toSlackOutboundResult(await (await prepareSlackOutboundSend(ctx))(ctx));
264
+ },
265
+ sendMedia: async (ctx) => {
266
+ return toSlackOutboundResult(await (await prepareSlackOutboundSend(ctx))({
267
+ ...ctx,
268
+ deliveryQueueId: void 0
269
+ }));
270
+ }
236
271
  };
237
272
  //#endregion
238
273
  export { slackOutbound };