@bubblelab/bubble-core 0.1.17 → 0.1.19

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 (115) hide show
  1. package/dist/bubble-bundle.d.ts +84 -79
  2. package/dist/bubble-factory.js +1 -1
  3. package/dist/bubble-factory.js.map +1 -1
  4. package/dist/bubbles/service-bubble/agi-inc.d.ts +112 -112
  5. package/dist/bubbles/service-bubble/ai-agent.d.ts +8 -8
  6. package/dist/bubbles/service-bubble/airtable.d.ts +152 -152
  7. package/dist/bubbles/service-bubble/apify/apify.d.ts +8 -8
  8. package/dist/bubbles/service-bubble/browserbase/browserbase.d.ts +20 -20
  9. package/dist/bubbles/service-bubble/browserbase/browserbase.schema.d.ts +8 -8
  10. package/dist/bubbles/service-bubble/eleven-labs.d.ts +28 -28
  11. package/dist/bubbles/service-bubble/firecrawl.d.ts +140 -140
  12. package/dist/bubbles/service-bubble/followupboss.d.ts +128 -128
  13. package/dist/bubbles/service-bubble/github.d.ts +104 -104
  14. package/dist/bubbles/service-bubble/gmail.d.ts +456 -456
  15. package/dist/bubbles/service-bubble/google-calendar.d.ts +120 -120
  16. package/dist/bubbles/service-bubble/google-drive.d.ts +92 -92
  17. package/dist/bubbles/service-bubble/google-sheets/google-sheets.d.ts +22 -22
  18. package/dist/bubbles/service-bubble/google-sheets/google-sheets.schema.d.ts +10 -10
  19. package/dist/bubbles/service-bubble/hello-world.d.ts +4 -4
  20. package/dist/bubbles/service-bubble/http.d.ts +16 -16
  21. package/dist/bubbles/service-bubble/insforge-db.d.ts +10 -10
  22. package/dist/bubbles/service-bubble/notion/notion.d.ts +76 -76
  23. package/dist/bubbles/service-bubble/postgresql.d.ts +10 -10
  24. package/dist/bubbles/service-bubble/resend.d.ts +32 -32
  25. package/dist/bubbles/service-bubble/slack/index.d.ts +3 -0
  26. package/dist/bubbles/service-bubble/slack/index.d.ts.map +1 -0
  27. package/dist/bubbles/service-bubble/slack/index.js +6 -0
  28. package/dist/bubbles/service-bubble/slack/index.js.map +1 -0
  29. package/dist/bubbles/service-bubble/slack/slack.d.ts +6812 -0
  30. package/dist/bubbles/service-bubble/slack/slack.d.ts.map +1 -0
  31. package/dist/bubbles/service-bubble/slack/slack.js +1840 -0
  32. package/dist/bubbles/service-bubble/slack/slack.js.map +1 -0
  33. package/dist/bubbles/service-bubble/slack/slack.schema.d.ts +3980 -0
  34. package/dist/bubbles/service-bubble/slack/slack.schema.d.ts.map +1 -0
  35. package/dist/bubbles/service-bubble/slack/slack.schema.js +1061 -0
  36. package/dist/bubbles/service-bubble/slack/slack.schema.js.map +1 -0
  37. package/dist/bubbles/service-bubble/slack/slack.utils.d.ts +141 -0
  38. package/dist/bubbles/service-bubble/slack/slack.utils.d.ts.map +1 -0
  39. package/dist/bubbles/service-bubble/slack/slack.utils.js +410 -0
  40. package/dist/bubbles/service-bubble/slack/slack.utils.js.map +1 -0
  41. package/dist/bubbles/service-bubble/slack.d.ts +1 -6811
  42. package/dist/bubbles/service-bubble/slack.d.ts.map +1 -1
  43. package/dist/bubbles/service-bubble/slack.js +2 -1829
  44. package/dist/bubbles/service-bubble/slack.js.map +1 -1
  45. package/dist/bubbles/service-bubble/storage.d.ts +20 -20
  46. package/dist/bubbles/service-bubble/telegram.d.ts +246 -246
  47. package/dist/bubbles/tool-bubble/amazon-shopping-tool/amazon-shopping-tool.d.ts +16 -16
  48. package/dist/bubbles/tool-bubble/amazon-shopping-tool/amazon-shopping-tool.schema.d.ts +6 -6
  49. package/dist/bubbles/tool-bubble/bubbleflow-validation-tool.d.ts +4 -4
  50. package/dist/bubbles/tool-bubble/chart-js-tool.d.ts +4 -4
  51. package/dist/bubbles/tool-bubble/code-edit-tool.d.ts +4 -4
  52. package/dist/bubbles/tool-bubble/get-bubble-details-tool.d.ts +4 -4
  53. package/dist/bubbles/tool-bubble/get-trigger-detail-tool.d.ts +4 -4
  54. package/dist/bubbles/tool-bubble/google-maps-tool.d.ts +16 -16
  55. package/dist/bubbles/tool-bubble/instagram-tool.d.ts +4 -4
  56. package/dist/bubbles/tool-bubble/linkedin-tool.d.ts +34 -34
  57. package/dist/bubbles/tool-bubble/list-bubbles-tool.d.ts +4 -4
  58. package/dist/bubbles/tool-bubble/reddit-scrape-tool.d.ts +14 -14
  59. package/dist/bubbles/tool-bubble/research-agent-tool.d.ts +4 -4
  60. package/dist/bubbles/tool-bubble/sql-query-tool.d.ts +8 -8
  61. package/dist/bubbles/tool-bubble/tiktok-tool.d.ts +12 -12
  62. package/dist/bubbles/tool-bubble/tool-template.d.ts +4 -4
  63. package/dist/bubbles/tool-bubble/twitter-tool.d.ts +14 -14
  64. package/dist/bubbles/tool-bubble/web-crawl-tool.d.ts +4 -4
  65. package/dist/bubbles/tool-bubble/web-extract-tool.d.ts +4 -4
  66. package/dist/bubbles/tool-bubble/web-scrape-tool.d.ts +4 -4
  67. package/dist/bubbles/tool-bubble/web-search-tool.d.ts +10 -10
  68. package/dist/bubbles/tool-bubble/youtube-tool.d.ts +14 -14
  69. package/dist/bubbles/workflow-bubble/database-analyzer.workflow.d.ts +4 -4
  70. package/dist/bubbles/workflow-bubble/generate-document.workflow.d.ts +16 -16
  71. package/dist/bubbles/workflow-bubble/parse-document.workflow.d.ts +4 -4
  72. package/dist/bubbles/workflow-bubble/pdf-form-operations.workflow.d.ts +32 -32
  73. package/dist/bubbles/workflow-bubble/pdf-ocr.workflow.d.ts +8 -8
  74. package/dist/bubbles/workflow-bubble/slack-data-assistant.workflow.d.ts +8 -8
  75. package/dist/bubbles/workflow-bubble/slack-data-assistant.workflow.d.ts.map +1 -1
  76. package/dist/bubbles/workflow-bubble/slack-data-assistant.workflow.js +2 -2
  77. package/dist/bubbles/workflow-bubble/slack-data-assistant.workflow.js.map +1 -1
  78. package/dist/bubbles/workflow-bubble/slack-formatter-agent.d.ts +40 -40
  79. package/dist/bubbles/workflow-bubble/slack-notifier.workflow.d.ts +4 -4
  80. package/dist/bubbles/workflow-bubble/slack-notifier.workflow.js +1 -1
  81. package/dist/bubbles/workflow-bubble/slack-notifier.workflow.js.map +1 -1
  82. package/dist/bubbles.json +2 -2
  83. package/dist/index.d.ts +1 -1
  84. package/dist/index.d.ts.map +1 -1
  85. package/dist/index.js +1 -1
  86. package/dist/index.js.map +1 -1
  87. package/package.json +2 -2
  88. package/dist/bubbles/service-bubble/browserbase/browserbase.integration.flow.d.ts +0 -37
  89. package/dist/bubbles/service-bubble/browserbase/browserbase.integration.flow.d.ts.map +0 -1
  90. package/dist/bubbles/service-bubble/browserbase/browserbase.integration.flow.js +0 -203
  91. package/dist/bubbles/service-bubble/browserbase/browserbase.integration.flow.js.map +0 -1
  92. package/dist/bubbles/service-bubble/crustdata/crustdata.d.ts +0 -1358
  93. package/dist/bubbles/service-bubble/crustdata/crustdata.d.ts.map +0 -1
  94. package/dist/bubbles/service-bubble/crustdata/crustdata.js +0 -219
  95. package/dist/bubbles/service-bubble/crustdata/crustdata.js.map +0 -1
  96. package/dist/bubbles/service-bubble/crustdata/crustdata.schema.d.ts +0 -1604
  97. package/dist/bubbles/service-bubble/crustdata/crustdata.schema.d.ts.map +0 -1
  98. package/dist/bubbles/service-bubble/crustdata/crustdata.schema.js +0 -194
  99. package/dist/bubbles/service-bubble/crustdata/crustdata.schema.js.map +0 -1
  100. package/dist/bubbles/service-bubble/crustdata/index.d.ts +0 -3
  101. package/dist/bubbles/service-bubble/crustdata/index.d.ts.map +0 -1
  102. package/dist/bubbles/service-bubble/crustdata/index.js +0 -3
  103. package/dist/bubbles/service-bubble/crustdata/index.js.map +0 -1
  104. package/dist/bubbles/service-bubble/http.integration.flow.d.ts +0 -49
  105. package/dist/bubbles/service-bubble/http.integration.flow.d.ts.map +0 -1
  106. package/dist/bubbles/service-bubble/http.integration.flow.js +0 -425
  107. package/dist/bubbles/service-bubble/http.integration.flow.js.map +0 -1
  108. package/dist/bubbles/tool-bubble/amazon-shopping-tool/amazon-shopping-tool.integration.flow.d.ts +0 -31
  109. package/dist/bubbles/tool-bubble/amazon-shopping-tool/amazon-shopping-tool.integration.flow.d.ts.map +0 -1
  110. package/dist/bubbles/tool-bubble/amazon-shopping-tool/amazon-shopping-tool.integration.flow.js +0 -100
  111. package/dist/bubbles/tool-bubble/amazon-shopping-tool/amazon-shopping-tool.integration.flow.js.map +0 -1
  112. package/dist/bubbles/tool-bubble/company-enrichment-tool.d.ts +0 -740
  113. package/dist/bubbles/tool-bubble/company-enrichment-tool.d.ts.map +0 -1
  114. package/dist/bubbles/tool-bubble/company-enrichment-tool.js +0 -350
  115. package/dist/bubbles/tool-bubble/company-enrichment-tool.js.map +0 -1
@@ -0,0 +1,1061 @@
1
+ /**
2
+ * Slack Bubble Schema Definitions
3
+ * All Zod schemas for Slack operations
4
+ */
5
+ import { z } from 'zod';
6
+ import { CredentialType } from '@bubblelab/shared-schemas';
7
+ // Slack API base URL
8
+ export const SLACK_API_BASE = 'https://slack.com/api';
9
+ // ============================================================================
10
+ // CHANNEL TYPES
11
+ // ============================================================================
12
+ export const ChannelTypes = z
13
+ .enum(['public_channel', 'private_channel', 'mpim', 'im'])
14
+ .describe('Types of Slack channels: public_channel, private_channel, mpim (multi-person direct message), im (direct message)');
15
+ // ============================================================================
16
+ // MESSAGE ATTACHMENT SCHEMA
17
+ // ============================================================================
18
+ export const MessageAttachmentSchema = z.object({
19
+ color: z
20
+ .string()
21
+ .optional()
22
+ .describe('Color bar accent (hex color or good/warning/danger)'),
23
+ pretext: z
24
+ .string()
25
+ .optional()
26
+ .describe('Text that appears before the main attachment content'),
27
+ author_name: z
28
+ .string()
29
+ .optional()
30
+ .describe('Author name displayed at the top'),
31
+ author_link: z
32
+ .string()
33
+ .url()
34
+ .optional()
35
+ .describe('URL to link the author name'),
36
+ author_icon: z.string().url().optional().describe('Author icon image URL'),
37
+ title: z.string().optional().describe('Attachment title text'),
38
+ title_link: z.string().url().optional().describe('URL to link the title'),
39
+ text: z.string().optional().describe('Main attachment text content'),
40
+ fields: z
41
+ .array(z.object({
42
+ title: z.string().describe('Field title'),
43
+ value: z.string().describe('Field value'),
44
+ short: z
45
+ .boolean()
46
+ .optional()
47
+ .describe('Whether field should be displayed side-by-side'),
48
+ }))
49
+ .optional()
50
+ .describe('Array of field objects for structured data'),
51
+ image_url: z.string().url().optional().describe('URL of image to display'),
52
+ thumb_url: z.string().url().optional().describe('URL of thumbnail image'),
53
+ footer: z.string().optional().describe('Footer text'),
54
+ footer_icon: z.string().url().optional().describe('Footer icon URL'),
55
+ ts: z.number().optional().describe('Timestamp for the attachment'),
56
+ });
57
+ // ============================================================================
58
+ // BLOCK KIT SCHEMA
59
+ // ============================================================================
60
+ export const BlockElementSchema = z
61
+ .object({
62
+ type: z
63
+ .string()
64
+ .describe('Block element type (section, divider, button, etc.)'),
65
+ text: z
66
+ .object({
67
+ type: z.enum(['plain_text', 'mrkdwn']).describe('Text formatting type'),
68
+ text: z.string().describe('The actual text content'),
69
+ emoji: z.boolean().optional(),
70
+ verbatim: z.boolean().optional(),
71
+ })
72
+ .optional()
73
+ .describe('Text object for the block element'),
74
+ elements: z
75
+ .array(z.object({
76
+ type: z
77
+ .enum(['plain_text', 'mrkdwn', 'image'])
78
+ .describe('Element type'),
79
+ text: z.string().optional().describe('Text content'),
80
+ image_url: z
81
+ .string()
82
+ .optional()
83
+ .describe('Image URL for image elements'),
84
+ alt_text: z
85
+ .string()
86
+ .optional()
87
+ .describe('Alt text for image elements'),
88
+ emoji: z.boolean().optional(),
89
+ verbatim: z.boolean().optional(),
90
+ }))
91
+ .optional()
92
+ .describe('Elements array for context blocks'),
93
+ })
94
+ .passthrough()
95
+ .describe('Block Kit element for rich message formatting');
96
+ // ============================================================================
97
+ // PARAMETERS SCHEMA (DISCRIMINATED UNION)
98
+ // ============================================================================
99
+ export const SlackParamsSchema = z.discriminatedUnion('operation', [
100
+ // Send message operation
101
+ z.object({
102
+ operation: z
103
+ .literal('send_message')
104
+ .describe('Send a message to a Slack channel or DM. Required scopes: chat:write (add chat:write.public for public channels bot has not joined, add im:write to send DMs to users)'),
105
+ channel: z
106
+ .string()
107
+ .min(1, 'Channel ID or name is required')
108
+ .describe('Channel ID (e.g., C1234567890), channel name (e.g., general or #general), or user ID for DM (e.g., U1234567890 - requires im:write scope)'),
109
+ text: z
110
+ .string()
111
+ .min(1, 'Message text is required')
112
+ .describe('Message text content'),
113
+ username: z
114
+ .string()
115
+ .optional()
116
+ .describe('Override bot username for this message'),
117
+ icon_emoji: z
118
+ .string()
119
+ .optional()
120
+ .describe('Override bot icon with emoji (e.g., :robot_face:)'),
121
+ icon_url: z
122
+ .string()
123
+ .url()
124
+ .optional()
125
+ .describe('Override bot icon with custom image URL'),
126
+ attachments: z
127
+ .array(MessageAttachmentSchema)
128
+ .optional()
129
+ .describe('Legacy message attachments'),
130
+ blocks: z
131
+ .array(BlockElementSchema)
132
+ .optional()
133
+ .describe('Block Kit structured message blocks'),
134
+ thread_ts: z
135
+ .string()
136
+ .optional()
137
+ .describe('Timestamp of parent message to reply in thread'),
138
+ reply_broadcast: z
139
+ .boolean()
140
+ .optional()
141
+ .default(false)
142
+ .describe('Broadcast thread reply to channel'),
143
+ credentials: z
144
+ .record(z.nativeEnum(CredentialType), z.string())
145
+ .optional()
146
+ .describe('Object mapping credential types to values (injected at runtime)'),
147
+ unfurl_links: z
148
+ .boolean()
149
+ .optional()
150
+ .default(true)
151
+ .describe('Enable automatic link unfurling'),
152
+ unfurl_media: z
153
+ .boolean()
154
+ .optional()
155
+ .default(true)
156
+ .describe('Enable automatic media unfurling'),
157
+ }),
158
+ // List channels operation
159
+ z.object({
160
+ operation: z
161
+ .literal('list_channels')
162
+ .describe('List all channels in the Slack workspace. Required scopes: channels:read (public), groups:read (private), im:read (DMs), mpim:read (group DMs)'),
163
+ types: z
164
+ .array(ChannelTypes)
165
+ .optional()
166
+ .default(['public_channel', 'private_channel', 'mpim', 'im'])
167
+ .describe('Types of channels to include in results'),
168
+ exclude_archived: z
169
+ .boolean()
170
+ .optional()
171
+ .default(true)
172
+ .describe('Exclude archived channels from results'),
173
+ limit: z
174
+ .number()
175
+ .min(1)
176
+ .max(1000)
177
+ .optional()
178
+ .default(50)
179
+ .describe('Maximum number of channels to return (1-1000)'),
180
+ cursor: z
181
+ .string()
182
+ .optional()
183
+ .describe('Cursor for pagination to get next set of results'),
184
+ credentials: z
185
+ .record(z.nativeEnum(CredentialType), z.string())
186
+ .optional()
187
+ .describe('Object mapping credential types to values (injected at runtime)'),
188
+ }),
189
+ // Get channel info operation
190
+ z.object({
191
+ operation: z
192
+ .literal('get_channel_info')
193
+ .describe('Get detailed information about a specific channel. Required scopes: channels:read (public), groups:read (private), im:read (DMs), mpim:read (group DMs)'),
194
+ channel: z
195
+ .string()
196
+ .min(1, 'Channel ID or name is required')
197
+ .describe('Channel ID (e.g., C1234567890) or channel name (e.g., general or #general)'),
198
+ include_locale: z
199
+ .boolean()
200
+ .optional()
201
+ .default(false)
202
+ .describe('Include locale information in the response'),
203
+ credentials: z
204
+ .record(z.nativeEnum(CredentialType), z.string())
205
+ .optional()
206
+ .describe('Object mapping credential types to values (injected at runtime)'),
207
+ }),
208
+ // Get user info operation
209
+ z.object({
210
+ operation: z
211
+ .literal('get_user_info')
212
+ .describe('Get detailed information about a specific user. Required scopes: users:read (add users:read.email to access email field)'),
213
+ user: z
214
+ .string()
215
+ .min(1, 'User ID is required')
216
+ .describe('User ID to get information about'),
217
+ include_locale: z
218
+ .boolean()
219
+ .optional()
220
+ .default(false)
221
+ .describe('Include locale information in the response'),
222
+ credentials: z
223
+ .record(z.nativeEnum(CredentialType), z.string())
224
+ .optional()
225
+ .describe('Object mapping credential types to values (injected at runtime)'),
226
+ }),
227
+ // List users operation
228
+ z.object({
229
+ operation: z
230
+ .literal('list_users')
231
+ .describe('List all users in the Slack workspace. Required scopes: users:read (add users:read.email to access email field)'),
232
+ limit: z
233
+ .number()
234
+ .min(1)
235
+ .max(1000)
236
+ .optional()
237
+ .default(50)
238
+ .describe('Maximum number of users to return (1-1000)'),
239
+ cursor: z
240
+ .string()
241
+ .optional()
242
+ .describe('Cursor for pagination to get next set of results'),
243
+ include_locale: z
244
+ .boolean()
245
+ .optional()
246
+ .default(false)
247
+ .describe('Include locale information in the response'),
248
+ credentials: z
249
+ .record(z.nativeEnum(CredentialType), z.string())
250
+ .optional()
251
+ .describe('Object mapping credential types to values (injected at runtime)'),
252
+ }),
253
+ // Get conversation history operation
254
+ z.object({
255
+ operation: z
256
+ .literal('get_conversation_history')
257
+ .describe('Retrieve message history from a channel or direct message. Required scopes: channels:history (public), groups:history (private), im:history (DMs), mpim:history (group DMs)'),
258
+ channel: z
259
+ .string()
260
+ .min(1, 'Channel ID or name is required')
261
+ .describe('Channel ID (e.g., C1234567890) or channel name (e.g., general or #general)'),
262
+ latest: z
263
+ .string()
264
+ .optional()
265
+ .describe('End of time range of messages to include (timestamp)'),
266
+ oldest: z
267
+ .string()
268
+ .optional()
269
+ .describe('Start of time range of messages to include (timestamp)'),
270
+ inclusive: z
271
+ .boolean()
272
+ .optional()
273
+ .default(false)
274
+ .describe('Include messages with latest or oldest timestamps in results'),
275
+ limit: z
276
+ .number()
277
+ .min(1)
278
+ .max(1000)
279
+ .optional()
280
+ .default(20)
281
+ .describe('Maximum number of messages to return (1-1000)'),
282
+ cursor: z
283
+ .string()
284
+ .optional()
285
+ .describe('Cursor for pagination to get next set of results'),
286
+ credentials: z
287
+ .record(z.nativeEnum(CredentialType), z.string())
288
+ .optional()
289
+ .describe('Object mapping credential types to values (injected at runtime)'),
290
+ }),
291
+ // Get thread replies operation
292
+ z.object({
293
+ operation: z
294
+ .literal('get_thread_replies')
295
+ .describe('Retrieve all replies to a thread in a channel. Required scopes: channels:history (public), groups:history (private), im:history (DMs), mpim:history (group DMs)'),
296
+ channel: z
297
+ .string()
298
+ .min(1, 'Channel ID is required')
299
+ .describe('Channel ID where the thread exists'),
300
+ ts: z
301
+ .string()
302
+ .min(1, 'Thread timestamp is required')
303
+ .describe('Timestamp of the parent message to get replies for'),
304
+ latest: z
305
+ .string()
306
+ .optional()
307
+ .describe('End of time range of messages to include (timestamp)'),
308
+ oldest: z
309
+ .string()
310
+ .optional()
311
+ .describe('Start of time range of messages to include (timestamp)'),
312
+ inclusive: z
313
+ .boolean()
314
+ .optional()
315
+ .default(false)
316
+ .describe('Include messages with latest or oldest timestamps in results'),
317
+ limit: z
318
+ .number()
319
+ .min(1)
320
+ .max(1000)
321
+ .optional()
322
+ .default(100)
323
+ .describe('Maximum number of messages to return (1-1000)'),
324
+ cursor: z
325
+ .string()
326
+ .optional()
327
+ .describe('Cursor for pagination to get next set of results'),
328
+ credentials: z
329
+ .record(z.nativeEnum(CredentialType), z.string())
330
+ .optional()
331
+ .describe('Object mapping credential types to values (injected at runtime)'),
332
+ }),
333
+ // Update message operation
334
+ z.object({
335
+ operation: z
336
+ .literal('update_message')
337
+ .describe('Update an existing message in a channel. Required scopes: chat:write'),
338
+ channel: z
339
+ .string()
340
+ .min(1, 'Channel ID or name is required')
341
+ .describe('Channel ID (e.g., C1234567890) or channel name (e.g., general or #general) where the message is located'),
342
+ ts: z
343
+ .string()
344
+ .min(1, 'Message timestamp is required')
345
+ .describe('Timestamp of the message to update'),
346
+ text: z.string().optional().describe('New text content for the message'),
347
+ attachments: z
348
+ .array(MessageAttachmentSchema)
349
+ .optional()
350
+ .describe('New legacy message attachments'),
351
+ blocks: z
352
+ .array(BlockElementSchema)
353
+ .optional()
354
+ .describe('New Block Kit structured message blocks'),
355
+ credentials: z
356
+ .record(z.nativeEnum(CredentialType), z.string())
357
+ .optional()
358
+ .describe('Object mapping credential types to values (injected at runtime)'),
359
+ }),
360
+ // Delete message operation
361
+ z.object({
362
+ operation: z
363
+ .literal('delete_message')
364
+ .describe('Delete a message from a channel. Required scopes: chat:write. Note: Bot tokens can only delete messages posted by the bot; user tokens can delete any message the user has permission to delete'),
365
+ channel: z
366
+ .string()
367
+ .min(1, 'Channel ID or name is required')
368
+ .describe('Channel ID (e.g., C1234567890) or channel name (e.g., general or #general) where the message is located'),
369
+ ts: z
370
+ .string()
371
+ .min(1, 'Message timestamp is required')
372
+ .describe('Timestamp of the message to delete'),
373
+ credentials: z
374
+ .record(z.nativeEnum(CredentialType), z.string())
375
+ .optional()
376
+ .describe('Object mapping credential types to values (injected at runtime)'),
377
+ }),
378
+ // Add reaction operation
379
+ z.object({
380
+ operation: z
381
+ .literal('add_reaction')
382
+ .describe('Add an emoji reaction to a message. Required scopes: reactions:write'),
383
+ name: z
384
+ .string()
385
+ .min(1, 'Emoji name is required')
386
+ .describe('Emoji name without colons (e.g., thumbsup, heart)'),
387
+ channel: z
388
+ .string()
389
+ .min(1, 'Channel ID or name is required')
390
+ .describe('Channel ID (e.g., C1234567890) or channel name (e.g., general or #general) where the message is located'),
391
+ timestamp: z
392
+ .string()
393
+ .min(1, 'Message timestamp is required')
394
+ .describe('Timestamp of the message to react to'),
395
+ credentials: z
396
+ .record(z.nativeEnum(CredentialType), z.string())
397
+ .optional()
398
+ .describe('Object mapping credential types to values (injected at runtime)'),
399
+ }),
400
+ // Remove reaction operation
401
+ z.object({
402
+ operation: z
403
+ .literal('remove_reaction')
404
+ .describe('Remove an emoji reaction from a message. Required scopes: reactions:write'),
405
+ name: z
406
+ .string()
407
+ .min(1, 'Emoji name is required')
408
+ .describe('Emoji name without colons (e.g., thumbsup, heart)'),
409
+ channel: z
410
+ .string()
411
+ .min(1, 'Channel ID or name is required')
412
+ .describe('Channel ID (e.g., C1234567890) or channel name (e.g., general or #general) where the message is located'),
413
+ timestamp: z
414
+ .string()
415
+ .min(1, 'Message timestamp is required')
416
+ .describe('Timestamp of the message to remove reaction from'),
417
+ credentials: z
418
+ .record(z.nativeEnum(CredentialType), z.string())
419
+ .optional()
420
+ .describe('Object mapping credential types to values (injected at runtime)'),
421
+ }),
422
+ // Join channel operation
423
+ z.object({
424
+ operation: z
425
+ .literal('join_channel')
426
+ .describe('Join a public Slack channel. Required scopes: channels:join (bot token) or channels:write (user token)'),
427
+ channel: z
428
+ .string()
429
+ .min(1, 'Channel ID or name is required')
430
+ .describe('Channel ID (e.g., C1234567890) or channel name (e.g., general or #general) to join'),
431
+ credentials: z
432
+ .record(z.nativeEnum(CredentialType), z.string())
433
+ .optional()
434
+ .describe('Object mapping credential types to values (injected at runtime)'),
435
+ }),
436
+ // Upload file operation
437
+ z.object({
438
+ operation: z
439
+ .literal('upload_file')
440
+ .describe('Upload a file to a Slack channel. Required scopes: files:write'),
441
+ channel: z
442
+ .string()
443
+ .min(1, 'Channel ID or name is required')
444
+ .describe('Channel ID (e.g., C1234567890), channel name (e.g., general or #general), or user ID for DM'),
445
+ file_path: z
446
+ .string()
447
+ .min(1, 'File path is required')
448
+ .describe('Local file path to upload'),
449
+ filename: z
450
+ .string()
451
+ .optional()
452
+ .describe('Override filename for the upload'),
453
+ title: z.string().optional().describe('Title for the file'),
454
+ initial_comment: z
455
+ .string()
456
+ .optional()
457
+ .describe('Initial comment to post with the file'),
458
+ thread_ts: z
459
+ .string()
460
+ .optional()
461
+ .describe('Timestamp of parent message to upload file in thread'),
462
+ credentials: z
463
+ .record(z.nativeEnum(CredentialType), z.string())
464
+ .optional()
465
+ .describe('Object mapping credential types to values (injected at runtime)'),
466
+ }),
467
+ // Schedule message operation
468
+ z.object({
469
+ operation: z
470
+ .literal('schedule_message')
471
+ .describe('Schedule a message to be sent at a future time. Required scopes: chat:write. Max 120 days in advance.'),
472
+ channel: z
473
+ .string()
474
+ .min(1, 'Channel ID or name is required')
475
+ .describe('Channel ID (e.g., C1234567890), channel name (e.g., general or #general), or user ID for DM'),
476
+ text: z
477
+ .string()
478
+ .min(1, 'Message text is required')
479
+ .describe('Message text content'),
480
+ post_at: z
481
+ .number()
482
+ .int()
483
+ .positive()
484
+ .describe('Unix timestamp (seconds) for when to send the message. Must be within 120 days from now.'),
485
+ thread_ts: z
486
+ .string()
487
+ .optional()
488
+ .describe('Timestamp of parent message to reply in thread'),
489
+ blocks: z
490
+ .array(BlockElementSchema)
491
+ .optional()
492
+ .describe('Block Kit structured message blocks'),
493
+ unfurl_links: z
494
+ .boolean()
495
+ .optional()
496
+ .default(true)
497
+ .describe('Enable automatic link unfurling'),
498
+ unfurl_media: z
499
+ .boolean()
500
+ .optional()
501
+ .default(true)
502
+ .describe('Enable automatic media unfurling'),
503
+ credentials: z
504
+ .record(z.nativeEnum(CredentialType), z.string())
505
+ .optional()
506
+ .describe('Object mapping credential types to values (injected at runtime)'),
507
+ }),
508
+ ]);
509
+ // ============================================================================
510
+ // RESPONSE DATA SCHEMAS
511
+ // ============================================================================
512
+ export const SlackChannelSchema = z
513
+ .object({
514
+ id: z.string().describe('Unique channel identifier'),
515
+ name: z.string().describe('Channel name without # prefix'),
516
+ is_channel: z
517
+ .boolean()
518
+ .optional()
519
+ .describe('True if this is a public channel'),
520
+ is_group: z
521
+ .boolean()
522
+ .optional()
523
+ .describe('True if this is a private channel'),
524
+ is_im: z.boolean().optional().describe('True if this is a direct message'),
525
+ is_mpim: z
526
+ .boolean()
527
+ .optional()
528
+ .describe('True if this is a multi-person direct message'),
529
+ is_private: z
530
+ .boolean()
531
+ .optional()
532
+ .describe('True if this is a private channel'),
533
+ created: z.number().describe('Unix timestamp when channel was created'),
534
+ is_archived: z.boolean().describe('True if channel is archived'),
535
+ is_general: z
536
+ .boolean()
537
+ .optional()
538
+ .describe('True if this is the #general channel'),
539
+ unlinked: z
540
+ .number()
541
+ .optional()
542
+ .describe('Unix timestamp when channel was unlinked'),
543
+ name_normalized: z.string().optional().describe('Normalized channel name'),
544
+ is_shared: z
545
+ .boolean()
546
+ .optional()
547
+ .describe('True if channel is shared with other workspaces'),
548
+ is_ext_shared: z
549
+ .boolean()
550
+ .optional()
551
+ .describe('True if channel is shared externally'),
552
+ is_org_shared: z
553
+ .boolean()
554
+ .optional()
555
+ .describe('True if channel is shared across organization'),
556
+ shared_team_ids: z
557
+ .array(z.string())
558
+ .optional()
559
+ .describe('IDs of teams this channel is shared with'),
560
+ pending_shared: z
561
+ .array(z.string())
562
+ .optional()
563
+ .describe('Pending shared connections'),
564
+ pending_connected_team_ids: z
565
+ .array(z.string())
566
+ .optional()
567
+ .describe('Pending team connection IDs'),
568
+ is_pending_ext_shared: z
569
+ .boolean()
570
+ .optional()
571
+ .describe('True if external sharing is pending'),
572
+ is_member: z
573
+ .boolean()
574
+ .optional()
575
+ .describe('True if the bot is a member of this channel'),
576
+ is_open: z.boolean().optional().describe('True if the channel is open'),
577
+ topic: z
578
+ .object({
579
+ value: z.string().describe('Topic text'),
580
+ creator: z.string().describe('User ID who set the topic'),
581
+ last_set: z.number().describe('Unix timestamp when topic was last set'),
582
+ })
583
+ .optional()
584
+ .describe('Channel topic information'),
585
+ purpose: z
586
+ .object({
587
+ value: z.string().describe('Purpose text'),
588
+ creator: z.string().describe('User ID who set the purpose'),
589
+ last_set: z
590
+ .number()
591
+ .describe('Unix timestamp when purpose was last set'),
592
+ })
593
+ .optional()
594
+ .describe('Channel purpose information'),
595
+ num_members: z
596
+ .number()
597
+ .optional()
598
+ .describe('Number of members in the channel'),
599
+ })
600
+ .describe('Slack channel object with metadata');
601
+ export const SlackUserSchema = z
602
+ .object({
603
+ id: z.string().describe('Unique user identifier'),
604
+ team_id: z.string().optional().describe('Team/workspace ID'),
605
+ name: z.string().describe('Username (handle without @)'),
606
+ deleted: z.boolean().optional().describe('True if user account is deleted'),
607
+ color: z.string().optional().describe('Color code for user in UI'),
608
+ real_name: z.string().optional().describe('Users real name'),
609
+ tz: z.string().optional().describe('Timezone identifier'),
610
+ tz_label: z.string().optional().describe('Human-readable timezone label'),
611
+ tz_offset: z
612
+ .number()
613
+ .optional()
614
+ .describe('Timezone offset from UTC in seconds'),
615
+ profile: z
616
+ .object({
617
+ title: z.string().optional().describe('Job title'),
618
+ phone: z.string().optional().describe('Phone number'),
619
+ skype: z.string().optional().describe('Skype username'),
620
+ real_name: z.string().optional().describe('Real name from profile'),
621
+ real_name_normalized: z
622
+ .string()
623
+ .optional()
624
+ .describe('Normalized real name'),
625
+ display_name: z.string().optional().describe('Display name'),
626
+ display_name_normalized: z
627
+ .string()
628
+ .optional()
629
+ .describe('Normalized display name'),
630
+ fields: z
631
+ .record(z.unknown())
632
+ .optional()
633
+ .describe('Custom profile fields'),
634
+ status_text: z.string().optional().describe('Current status text'),
635
+ status_emoji: z.string().optional().describe('Current status emoji'),
636
+ status_expiration: z
637
+ .number()
638
+ .optional()
639
+ .describe('Unix timestamp when status expires'),
640
+ avatar_hash: z.string().optional().describe('Hash for avatar image'),
641
+ image_original: z
642
+ .string()
643
+ .optional()
644
+ .describe('URL of original avatar image'),
645
+ is_custom_image: z
646
+ .boolean()
647
+ .optional()
648
+ .describe('True if using custom avatar'),
649
+ email: z.string().optional().describe('Email address'),
650
+ first_name: z.string().optional().describe('First name'),
651
+ last_name: z.string().optional().describe('Last name'),
652
+ image_24: z.string().optional().describe('24x24 pixel avatar URL'),
653
+ image_32: z.string().optional().describe('32x32 pixel avatar URL'),
654
+ image_48: z.string().optional().describe('48x48 pixel avatar URL'),
655
+ image_72: z.string().optional().describe('72x72 pixel avatar URL'),
656
+ image_192: z.string().optional().describe('192x192 pixel avatar URL'),
657
+ image_512: z.string().optional().describe('512x512 pixel avatar URL'),
658
+ image_1024: z
659
+ .string()
660
+ .optional()
661
+ .describe('1024x1024 pixel avatar URL'),
662
+ })
663
+ .optional()
664
+ .describe('User profile information'),
665
+ is_admin: z
666
+ .boolean()
667
+ .optional()
668
+ .describe('True if user is workspace admin'),
669
+ is_owner: z
670
+ .boolean()
671
+ .optional()
672
+ .describe('True if user is workspace owner'),
673
+ is_primary_owner: z
674
+ .boolean()
675
+ .optional()
676
+ .describe('True if user is primary workspace owner'),
677
+ is_restricted: z
678
+ .boolean()
679
+ .optional()
680
+ .describe('True if user is restricted (single-channel guest)'),
681
+ is_ultra_restricted: z
682
+ .boolean()
683
+ .optional()
684
+ .describe('True if user is ultra restricted (multi-channel guest)'),
685
+ is_bot: z.boolean().optional().describe('True if this is a bot user'),
686
+ is_app_user: z.boolean().optional().describe('True if this is an app user'),
687
+ updated: z
688
+ .number()
689
+ .optional()
690
+ .describe('Unix timestamp when user was last updated'),
691
+ has_2fa: z
692
+ .boolean()
693
+ .optional()
694
+ .describe('True if user has two-factor authentication enabled'),
695
+ })
696
+ .describe('Slack user object with profile and permissions');
697
+ export const SlackMessageSchema = z
698
+ .object({
699
+ type: z.string().describe('Message type (usually "message")'),
700
+ ts: z.string().optional().describe('Message timestamp (unique identifier)'),
701
+ user: z.string().optional().describe('User ID who sent the message'),
702
+ bot_id: z
703
+ .string()
704
+ .optional()
705
+ .describe('Bot ID if message was sent by a bot'),
706
+ bot_profile: z
707
+ .object({
708
+ name: z.string().optional().describe('Bot display name'),
709
+ })
710
+ .optional()
711
+ .describe('Bot profile information if message was sent by a bot'),
712
+ username: z
713
+ .string()
714
+ .optional()
715
+ .describe('Username of the bot or user who sent the message'),
716
+ text: z.string().optional().describe('Message text content'),
717
+ thread_ts: z
718
+ .string()
719
+ .optional()
720
+ .describe('Timestamp of parent message if this is a thread reply'),
721
+ parent_user_id: z
722
+ .string()
723
+ .optional()
724
+ .describe('User ID of thread parent message author'),
725
+ reply_count: z
726
+ .number()
727
+ .optional()
728
+ .describe('Number of replies in this thread'),
729
+ reply_users_count: z
730
+ .number()
731
+ .optional()
732
+ .describe('Number of unique users who replied in thread'),
733
+ latest_reply: z
734
+ .string()
735
+ .optional()
736
+ .describe('Timestamp of most recent reply in thread'),
737
+ reply_users: z
738
+ .array(z.string())
739
+ .optional()
740
+ .describe('Array of user IDs who replied in thread'),
741
+ is_locked: z.boolean().optional().describe('True if thread is locked'),
742
+ subscribed: z
743
+ .boolean()
744
+ .optional()
745
+ .describe('True if current user is subscribed to thread'),
746
+ attachments: z
747
+ .array(z.unknown())
748
+ .optional()
749
+ .describe('Legacy message attachments'),
750
+ blocks: z
751
+ .array(z.unknown())
752
+ .optional()
753
+ .describe('Block Kit structured content'),
754
+ reactions: z
755
+ .array(z.object({
756
+ name: z.string().describe('Emoji name without colons'),
757
+ users: z
758
+ .array(z.string())
759
+ .describe('User IDs who reacted with this emoji'),
760
+ count: z.number().describe('Total count of this reaction'),
761
+ }))
762
+ .optional()
763
+ .describe('Array of emoji reactions on this message'),
764
+ })
765
+ .describe('Slack message object with content and metadata');
766
+ // ============================================================================
767
+ // RESULT SCHEMAS (DISCRIMINATED UNION)
768
+ // ============================================================================
769
+ export const SlackResultSchema = z.discriminatedUnion('operation', [
770
+ z.object({
771
+ operation: z
772
+ .literal('send_message')
773
+ .describe('Send a message to a Slack channel or DM'),
774
+ ok: z.boolean().describe('Whether the Slack API call was successful'),
775
+ channel: z
776
+ .string()
777
+ .optional()
778
+ .describe('Channel ID where the message was sent'),
779
+ ts: z.string().optional().describe('Timestamp of the sent message'),
780
+ message: SlackMessageSchema.optional().describe('Details of the sent message'),
781
+ error: z.string().describe('Error message if operation failed'),
782
+ success: z.boolean().describe('Whether the operation was successful'),
783
+ }),
784
+ z.object({
785
+ operation: z
786
+ .literal('list_channels')
787
+ .describe('List all channels in the Slack workspace'),
788
+ ok: z.boolean().describe('Whether the Slack API call was successful'),
789
+ channels: z
790
+ .array(SlackChannelSchema)
791
+ .optional()
792
+ .describe('Array of channel objects'),
793
+ response_metadata: z
794
+ .object({
795
+ next_cursor: z
796
+ .string()
797
+ .describe('Cursor for pagination to get next set of results'),
798
+ })
799
+ .optional()
800
+ .describe('Metadata for pagination'),
801
+ error: z.string().describe('Error message if operation failed'),
802
+ success: z.boolean().describe('Whether the operation was successful'),
803
+ }),
804
+ z.object({
805
+ operation: z
806
+ .literal('get_channel_info')
807
+ .describe('Get detailed information about a specific channel'),
808
+ ok: z.boolean().describe('Whether the Slack API call was successful'),
809
+ channel: SlackChannelSchema.optional().describe('Channel information object'),
810
+ error: z.string().describe('Error message if operation failed'),
811
+ success: z.boolean().describe('Whether the operation was successful'),
812
+ }),
813
+ z.object({
814
+ operation: z
815
+ .literal('get_user_info')
816
+ .describe('Get detailed information about a specific user'),
817
+ ok: z.boolean().describe('Whether the Slack API call was successful'),
818
+ user: SlackUserSchema.optional().describe('User information object'),
819
+ error: z.string().describe('Error message if operation failed'),
820
+ success: z.boolean().describe('Whether the operation was successful'),
821
+ }),
822
+ z.object({
823
+ operation: z
824
+ .literal('list_users')
825
+ .describe('List all users in the Slack workspace'),
826
+ ok: z.boolean().describe('Whether the Slack API call was successful'),
827
+ members: z
828
+ .array(SlackUserSchema)
829
+ .optional()
830
+ .describe('Array of user objects'),
831
+ response_metadata: z
832
+ .object({
833
+ next_cursor: z
834
+ .string()
835
+ .describe('Cursor for pagination to get next set of results'),
836
+ })
837
+ .optional()
838
+ .describe('Metadata for pagination'),
839
+ error: z.string().describe('Error message if operation failed'),
840
+ success: z.boolean().describe('Whether the operation was successful'),
841
+ }),
842
+ z.object({
843
+ operation: z
844
+ .literal('get_conversation_history')
845
+ .describe('Retrieve message history from a channel or direct message'),
846
+ ok: z.boolean().describe('Whether the Slack API call was successful'),
847
+ messages: z
848
+ .array(SlackMessageSchema)
849
+ .optional()
850
+ .describe('Array of message objects'),
851
+ has_more: z
852
+ .boolean()
853
+ .optional()
854
+ .describe('Whether there are more messages to retrieve'),
855
+ response_metadata: z
856
+ .object({
857
+ next_cursor: z
858
+ .string()
859
+ .describe('Cursor for pagination to get next set of results'),
860
+ })
861
+ .optional()
862
+ .describe('Metadata for pagination'),
863
+ error: z.string().describe('Error message if operation failed'),
864
+ success: z.boolean().describe('Whether the operation was successful'),
865
+ }),
866
+ z.object({
867
+ operation: z
868
+ .literal('get_thread_replies')
869
+ .describe('Retrieve all replies to a thread in a channel'),
870
+ ok: z.boolean().describe('Whether the Slack API call was successful'),
871
+ messages: z
872
+ .array(SlackMessageSchema)
873
+ .optional()
874
+ .describe('Array of message objects in the thread'),
875
+ has_more: z
876
+ .boolean()
877
+ .optional()
878
+ .describe('Whether there are more messages to retrieve'),
879
+ response_metadata: z
880
+ .object({
881
+ next_cursor: z
882
+ .string()
883
+ .describe('Cursor for pagination to get next set of results'),
884
+ })
885
+ .optional()
886
+ .describe('Metadata for pagination'),
887
+ error: z.string().describe('Error message if operation failed'),
888
+ success: z.boolean().describe('Whether the operation was successful'),
889
+ }),
890
+ z.object({
891
+ operation: z
892
+ .literal('update_message')
893
+ .describe('Update an existing message in a channel'),
894
+ ok: z.boolean().describe('Whether the Slack API call was successful'),
895
+ channel: z
896
+ .string()
897
+ .optional()
898
+ .describe('Channel ID where the message was updated'),
899
+ ts: z.string().optional().describe('Timestamp of the updated message'),
900
+ text: z.string().optional().describe('Updated text content of the message'),
901
+ message: SlackMessageSchema.optional().describe('Details of the updated message'),
902
+ error: z.string().describe('Error message if operation failed'),
903
+ success: z.boolean().describe('Whether the operation was successful'),
904
+ }),
905
+ z.object({
906
+ operation: z
907
+ .literal('delete_message')
908
+ .describe('Delete a message from a channel'),
909
+ ok: z.boolean().describe('Whether the Slack API call was successful'),
910
+ channel: z
911
+ .string()
912
+ .optional()
913
+ .describe('Channel ID where the message was deleted'),
914
+ ts: z.string().optional().describe('Timestamp of the deleted message'),
915
+ error: z.string().describe('Error message if operation failed'),
916
+ success: z.boolean().describe('Whether the operation was successful'),
917
+ }),
918
+ z.object({
919
+ operation: z
920
+ .literal('add_reaction')
921
+ .describe('Add an emoji reaction to a message'),
922
+ ok: z.boolean().describe('Whether the Slack API call was successful'),
923
+ error: z.string().describe('Error message if operation failed'),
924
+ success: z.boolean().describe('Whether the operation was successful'),
925
+ }),
926
+ z.object({
927
+ operation: z
928
+ .literal('remove_reaction')
929
+ .describe('Remove an emoji reaction from a message'),
930
+ ok: z.boolean().describe('Whether the Slack API call was successful'),
931
+ error: z.string().describe('Error message if operation failed'),
932
+ success: z.boolean().describe('Whether the operation was successful'),
933
+ }),
934
+ z.object({
935
+ operation: z
936
+ .literal('join_channel')
937
+ .describe('Join a public Slack channel'),
938
+ ok: z.boolean().describe('Whether the Slack API call was successful'),
939
+ channel: SlackChannelSchema.optional().describe('Channel information object after joining'),
940
+ already_in_channel: z
941
+ .boolean()
942
+ .optional()
943
+ .describe('Whether the bot was already a member of the channel'),
944
+ error: z.string().describe('Error message if operation failed'),
945
+ success: z.boolean().describe('Whether the operation was successful'),
946
+ }),
947
+ z.object({
948
+ operation: z
949
+ .literal('upload_file')
950
+ .describe('Upload a file to a Slack channel'),
951
+ ok: z.boolean().describe('Whether the Slack API call was successful'),
952
+ file: z
953
+ .object({
954
+ id: z.string().describe('Unique file identifier'),
955
+ created: z.number().describe('Unix timestamp when file was created'),
956
+ timestamp: z.number().describe('Unix timestamp when file was uploaded'),
957
+ name: z.string().describe('Original filename'),
958
+ title: z.string().optional().describe('File title'),
959
+ mimetype: z.string().describe('MIME type of the file'),
960
+ filetype: z.string().describe('File type extension'),
961
+ pretty_type: z.string().describe('Human-readable file type'),
962
+ user: z.string().describe('User ID who uploaded the file'),
963
+ editable: z.boolean().describe('Whether the file is editable'),
964
+ size: z.number().describe('File size in bytes'),
965
+ mode: z.string().describe('File sharing mode'),
966
+ is_external: z
967
+ .boolean()
968
+ .describe('Whether file is from external source'),
969
+ external_type: z.string().describe('External file type if applicable'),
970
+ is_public: z.boolean().describe('Whether file is publicly accessible'),
971
+ public_url_shared: z.boolean().describe('Whether public URL is shared'),
972
+ display_as_bot: z
973
+ .boolean()
974
+ .describe('Whether file is displayed as uploaded by bot'),
975
+ username: z.string().describe('Username of uploader'),
976
+ url_private: z.string().describe('Private URL to access file'),
977
+ url_private_download: z.string().describe('Private download URL'),
978
+ permalink: z.string().describe('Permanent link to file'),
979
+ permalink_public: z
980
+ .string()
981
+ .optional()
982
+ .describe('Public permanent link'),
983
+ shares: z
984
+ .object({
985
+ public: z
986
+ .record(z.array(z.object({
987
+ reply_users: z
988
+ .array(z.string())
989
+ .describe('User IDs who replied'),
990
+ reply_users_count: z
991
+ .number()
992
+ .describe('Number of unique users who replied'),
993
+ reply_count: z.number().describe('Total number of replies'),
994
+ ts: z.string().describe('Timestamp of the share'),
995
+ channel_name: z.string().describe('Name of the channel'),
996
+ team_id: z.string().describe('Team ID'),
997
+ })))
998
+ .optional()
999
+ .describe('Public channel shares'),
1000
+ private: z
1001
+ .record(z.array(z.object({
1002
+ reply_users: z
1003
+ .array(z.string())
1004
+ .describe('User IDs who replied'),
1005
+ reply_users_count: z
1006
+ .number()
1007
+ .describe('Number of unique users who replied'),
1008
+ reply_count: z.number().describe('Total number of replies'),
1009
+ ts: z.string().describe('Timestamp of the share'),
1010
+ channel_name: z.string().describe('Name of the channel'),
1011
+ team_id: z.string().describe('Team ID'),
1012
+ })))
1013
+ .optional()
1014
+ .describe('Private channel shares'),
1015
+ })
1016
+ .optional()
1017
+ .describe('Information about where file is shared'),
1018
+ channels: z
1019
+ .array(z.string())
1020
+ .optional()
1021
+ .describe('Channel IDs where file is shared'),
1022
+ groups: z
1023
+ .array(z.string())
1024
+ .optional()
1025
+ .describe('Private group IDs where file is shared'),
1026
+ ims: z
1027
+ .array(z.string())
1028
+ .optional()
1029
+ .describe('Direct message IDs where file is shared'),
1030
+ has_rich_preview: z
1031
+ .boolean()
1032
+ .optional()
1033
+ .describe('Whether file has rich preview'),
1034
+ })
1035
+ .optional()
1036
+ .describe('File information object'),
1037
+ error: z.string().describe('Error message if operation failed'),
1038
+ success: z.boolean().describe('Whether the operation was successful'),
1039
+ }),
1040
+ z.object({
1041
+ operation: z
1042
+ .literal('schedule_message')
1043
+ .describe('Schedule a message to be sent at a future time'),
1044
+ ok: z.boolean().describe('Whether the Slack API call was successful'),
1045
+ channel: z
1046
+ .string()
1047
+ .optional()
1048
+ .describe('Channel ID where message will be posted'),
1049
+ scheduled_message_id: z
1050
+ .string()
1051
+ .optional()
1052
+ .describe('Unique identifier for the scheduled message'),
1053
+ post_at: z
1054
+ .number()
1055
+ .optional()
1056
+ .describe('Unix timestamp when message will be posted'),
1057
+ error: z.string().describe('Error message if operation failed'),
1058
+ success: z.boolean().describe('Whether the operation was successful'),
1059
+ }),
1060
+ ]);
1061
+ //# sourceMappingURL=slack.schema.js.map