@venturialstd/slack 0.1.29 → 0.1.30
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +581 -0
- package/dist/clients/slack.client.d.ts +11 -0
- package/dist/clients/slack.client.d.ts.map +1 -0
- package/dist/clients/slack.client.js +58 -0
- package/dist/clients/slack.client.js.map +1 -0
- package/dist/constants/index.d.ts +3 -0
- package/dist/constants/index.d.ts.map +1 -0
- package/dist/constants/index.js +19 -0
- package/dist/constants/index.js.map +1 -0
- package/dist/{slack/constants → constants}/slack.event.constant.d.ts +1 -0
- package/dist/constants/slack.event.constant.d.ts.map +1 -0
- package/dist/constants/slack.event.constant.js.map +1 -0
- package/dist/constants/slack.settings.constant.d.ts +4 -0
- package/dist/constants/slack.settings.constant.d.ts.map +1 -0
- package/dist/{slack/constants/slack.constants.js → constants/slack.settings.constant.js} +2 -2
- package/dist/constants/slack.settings.constant.js.map +1 -0
- package/dist/{slack/controllers → controllers}/slack.webhook.controller.d.ts +1 -0
- package/dist/controllers/slack.webhook.controller.d.ts.map +1 -0
- package/dist/{slack/controllers → controllers}/slack.webhook.controller.js +4 -4
- package/dist/controllers/slack.webhook.controller.js.map +1 -0
- package/dist/{slack/dtos → dtos}/slack-webhook-event.dto.d.ts +1 -0
- package/dist/dtos/slack-webhook-event.dto.d.ts.map +1 -0
- package/dist/dtos/slack-webhook-event.dto.js.map +1 -0
- package/dist/index.d.ts +10 -0
- package/dist/index.d.ts.map +1 -0
- package/dist/index.js +34 -0
- package/dist/index.js.map +1 -0
- package/dist/services/index.d.ts +14 -0
- package/dist/services/index.d.ts.map +1 -0
- package/dist/services/index.js +30 -0
- package/dist/services/index.js.map +1 -0
- package/dist/services/slack-auth.service.d.ts +12 -0
- package/dist/services/slack-auth.service.d.ts.map +1 -0
- package/dist/{slack/services/slack-message.service.js → services/slack-auth.service.js} +14 -14
- package/dist/services/slack-auth.service.js.map +1 -0
- package/dist/services/slack-chat.service.d.ts +18 -0
- package/dist/services/slack-chat.service.d.ts.map +1 -0
- package/dist/services/slack-chat.service.js +110 -0
- package/dist/services/slack-chat.service.js.map +1 -0
- package/dist/services/slack-conversations.service.d.ts +27 -0
- package/dist/services/slack-conversations.service.d.ts.map +1 -0
- package/dist/services/slack-conversations.service.js +200 -0
- package/dist/services/slack-conversations.service.js.map +1 -0
- package/dist/services/slack-dnd.service.d.ts +15 -0
- package/dist/services/slack-dnd.service.d.ts.map +1 -0
- package/dist/services/slack-dnd.service.js +80 -0
- package/dist/services/slack-dnd.service.js.map +1 -0
- package/dist/services/slack-emoji.service.d.ts +11 -0
- package/dist/services/slack-emoji.service.d.ts.map +1 -0
- package/dist/services/slack-emoji.service.js +40 -0
- package/dist/services/slack-emoji.service.js.map +1 -0
- package/dist/services/slack-files.service.d.ts +29 -0
- package/dist/services/slack-files.service.d.ts.map +1 -0
- package/dist/services/slack-files.service.js +175 -0
- package/dist/services/slack-files.service.js.map +1 -0
- package/dist/services/slack-pins.service.d.ts +13 -0
- package/dist/services/slack-pins.service.d.ts.map +1 -0
- package/dist/{slack/services/slack-channel.service.js → services/slack-pins.service.js} +18 -17
- package/dist/services/slack-pins.service.js.map +1 -0
- package/dist/services/slack-reactions.service.d.ts +14 -0
- package/dist/services/slack-reactions.service.d.ts.map +1 -0
- package/dist/services/slack-reactions.service.js +70 -0
- package/dist/services/slack-reactions.service.js.map +1 -0
- package/dist/services/slack-reminders.service.d.ts +15 -0
- package/dist/services/slack-reminders.service.d.ts.map +1 -0
- package/dist/services/slack-reminders.service.js +80 -0
- package/dist/services/slack-reminders.service.js.map +1 -0
- package/dist/services/slack-search.service.d.ts +13 -0
- package/dist/services/slack-search.service.d.ts.map +1 -0
- package/dist/services/slack-search.service.js +60 -0
- package/dist/services/slack-search.service.js.map +1 -0
- package/dist/services/slack-stars.service.d.ts +28 -0
- package/dist/services/slack-stars.service.d.ts.map +1 -0
- package/dist/services/slack-stars.service.js +77 -0
- package/dist/services/slack-stars.service.js.map +1 -0
- package/dist/services/slack-team.service.d.ts +15 -0
- package/dist/services/slack-team.service.d.ts.map +1 -0
- package/dist/services/slack-team.service.js +80 -0
- package/dist/services/slack-team.service.js.map +1 -0
- package/dist/services/slack-users.service.d.ts +20 -0
- package/dist/services/slack-users.service.d.ts.map +1 -0
- package/dist/services/slack-users.service.js +130 -0
- package/dist/services/slack-users.service.js.map +1 -0
- package/dist/services/slack-views.service.d.ts +14 -0
- package/dist/services/slack-views.service.d.ts.map +1 -0
- package/dist/services/slack-views.service.js +70 -0
- package/dist/services/slack-views.service.js.map +1 -0
- package/dist/services/slack-workflows.service.d.ts +28 -0
- package/dist/services/slack-workflows.service.d.ts.map +1 -0
- package/dist/services/slack-workflows.service.js +77 -0
- package/dist/services/slack-workflows.service.js.map +1 -0
- package/dist/settings/slack.settings.d.ts +3 -0
- package/dist/settings/slack.settings.d.ts.map +1 -0
- package/dist/settings/slack.settings.js +19 -0
- package/dist/settings/slack.settings.js.map +1 -0
- package/dist/slack.module.d.ts +3 -0
- package/dist/slack.module.d.ts.map +1 -0
- package/dist/slack.module.js +57 -0
- package/dist/slack.module.js.map +1 -0
- package/dist/types/slack.config.type.d.ts +4 -0
- package/dist/types/slack.config.type.d.ts.map +1 -0
- package/dist/{slack/interfaces/slack-interface.js → types/slack.config.type.js} +1 -1
- package/dist/types/slack.config.type.js.map +1 -0
- package/dist/types/slack.event.type.d.ts +7 -0
- package/dist/types/slack.event.type.d.ts.map +1 -0
- package/dist/types/slack.event.type.js.map +1 -0
- package/package.json +16 -13
- package/dist/slack/clients/slack.client.d.ts +0 -13
- package/dist/slack/clients/slack.client.js +0 -92
- package/dist/slack/clients/slack.client.js.map +0 -1
- package/dist/slack/constants/slack.constants.d.ts +0 -3
- package/dist/slack/constants/slack.constants.js.map +0 -1
- package/dist/slack/constants/slack.event.constant.js.map +0 -1
- package/dist/slack/controllers/slack.webhook.controller.js.map +0 -1
- package/dist/slack/dtos/slack-webhook-event.dto.js.map +0 -1
- package/dist/slack/index.d.ts +0 -7
- package/dist/slack/index.js +0 -16
- package/dist/slack/index.js.map +0 -1
- package/dist/slack/interfaces/slack-interface.d.ts +0 -12
- package/dist/slack/interfaces/slack-interface.js.map +0 -1
- package/dist/slack/services/slack-channel.service.d.ts +0 -10
- package/dist/slack/services/slack-channel.service.js.map +0 -1
- package/dist/slack/services/slack-message.service.d.ts +0 -9
- package/dist/slack/services/slack-message.service.js.map +0 -1
- package/dist/slack/slack.module.d.ts +0 -2
- package/dist/slack/slack.module.js +0 -28
- package/dist/slack/slack.module.js.map +0 -1
- package/dist/slack/tsconfig.build.tsbuildinfo +0 -1
- package/dist/slack/types/slack.event.type.d.ts +0 -20
- package/dist/slack/types/slack.event.type.js.map +0 -1
- /package/dist/{slack/constants → constants}/slack.event.constant.js +0 -0
- /package/dist/{slack/dtos → dtos}/slack-webhook-event.dto.js +0 -0
- /package/dist/{slack/types → types}/slack.event.type.js +0 -0
package/README.md
ADDED
|
@@ -0,0 +1,581 @@
|
|
|
1
|
+
# @venturialstd/slack
|
|
2
|
+
|
|
3
|
+
A comprehensive **NestJS module for Slack Web API**, developed by **Venturial**, that provides full integration with Slack's platform. This module enables seamless messaging, file management, user interactions, and webhook handling for Slack workspaces.
|
|
4
|
+
|
|
5
|
+
---
|
|
6
|
+
|
|
7
|
+
## Features
|
|
8
|
+
|
|
9
|
+
- **Chat Operations**: Post, update, delete, and schedule messages with full Block Kit support
|
|
10
|
+
- **Conversation Management**: Create, list, archive, and manage channels and conversations
|
|
11
|
+
- **User Management**: List users, get user info, manage profiles, and handle presence
|
|
12
|
+
- **File Operations**: Upload, download, list, and manage files with remote file support
|
|
13
|
+
- **Reactions**: Add, remove, and manage emoji reactions on messages
|
|
14
|
+
- **Pins**: Pin important messages to channels
|
|
15
|
+
- **Reminders**: Create and manage reminders for users
|
|
16
|
+
- **Search**: Search messages and files across the workspace
|
|
17
|
+
- **Team Information**: Access team details, billing info, and access logs
|
|
18
|
+
- **Views & Modals**: Open, publish, push, and update Slack views and modals
|
|
19
|
+
- **Webhooks**: Built-in webhook controller for receiving Slack events
|
|
20
|
+
- **DND Management**: Manage Do Not Disturb settings
|
|
21
|
+
- **Emoji Management**: List custom emojis in the workspace
|
|
22
|
+
- **Type Safety**: Full TypeScript support with comprehensive type definitions
|
|
23
|
+
- **Flexible Configuration**: Support for per-request configuration or global settings
|
|
24
|
+
|
|
25
|
+
---
|
|
26
|
+
|
|
27
|
+
## Installation
|
|
28
|
+
|
|
29
|
+
```bash
|
|
30
|
+
npm install @venturialstd/slack
|
|
31
|
+
# or
|
|
32
|
+
yarn add @venturialstd/slack
|
|
33
|
+
```
|
|
34
|
+
|
|
35
|
+
### Peer Dependencies
|
|
36
|
+
|
|
37
|
+
This package requires the following peer dependencies:
|
|
38
|
+
|
|
39
|
+
```bash
|
|
40
|
+
npm install @nestjs/common@^9 || ^10 || ^11 @nestjs/event-emitter@^3.0.0 @venturialstd/core@^2.0.0
|
|
41
|
+
```
|
|
42
|
+
|
|
43
|
+
The package also requires `@slack/web-api` as a dependency, which is automatically installed.
|
|
44
|
+
|
|
45
|
+
---
|
|
46
|
+
|
|
47
|
+
## Basic Usage
|
|
48
|
+
|
|
49
|
+
### 1. Import the Module
|
|
50
|
+
|
|
51
|
+
```typescript
|
|
52
|
+
import { Module } from '@nestjs/common';
|
|
53
|
+
import { SlackModule } from '@venturialstd/slack';
|
|
54
|
+
|
|
55
|
+
@Module({
|
|
56
|
+
imports: [
|
|
57
|
+
SlackModule,
|
|
58
|
+
],
|
|
59
|
+
})
|
|
60
|
+
export class AppModule {}
|
|
61
|
+
```
|
|
62
|
+
|
|
63
|
+
### 2. Inject and Use Services
|
|
64
|
+
|
|
65
|
+
```typescript
|
|
66
|
+
import { Injectable } from '@nestjs/common';
|
|
67
|
+
import {
|
|
68
|
+
SlackChatService,
|
|
69
|
+
SlackConversationsService,
|
|
70
|
+
SlackUsersService,
|
|
71
|
+
SlackFilesService,
|
|
72
|
+
} from '@venturialstd/slack';
|
|
73
|
+
|
|
74
|
+
@Injectable()
|
|
75
|
+
export class NotificationService {
|
|
76
|
+
constructor(
|
|
77
|
+
private readonly chatService: SlackChatService,
|
|
78
|
+
private readonly conversationsService: SlackConversationsService,
|
|
79
|
+
private readonly usersService: SlackUsersService,
|
|
80
|
+
private readonly filesService: SlackFilesService,
|
|
81
|
+
) {}
|
|
82
|
+
|
|
83
|
+
async sendNotification(channelId: string, message: string) {
|
|
84
|
+
// Send a message to a channel
|
|
85
|
+
const result = await this.chatService.postMessage(null, {
|
|
86
|
+
channel: channelId,
|
|
87
|
+
text: message,
|
|
88
|
+
});
|
|
89
|
+
|
|
90
|
+
return result;
|
|
91
|
+
}
|
|
92
|
+
|
|
93
|
+
async listChannels() {
|
|
94
|
+
// List all channels
|
|
95
|
+
const result = await this.conversationsService.list(null, {
|
|
96
|
+
types: 'public_channel,private_channel',
|
|
97
|
+
});
|
|
98
|
+
|
|
99
|
+
return result;
|
|
100
|
+
}
|
|
101
|
+
|
|
102
|
+
async getUserInfo(userId: string) {
|
|
103
|
+
// Get user information
|
|
104
|
+
const result = await this.usersService.info(null, {
|
|
105
|
+
user: userId,
|
|
106
|
+
});
|
|
107
|
+
|
|
108
|
+
return result;
|
|
109
|
+
}
|
|
110
|
+
}
|
|
111
|
+
```
|
|
112
|
+
|
|
113
|
+
### 3. Using Custom Configuration
|
|
114
|
+
|
|
115
|
+
You can pass a custom configuration for each request:
|
|
116
|
+
|
|
117
|
+
```typescript
|
|
118
|
+
import { SlackConfig } from '@venturialstd/slack';
|
|
119
|
+
|
|
120
|
+
@Injectable()
|
|
121
|
+
export class MultiWorkspaceService {
|
|
122
|
+
constructor(private readonly chatService: SlackChatService) {}
|
|
123
|
+
|
|
124
|
+
async sendToWorkspace(workspaceToken: string, channelId: string, message: string) {
|
|
125
|
+
const config: SlackConfig = {
|
|
126
|
+
botToken: workspaceToken,
|
|
127
|
+
};
|
|
128
|
+
|
|
129
|
+
return await this.chatService.postMessage(config, {
|
|
130
|
+
channel: channelId,
|
|
131
|
+
text: message,
|
|
132
|
+
});
|
|
133
|
+
}
|
|
134
|
+
}
|
|
135
|
+
```
|
|
136
|
+
|
|
137
|
+
---
|
|
138
|
+
|
|
139
|
+
## Configuration
|
|
140
|
+
|
|
141
|
+
### Settings-Based Configuration
|
|
142
|
+
|
|
143
|
+
The module uses `@venturialstd/core` SettingsModule for configuration. Configure the bot token in your settings:
|
|
144
|
+
|
|
145
|
+
**Setting Key**: `GLOBAL:SLACK:GENERAL:BOT_TOKEN`
|
|
146
|
+
|
|
147
|
+
**Setting Type**: `SECRET`
|
|
148
|
+
|
|
149
|
+
**Description**: Bot User OAuth Token for Slack API authentication. Required for all API requests.
|
|
150
|
+
|
|
151
|
+
### Environment Variables
|
|
152
|
+
|
|
153
|
+
You can also configure the bot token through your application's settings system. The module will automatically use the configured token when no custom config is provided.
|
|
154
|
+
|
|
155
|
+
### Custom Configuration
|
|
156
|
+
|
|
157
|
+
For multi-workspace scenarios or dynamic token management, you can pass a `SlackConfig` object to any service method:
|
|
158
|
+
|
|
159
|
+
```typescript
|
|
160
|
+
const config: SlackConfig = {
|
|
161
|
+
botToken: 'xoxb-your-bot-token',
|
|
162
|
+
};
|
|
163
|
+
|
|
164
|
+
await chatService.postMessage(config, { channel: 'C123', text: 'Hello' });
|
|
165
|
+
```
|
|
166
|
+
|
|
167
|
+
---
|
|
168
|
+
|
|
169
|
+
## API Reference
|
|
170
|
+
|
|
171
|
+
All service methods follow the pattern:
|
|
172
|
+
```typescript
|
|
173
|
+
async methodName(config: SlackConfig | null = null, args: MethodArguments)
|
|
174
|
+
```
|
|
175
|
+
|
|
176
|
+
The `config` parameter is optional. If `null` or not provided, the module uses the token from settings.
|
|
177
|
+
|
|
178
|
+
### SlackChatService
|
|
179
|
+
|
|
180
|
+
Handles all chat-related operations.
|
|
181
|
+
|
|
182
|
+
| Method | Description | Arguments Type |
|
|
183
|
+
|--------|-------------|----------------|
|
|
184
|
+
| `postMessage(config, args)` | Post a message to a channel | `ChatPostMessageArguments` |
|
|
185
|
+
| `update(config, args)` | Update an existing message | `ChatUpdateArguments` |
|
|
186
|
+
| `delete(config, args)` | Delete a message | `ChatDeleteArguments` |
|
|
187
|
+
| `scheduleMessage(config, args)` | Schedule a message for later | `ChatScheduleMessageArguments` |
|
|
188
|
+
| `getPermalink(config, args)` | Get a permalink for a message | `ChatGetPermalinkArguments` |
|
|
189
|
+
| `unfurl(config, args)` | Unfurl links in a message | `ChatUnfurlArguments` |
|
|
190
|
+
| `scheduledMessagesList(config, args)` | List scheduled messages | `ChatScheduledMessagesListArguments` |
|
|
191
|
+
| `deleteScheduledMessage(config, args)` | Delete a scheduled message | `ChatDeleteScheduledMessageArguments` |
|
|
192
|
+
|
|
193
|
+
**Example:**
|
|
194
|
+
```typescript
|
|
195
|
+
await chatService.postMessage(null, {
|
|
196
|
+
channel: 'C1234567890',
|
|
197
|
+
text: 'Hello, world!',
|
|
198
|
+
blocks: [
|
|
199
|
+
{
|
|
200
|
+
type: 'section',
|
|
201
|
+
text: {
|
|
202
|
+
type: 'mrkdwn',
|
|
203
|
+
text: 'This is a *formatted* message',
|
|
204
|
+
},
|
|
205
|
+
},
|
|
206
|
+
],
|
|
207
|
+
});
|
|
208
|
+
```
|
|
209
|
+
|
|
210
|
+
### SlackConversationsService
|
|
211
|
+
|
|
212
|
+
Manages channels and conversations.
|
|
213
|
+
|
|
214
|
+
| Method | Description | Arguments Type |
|
|
215
|
+
|--------|-------------|----------------|
|
|
216
|
+
| `list(config, args)` | List conversations | `ConversationsListArguments` |
|
|
217
|
+
| `create(config, args)` | Create a new conversation | `ConversationsCreateArguments` |
|
|
218
|
+
| `history(config, args)` | Get conversation history | `ConversationsHistoryArguments` |
|
|
219
|
+
| `replies(config, args)` | Get thread replies | `ConversationsRepliesArguments` |
|
|
220
|
+
| `info(config, args)` | Get conversation info | `ConversationsInfoArguments` |
|
|
221
|
+
| `invite(config, args)` | Invite users to conversation | `ConversationsInviteArguments` |
|
|
222
|
+
| `kick(config, args)` | Remove user from conversation | `ConversationsKickArguments` |
|
|
223
|
+
| `join(config, args)` | Join a conversation | `ConversationsJoinArguments` |
|
|
224
|
+
| `leave(config, args)` | Leave a conversation | `ConversationsLeaveArguments` |
|
|
225
|
+
| `members(config, args)` | Get conversation members | `ConversationsMembersArguments` |
|
|
226
|
+
| `open(config, args)` | Open a direct message | `ConversationsOpenArguments` |
|
|
227
|
+
| `rename(config, args)` | Rename a conversation | `ConversationsRenameArguments` |
|
|
228
|
+
| `setPurpose(config, args)` | Set conversation purpose | `ConversationsSetPurposeArguments` |
|
|
229
|
+
| `setTopic(config, args)` | Set conversation topic | `ConversationsSetTopicArguments` |
|
|
230
|
+
| `archive(config, args)` | Archive a conversation | `ConversationsArchiveArguments` |
|
|
231
|
+
| `unarchive(config, args)` | Unarchive a conversation | `ConversationsUnarchiveArguments` |
|
|
232
|
+
| `mark(config, args)` | Mark conversation as read | `ConversationsMarkArguments` |
|
|
233
|
+
|
|
234
|
+
**Example:**
|
|
235
|
+
```typescript
|
|
236
|
+
// List all public channels
|
|
237
|
+
const channels = await conversationsService.list(null, {
|
|
238
|
+
types: 'public_channel',
|
|
239
|
+
limit: 100,
|
|
240
|
+
});
|
|
241
|
+
|
|
242
|
+
// Create a new channel
|
|
243
|
+
const newChannel = await conversationsService.create(null, {
|
|
244
|
+
name: 'my-new-channel',
|
|
245
|
+
is_private: false,
|
|
246
|
+
});
|
|
247
|
+
```
|
|
248
|
+
|
|
249
|
+
### SlackUsersService
|
|
250
|
+
|
|
251
|
+
Manages user information and profiles.
|
|
252
|
+
|
|
253
|
+
| Method | Description | Arguments Type |
|
|
254
|
+
|--------|-------------|----------------|
|
|
255
|
+
| `list(config, args)` | List all users | `UsersListArguments` |
|
|
256
|
+
| `info(config, args)` | Get user information | `UsersInfoArguments` |
|
|
257
|
+
| `lookupByEmail(config, args)` | Find user by email | `UsersLookupByEmailArguments` |
|
|
258
|
+
| `setPhoto(config, args)` | Set user photo | `UsersSetPhotoArguments` |
|
|
259
|
+
| `setPresence(config, args)` | Set user presence | `UsersSetPresenceArguments` |
|
|
260
|
+
| `getPresence(config, args)` | Get user presence | `UsersGetPresenceArguments` |
|
|
261
|
+
| `identity(config, args)` | Get user identity | `UsersIdentityArguments` |
|
|
262
|
+
| `profileGet(config, args)` | Get user profile | `UsersProfileGetArguments` |
|
|
263
|
+
| `profileSet(config, args)` | Set user profile | `UsersProfileSetArguments` |
|
|
264
|
+
| `deletePhoto(config, args)` | Delete user photo | `UsersDeletePhotoArguments` |
|
|
265
|
+
|
|
266
|
+
**Example:**
|
|
267
|
+
```typescript
|
|
268
|
+
// Get user info
|
|
269
|
+
const user = await usersService.info(null, {
|
|
270
|
+
user: 'U1234567890',
|
|
271
|
+
});
|
|
272
|
+
|
|
273
|
+
// Lookup user by email
|
|
274
|
+
const userByEmail = await usersService.lookupByEmail(null, {
|
|
275
|
+
email: 'user@example.com',
|
|
276
|
+
});
|
|
277
|
+
```
|
|
278
|
+
|
|
279
|
+
### SlackFilesService
|
|
280
|
+
|
|
281
|
+
Handles file operations.
|
|
282
|
+
|
|
283
|
+
| Method | Description | Arguments Type |
|
|
284
|
+
|--------|-------------|----------------|
|
|
285
|
+
| `upload(config, args)` | Upload a file (⚠️ **Deprecated** - Use `getUploadURLExternal` + `completeUploadExternal` instead. Retired Nov 12, 2025) | `FilesUploadArguments` |
|
|
286
|
+
| `info(config, args)` | Get file information | `FilesInfoArguments` |
|
|
287
|
+
| `list(config, args)` | List files | `FilesListArguments` |
|
|
288
|
+
| `delete(config, args)` | Delete a file | `FilesDeleteArguments` |
|
|
289
|
+
| `revokePublicURL(config, args)` | Revoke public URL | `FilesRevokePublicURLArguments` |
|
|
290
|
+
| `sharedPublicURL(config, args)` | Share public URL | `FilesSharedPublicURLArguments` |
|
|
291
|
+
| `getUploadURLExternal(config, args)` | Get external upload URL | `FilesGetUploadURLExternalArguments` |
|
|
292
|
+
| `completeUploadExternal(config, args)` | Complete external upload | `FilesCompleteUploadExternalArguments` |
|
|
293
|
+
| `remoteInfo(config, args)` | Get remote file info | `FilesRemoteInfoArguments` |
|
|
294
|
+
| `remoteList(config, args)` | List remote files | `FilesRemoteListArguments` |
|
|
295
|
+
| `remoteAdd(config, args)` | Add remote file | `FilesRemoteAddArguments` |
|
|
296
|
+
| `remoteUpdate(config, args)` | Update remote file | `FilesRemoteUpdateArguments` |
|
|
297
|
+
| `remoteRemove(config, args)` | Remove remote file | `FilesRemoteRemoveArguments` |
|
|
298
|
+
| `remoteShare(config, args)` | Share remote file | `FilesRemoteShareArguments` |
|
|
299
|
+
|
|
300
|
+
**Example:**
|
|
301
|
+
```typescript
|
|
302
|
+
// Upload a file using the new recommended method
|
|
303
|
+
// Step 1: Get upload URL
|
|
304
|
+
const uploadUrl = await filesService.getUploadURLExternal(null, {
|
|
305
|
+
filename: 'document.pdf',
|
|
306
|
+
length: fileSize,
|
|
307
|
+
});
|
|
308
|
+
|
|
309
|
+
// Step 2: Upload file to the URL (using fetch or similar)
|
|
310
|
+
await fetch(uploadUrl.upload_url, {
|
|
311
|
+
method: 'POST',
|
|
312
|
+
body: fileBuffer,
|
|
313
|
+
headers: uploadUrl.headers,
|
|
314
|
+
});
|
|
315
|
+
|
|
316
|
+
// Step 3: Complete the upload
|
|
317
|
+
const file = await filesService.completeUploadExternal(null, {
|
|
318
|
+
files: [{
|
|
319
|
+
id: uploadUrl.file_id,
|
|
320
|
+
title: 'Important Document',
|
|
321
|
+
}],
|
|
322
|
+
channel_id: 'C1234567890',
|
|
323
|
+
});
|
|
324
|
+
|
|
325
|
+
// Note: The old upload() method is deprecated and will be retired Nov 12, 2025
|
|
326
|
+
```
|
|
327
|
+
|
|
328
|
+
### SlackReactionsService
|
|
329
|
+
|
|
330
|
+
Manages emoji reactions.
|
|
331
|
+
|
|
332
|
+
| Method | Description | Arguments Type |
|
|
333
|
+
|--------|-------------|----------------|
|
|
334
|
+
| `add(config, args)` | Add a reaction | `ReactionsAddArguments` |
|
|
335
|
+
| `get(config, args)` | Get reactions for an item | `ReactionsGetArguments` |
|
|
336
|
+
| `list(config, args)` | List reactions by user | `ReactionsListArguments` |
|
|
337
|
+
| `remove(config, args)` | Remove a reaction | `ReactionsRemoveArguments` |
|
|
338
|
+
|
|
339
|
+
**Example:**
|
|
340
|
+
```typescript
|
|
341
|
+
// Add a reaction
|
|
342
|
+
await reactionsService.add(null, {
|
|
343
|
+
channel: 'C1234567890',
|
|
344
|
+
timestamp: '1234567890.123456',
|
|
345
|
+
name: 'thumbsup',
|
|
346
|
+
});
|
|
347
|
+
```
|
|
348
|
+
|
|
349
|
+
### SlackRemindersService
|
|
350
|
+
|
|
351
|
+
Manages reminders.
|
|
352
|
+
|
|
353
|
+
| Method | Description | Arguments Type |
|
|
354
|
+
|--------|-------------|----------------|
|
|
355
|
+
| `add(config, args)` | Create a reminder | `RemindersAddArguments` |
|
|
356
|
+
| `complete(config, args)` | Complete a reminder | `RemindersCompleteArguments` |
|
|
357
|
+
| `delete(config, args)` | Delete a reminder | `RemindersDeleteArguments` |
|
|
358
|
+
| `info(config, args)` | Get reminder info | `RemindersInfoArguments` |
|
|
359
|
+
| `list(config, args)` | List reminders | `RemindersListArguments` |
|
|
360
|
+
|
|
361
|
+
### SlackPinsService
|
|
362
|
+
|
|
363
|
+
Manages pinned messages.
|
|
364
|
+
|
|
365
|
+
| Method | Description | Arguments Type |
|
|
366
|
+
|--------|-------------|----------------|
|
|
367
|
+
| `add(config, args)` | Pin an item | `PinsAddArguments` |
|
|
368
|
+
| `list(config, args)` | List pinned items | `PinsListArguments` |
|
|
369
|
+
| `remove(config, args)` | Unpin an item | `PinsRemoveArguments` |
|
|
370
|
+
|
|
371
|
+
### SlackDndService
|
|
372
|
+
|
|
373
|
+
Manages Do Not Disturb settings.
|
|
374
|
+
|
|
375
|
+
| Method | Description | Arguments Type |
|
|
376
|
+
|--------|-------------|----------------|
|
|
377
|
+
| `info(config, args)` | Get DND info | `DndInfoArguments` |
|
|
378
|
+
| `setSnooze(config, args)` | Set DND snooze | `DndSetSnoozeArguments` |
|
|
379
|
+
| `endDnd(config, args)` | End DND | `DndEndDndArguments` |
|
|
380
|
+
| `endSnooze(config, args)` | End DND snooze | `DndEndSnoozeArguments` |
|
|
381
|
+
| `teamInfo(config, args)` | Get team DND info | `DndTeamInfoArguments` |
|
|
382
|
+
|
|
383
|
+
### SlackEmojiService
|
|
384
|
+
|
|
385
|
+
Manages emoji.
|
|
386
|
+
|
|
387
|
+
| Method | Description | Arguments Type |
|
|
388
|
+
|--------|-------------|----------------|
|
|
389
|
+
| `list(config, args)` | List custom emojis | `EmojiListArguments` |
|
|
390
|
+
|
|
391
|
+
### SlackTeamService
|
|
392
|
+
|
|
393
|
+
Accesses team information.
|
|
394
|
+
|
|
395
|
+
| Method | Description | Arguments Type |
|
|
396
|
+
|--------|-------------|----------------|
|
|
397
|
+
| `info(config, args)` | Get team info | `TeamInfoArguments` |
|
|
398
|
+
| `billableInfo(config, args)` | Get billable info | `TeamBillableInfoArguments` |
|
|
399
|
+
| `integrationLogs(config, args)` | Get integration logs | `TeamIntegrationLogsArguments` |
|
|
400
|
+
| `profileGet(config, args)` | Get team profile | `TeamProfileGetArguments` |
|
|
401
|
+
| `accessLogs(config, args)` | Get access logs | `TeamAccessLogsArguments` |
|
|
402
|
+
|
|
403
|
+
### SlackSearchService
|
|
404
|
+
|
|
405
|
+
Searches messages and files.
|
|
406
|
+
|
|
407
|
+
| Method | Description | Arguments Type |
|
|
408
|
+
|--------|-------------|----------------|
|
|
409
|
+
| `messages(config, args)` | Search messages | `SearchMessagesArguments` |
|
|
410
|
+
| `files(config, args)` | Search files | `SearchFilesArguments` |
|
|
411
|
+
| `all(config, args)` | Search all | `SearchAllArguments` |
|
|
412
|
+
|
|
413
|
+
**Example:**
|
|
414
|
+
```typescript
|
|
415
|
+
// Search for messages
|
|
416
|
+
const results = await searchService.messages(null, {
|
|
417
|
+
query: 'important',
|
|
418
|
+
sort: 'timestamp',
|
|
419
|
+
count: 20,
|
|
420
|
+
});
|
|
421
|
+
```
|
|
422
|
+
|
|
423
|
+
### SlackViewsService
|
|
424
|
+
|
|
425
|
+
Manages views and modals.
|
|
426
|
+
|
|
427
|
+
| Method | Description | Arguments Type |
|
|
428
|
+
|--------|-------------|----------------|
|
|
429
|
+
| `open(config, args)` | Open a view | `ViewsOpenArguments` |
|
|
430
|
+
| `publish(config, args)` | Publish a view | `ViewsPublishArguments` |
|
|
431
|
+
| `push(config, args)` | Push a view | `ViewsPushArguments` |
|
|
432
|
+
| `update(config, args)` | Update a view | `ViewsUpdateArguments` |
|
|
433
|
+
|
|
434
|
+
### SlackAuthService
|
|
435
|
+
|
|
436
|
+
Handles authentication.
|
|
437
|
+
|
|
438
|
+
| Method | Description | Arguments Type |
|
|
439
|
+
|--------|-------------|----------------|
|
|
440
|
+
| `test(config, args)` | Test authentication | `AuthTestArguments` |
|
|
441
|
+
| `revoke(config, args)` | Revoke token | `AuthRevokeArguments` |
|
|
442
|
+
|
|
443
|
+
---
|
|
444
|
+
|
|
445
|
+
## Webhooks
|
|
446
|
+
|
|
447
|
+
The module includes a built-in webhook controller for receiving Slack events.
|
|
448
|
+
|
|
449
|
+
### Endpoint
|
|
450
|
+
|
|
451
|
+
`POST /general/slack/webhook`
|
|
452
|
+
|
|
453
|
+
### Configuration
|
|
454
|
+
|
|
455
|
+
Configure your Slack app's Event Subscriptions to point to this endpoint.
|
|
456
|
+
|
|
457
|
+
### Event Handling
|
|
458
|
+
|
|
459
|
+
The controller automatically handles:
|
|
460
|
+
- **URL Verification**: Responds to Slack's challenge during setup
|
|
461
|
+
- **Event Callbacks**: Emits events via `@nestjs/event-emitter`
|
|
462
|
+
|
|
463
|
+
### Listening to Events
|
|
464
|
+
|
|
465
|
+
```typescript
|
|
466
|
+
import { Injectable } from '@nestjs/common';
|
|
467
|
+
import { OnEvent } from '@nestjs/event-emitter';
|
|
468
|
+
import { EVENT_EMITTER_SLACK_EVENTS } from '@venturialstd/slack';
|
|
469
|
+
|
|
470
|
+
@Injectable()
|
|
471
|
+
export class SlackEventHandler {
|
|
472
|
+
@OnEvent(EVENT_EMITTER_SLACK_EVENTS.WEBHOOK_INCOMING_MESSAGE)
|
|
473
|
+
handleIncomingMessage(payload: { data: SlackMessageEvent }) {
|
|
474
|
+
console.log('New message:', payload.data);
|
|
475
|
+
// Handle the message
|
|
476
|
+
}
|
|
477
|
+
}
|
|
478
|
+
```
|
|
479
|
+
|
|
480
|
+
### Available Events
|
|
481
|
+
|
|
482
|
+
- `WEBHOOK_INCOMING_MESSAGE`: Emitted when a message event is received
|
|
483
|
+
|
|
484
|
+
---
|
|
485
|
+
|
|
486
|
+
## Types
|
|
487
|
+
|
|
488
|
+
### SlackConfig
|
|
489
|
+
|
|
490
|
+
```typescript
|
|
491
|
+
interface SlackConfig {
|
|
492
|
+
botToken?: string;
|
|
493
|
+
}
|
|
494
|
+
```
|
|
495
|
+
|
|
496
|
+
### SlackMessageEvent
|
|
497
|
+
|
|
498
|
+
```typescript
|
|
499
|
+
interface SlackMessageEvent {
|
|
500
|
+
type: string;
|
|
501
|
+
user?: string;
|
|
502
|
+
text?: string;
|
|
503
|
+
channel: string;
|
|
504
|
+
ts: string;
|
|
505
|
+
thread_ts?: string;
|
|
506
|
+
bot_id?: string;
|
|
507
|
+
client_msg_id?: string;
|
|
508
|
+
team?: string;
|
|
509
|
+
event_ts?: string;
|
|
510
|
+
channel_type?: string;
|
|
511
|
+
blocks?: unknown[];
|
|
512
|
+
}
|
|
513
|
+
```
|
|
514
|
+
|
|
515
|
+
All argument types are imported from `@slack/web-api` and are fully typed.
|
|
516
|
+
|
|
517
|
+
---
|
|
518
|
+
|
|
519
|
+
## Notes
|
|
520
|
+
|
|
521
|
+
### Rate Limiting
|
|
522
|
+
|
|
523
|
+
Slack API has rate limits. The module doesn't implement rate limiting internally. Consider implementing rate limiting in your application if you expect high-volume usage.
|
|
524
|
+
|
|
525
|
+
### Error Handling
|
|
526
|
+
|
|
527
|
+
All service methods include error handling and logging. Errors are logged using the `AppLogger` and then re-thrown for your application to handle.
|
|
528
|
+
|
|
529
|
+
### Token Management
|
|
530
|
+
|
|
531
|
+
- If no `config` is provided, the module uses the token from settings
|
|
532
|
+
- If `config` is provided with a `botToken`, it uses that token for the request
|
|
533
|
+
- The client caches the WebClient instance when using settings-based configuration
|
|
534
|
+
- Each request with a custom config creates a new client instance
|
|
535
|
+
|
|
536
|
+
### Type Safety
|
|
537
|
+
|
|
538
|
+
All methods use TypeScript types from `@slack/web-api`, ensuring type safety and IntelliSense support.
|
|
539
|
+
|
|
540
|
+
### Block Kit Support
|
|
541
|
+
|
|
542
|
+
The chat service fully supports Slack's Block Kit for rich message formatting. See [Slack Block Kit documentation](https://api.slack.com/block-kit) for details.
|
|
543
|
+
|
|
544
|
+
### Deprecated Features
|
|
545
|
+
|
|
546
|
+
- **files.upload**: The `files.upload` method is deprecated by Slack. Use `getUploadURLExternal` and `completeUploadExternal` instead for better reliability with larger files. The method will be retired on November 12, 2025. For new apps created after May 16, 2024, this method is not available. See [Slack's migration guide](https://api.slack.com/changelog/2024-04-a-better-way-to-upload-files-is-here-to-stay) for details.
|
|
547
|
+
|
|
548
|
+
### Removed Features
|
|
549
|
+
|
|
550
|
+
The following services have been removed from this module due to Slack API deprecation:
|
|
551
|
+
|
|
552
|
+
- **SlackStarsService**: The Stars API was deprecated by Slack in favor of "Save it for Later" feature. There is no public API available for the new "Later" feature. The Stars API methods no longer reflect what users see in Slack's UI.
|
|
553
|
+
|
|
554
|
+
- **SlackWorkflowsService**: The Workflows API methods (`stepCompleted`, `stepFailed`, `updateStep`) were retired by Slack on September 26, 2024. Slack now uses custom functions in their new automation platform instead. See [Slack's changelog](https://api.slack.com/changelog/2023-08-workflow-steps-from-apps-step-back) for migration guidance.
|
|
555
|
+
|
|
556
|
+
### Best Practices
|
|
557
|
+
|
|
558
|
+
1. **Use Settings for Default Token**: Configure the bot token in settings for most use cases
|
|
559
|
+
2. **Custom Config for Multi-Workspace**: Use `SlackConfig` for scenarios with multiple workspaces
|
|
560
|
+
3. **Error Handling**: Always wrap service calls in try-catch blocks
|
|
561
|
+
4. **Rate Limiting**: Implement rate limiting for high-volume applications
|
|
562
|
+
5. **Webhook Security**: Verify webhook requests using Slack's signing secret (implement in your application)
|
|
563
|
+
|
|
564
|
+
### Related Documentation
|
|
565
|
+
|
|
566
|
+
- [Slack Web API Documentation](https://api.slack.com/methods)
|
|
567
|
+
- [Slack Block Kit](https://api.slack.com/block-kit)
|
|
568
|
+
- [Slack Events API](https://api.slack.com/events-api)
|
|
569
|
+
- [@slack/web-api Package](https://www.npmjs.com/package/@slack/web-api)
|
|
570
|
+
|
|
571
|
+
---
|
|
572
|
+
|
|
573
|
+
## License
|
|
574
|
+
|
|
575
|
+
MIT
|
|
576
|
+
|
|
577
|
+
---
|
|
578
|
+
|
|
579
|
+
## Support
|
|
580
|
+
|
|
581
|
+
For issues and feature requests, please contact Venturial support or open an issue in the repository.
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { WebClient } from '@slack/web-api';
|
|
2
|
+
import { AppLogger, SettingsService } from '@venturialstd/core';
|
|
3
|
+
import { SlackConfig } from '../types/slack.config.type';
|
|
4
|
+
export declare class SlackClient {
|
|
5
|
+
private readonly logger;
|
|
6
|
+
private readonly settingsService;
|
|
7
|
+
private client;
|
|
8
|
+
constructor(logger: AppLogger, settingsService: SettingsService);
|
|
9
|
+
getClient(config?: SlackConfig | null): Promise<WebClient>;
|
|
10
|
+
}
|
|
11
|
+
//# sourceMappingURL=slack.client.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"slack.client.d.ts","sourceRoot":"","sources":["../../src/clients/slack.client.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,SAAS,EAAE,MAAM,gBAAgB,CAAC;AAC3C,OAAO,EAAE,SAAS,EAAE,eAAe,EAAE,MAAM,oBAAoB,CAAC;AAGhE,OAAO,EAAE,WAAW,EAAE,MAAM,4BAA4B,CAAC;AAEzD,qBACa,WAAW;IAIpB,OAAO,CAAC,QAAQ,CAAC,MAAM;IACvB,OAAO,CAAC,QAAQ,CAAC,eAAe;IAJlC,OAAO,CAAC,MAAM,CAA0B;gBAGrB,MAAM,EAAE,SAAS,EACjB,eAAe,EAAE,eAAe;IAK7C,SAAS,CAAC,MAAM,GAAE,WAAW,GAAG,IAAW,GAAG,OAAO,CAAC,SAAS,CAAC;CA6BvE"}
|
|
@@ -0,0 +1,58 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {
|
|
3
|
+
var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
|
|
4
|
+
if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
|
|
5
|
+
else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
|
|
6
|
+
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
7
|
+
};
|
|
8
|
+
var __metadata = (this && this.__metadata) || function (k, v) {
|
|
9
|
+
if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v);
|
|
10
|
+
};
|
|
11
|
+
var SlackClient_1;
|
|
12
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
13
|
+
exports.SlackClient = void 0;
|
|
14
|
+
const common_1 = require("@nestjs/common");
|
|
15
|
+
const web_api_1 = require("@slack/web-api");
|
|
16
|
+
const core_1 = require("@venturialstd/core");
|
|
17
|
+
const constants_1 = require("../constants");
|
|
18
|
+
let SlackClient = SlackClient_1 = class SlackClient {
|
|
19
|
+
logger;
|
|
20
|
+
settingsService;
|
|
21
|
+
client = null;
|
|
22
|
+
constructor(logger, settingsService) {
|
|
23
|
+
this.logger = logger;
|
|
24
|
+
this.settingsService = settingsService;
|
|
25
|
+
this.logger.setContext(SlackClient_1.name);
|
|
26
|
+
}
|
|
27
|
+
async getClient(config = null) {
|
|
28
|
+
if (this.client && !config) {
|
|
29
|
+
return this.client;
|
|
30
|
+
}
|
|
31
|
+
const token = config?.botToken ||
|
|
32
|
+
(await this.settingsService.get(constants_1.SLACK_SETTING_KEYS.GENERAL_BOT_TOKEN));
|
|
33
|
+
if (!token) {
|
|
34
|
+
throw new Error('Slack bot token not configured');
|
|
35
|
+
}
|
|
36
|
+
const client = new web_api_1.WebClient(token);
|
|
37
|
+
// Test connection on first initialization
|
|
38
|
+
if (!this.client) {
|
|
39
|
+
try {
|
|
40
|
+
const auth = await client.auth.test();
|
|
41
|
+
this.logger.log(`Slack connected: ${auth.user} (${auth.team})`);
|
|
42
|
+
}
|
|
43
|
+
catch (error) {
|
|
44
|
+
this.logger.error('Error connecting to Slack', error);
|
|
45
|
+
throw error;
|
|
46
|
+
}
|
|
47
|
+
}
|
|
48
|
+
this.client = client;
|
|
49
|
+
return client;
|
|
50
|
+
}
|
|
51
|
+
};
|
|
52
|
+
exports.SlackClient = SlackClient;
|
|
53
|
+
exports.SlackClient = SlackClient = SlackClient_1 = __decorate([
|
|
54
|
+
(0, common_1.Injectable)(),
|
|
55
|
+
__metadata("design:paramtypes", [core_1.AppLogger,
|
|
56
|
+
core_1.SettingsService])
|
|
57
|
+
], SlackClient);
|
|
58
|
+
//# sourceMappingURL=slack.client.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"slack.client.js","sourceRoot":"","sources":["../../src/clients/slack.client.ts"],"names":[],"mappings":";;;;;;;;;;;;;AAAA,2CAA4C;AAC5C,4CAA2C;AAC3C,6CAAgE;AAEhE,4CAAkD;AAI3C,IAAM,WAAW,mBAAjB,MAAM,WAAW;IAIH;IACA;IAJX,MAAM,GAAqB,IAAI,CAAC;IAExC,YACmB,MAAiB,EACjB,eAAgC;QADhC,WAAM,GAAN,MAAM,CAAW;QACjB,oBAAe,GAAf,eAAe,CAAiB;QAEjD,IAAI,CAAC,MAAM,CAAC,UAAU,CAAC,aAAW,CAAC,IAAI,CAAC,CAAC;IAC3C,CAAC;IAED,KAAK,CAAC,SAAS,CAAC,SAA6B,IAAI;QAC/C,IAAI,IAAI,CAAC,MAAM,IAAI,CAAC,MAAM,EAAE,CAAC;YAC3B,OAAO,IAAI,CAAC,MAAM,CAAC;QACrB,CAAC;QAED,MAAM,KAAK,GACT,MAAM,EAAE,QAAQ;YAChB,CAAC,MAAM,IAAI,CAAC,eAAe,CAAC,GAAG,CAAC,8BAAkB,CAAC,iBAAiB,CAAC,CAAC,CAAC;QAEzE,IAAI,CAAC,KAAK,EAAE,CAAC;YACX,MAAM,IAAI,KAAK,CAAC,gCAAgC,CAAC,CAAC;QACpD,CAAC;QAED,MAAM,MAAM,GAAG,IAAI,mBAAS,CAAC,KAAK,CAAC,CAAC;QAEpC,0CAA0C;QAC1C,IAAI,CAAC,IAAI,CAAC,MAAM,EAAE,CAAC;YACjB,IAAI,CAAC;gBACH,MAAM,IAAI,GAAG,MAAM,MAAM,CAAC,IAAI,CAAC,IAAI,EAAE,CAAC;gBACtC,IAAI,CAAC,MAAM,CAAC,GAAG,CAAC,oBAAoB,IAAI,CAAC,IAAI,KAAK,IAAI,CAAC,IAAI,GAAG,CAAC,CAAC;YAClE,CAAC;YAAC,OAAO,KAAK,EAAE,CAAC;gBACf,IAAI,CAAC,MAAM,CAAC,KAAK,CAAC,2BAA2B,EAAE,KAAc,CAAC,CAAC;gBAC/D,MAAM,KAAK,CAAC;YACd,CAAC;QACH,CAAC;QAED,IAAI,CAAC,MAAM,GAAG,MAAM,CAAC;QACrB,OAAO,MAAM,CAAC;IAChB,CAAC;CACF,CAAA;AAvCY,kCAAW;sBAAX,WAAW;IADvB,IAAA,mBAAU,GAAE;qCAKgB,gBAAS;QACA,sBAAe;GALxC,WAAW,CAuCvB"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/constants/index.ts"],"names":[],"mappings":"AAAA,cAAc,wBAAwB,CAAC;AACvC,cAAc,2BAA2B,CAAC"}
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
+
if (k2 === undefined) k2 = k;
|
|
4
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
5
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
6
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
7
|
+
}
|
|
8
|
+
Object.defineProperty(o, k2, desc);
|
|
9
|
+
}) : (function(o, m, k, k2) {
|
|
10
|
+
if (k2 === undefined) k2 = k;
|
|
11
|
+
o[k2] = m[k];
|
|
12
|
+
}));
|
|
13
|
+
var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
14
|
+
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
15
|
+
};
|
|
16
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17
|
+
__exportStar(require("./slack.event.constant"), exports);
|
|
18
|
+
__exportStar(require("./slack.settings.constant"), exports);
|
|
19
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/constants/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;AAAA,yDAAuC;AACvC,4DAA0C"}
|