Slack
Add Query
You can add a query step by adding a workflow from the page list.
When you select the Slack data source from the workflow step sidebar, the query input window appears.
Event Types
Send Channel Message
Send a message to a Slack channel.
Parameters
type SlackSender = 'USER' | 'BOT';
type SlackMessage = 'TEXT' | 'BLOCKS' | 'ATTACHMENT';
type SlackContent = `string` | `Record<string, unknown>[]`;
Name | Type | Description |
---|---|---|
Sender Type (senderType) | SlackSender | Message sending user type |
Channel Name (channel) | string | Channel name |
Message Type (messageType) | SlackMessage | Message type |
Content (content) | SlackContent | Message content |
Thread (threadTs) | string | Thread timestamp |
Reply Broadcast (replyBroadcast) | boolean | Thread message channel send |
Other settings (optionalArguments) | Record<string, unknown> | Other settings |
- Optional arguments of other settings are available in the official documentation.
- Content parameter type is different depending on the message type.
- Text type
string
- See the official documentation for more details.
- Block type
Record<string, unknown>[]
- See the official documentation for more details.
- Attachment type
Record<string, unknown>[]
- See the official documentation for more details.
- Text type
Query Result
When you execute the message sending action, the result value is returned in the following structure.
interface Result {
ok: boolean;
channel: string;
ts: string;
message: Record<string, unknown>;
warning: string;
response_metadata: Record<string, unknown>;
}
Use Result Value
To use the result value in another step, write as follows.
return outputs.stepName.message;
Send Direct Message
Send a direct message.
Parameters
Name | Type | Description |
---|---|---|
Sender Type (senderType) | SlackSender | Message sending user type |
User Name (user) | string | User name |
Message Type (messageType) | SlackMessage | Message type |
Content (content) | SlackContent | Message content |
Query Result
When you execute the direct message sending action, the result value is returned in the following structure.
interface Result {
ok: boolean;
channel: string;
ts: string;
message: Record<string, unknown>;
warning: string;
response_metadata: Record<string, unknown>;
}
Use Result Value
To use the result value in another step, write as follows.
return outputs.stepName.message;
Search Message
Search for a message.
Parameters
Name | Type | Description |
---|---|---|
Search (query) | string | Search content |
Query Result
When you execute the message search action, the result value is returned in the following structure.
interface Result {
ok: boolean;
query: string;
messages: Record<string, unknown>;
}
Use Result Value
To use the result value in another step, write as follows.
return outputs.stepName.messages;
List Users
Search for a user.
파라미터
Name | Type | Description |
---|---|---|
Limit (limit) | number | Limit |
Cursor (cursor) | string | Cursor |
Other settings (optionalArguments) | Record<string, unknown> | Other settings |
- Optional arguments of other settings are available in the official documentation.
Query Result
When you execute the user list action, the result value is returned in the following structure.
interface Result {
ok: boolean;
offset: number;
members: Record<string, unknown>[];
cache_ts: number;
response_metadata: Record<string, unknown>;
}
Use Result Value
To use the result value in another step, write as follows.
return outputs.stepName.members;
List Channels
Search for a channel.
Parameters
Name | Type | Description |
---|---|---|
Type (channelType) | string | Channel type |
Limit (limit) | number | Limit |
Cursor (cursor) | string | Cursor |
Other settings (optionalArguments) | Record<string, unknown> | Other settings |
- Optional arguments of other settings are available in the official documentation.
Query Result
When you execute the channel list action, the result value is returned in the following structure.
interface Result {
ok: boolean;
channels: Record<string, unknown>[];
response_metadata: Record<string, unknown>;
}
Use Result Value
To use the result value in another step, write as follows.
return outputs.stepName.channels;
List Messages
View a message.
Parameters
Name | Type | Description |
---|---|---|
Channel Name (channel) | string | Channel name |
Limit (limit) | number | Limit |
Cursor (cursor) | string | Cursor |
Other settings (optionalArguments) | Record<string, unknown> | Other settings |
- Optional arguments of other settings are available in the official documentation.
Query Result
When you execute the message viewing action, the result value is returned in the following structure.
interface Result {
ok: boolean;
messages: Record<string, unknown>[];
has_more: boolean;
pin_count: number;
channel_actions_ts: string;
channel_actions_count: number;
warnings: string;
response_metadata: Record<string, unknown>;
}
Use Result Value
To use the result value in another step, write as follows.
return outputs.stepName.messages;
List Replies
View a thread.
Parameters
Name | Type | Description |
---|---|---|
Channel Name (channel) | string | Channel name |
Thread (ts) | string | Thread timestamp |
Limit (limit) | number | Limit |
Cursor (cursor) | string | Cursor |
Other settings (optionalArguments) | Record<string, unknown> | Other settings |
- Optional arguments of other settings are available in the official documentation.
Query Result
When you execute the thread viewing action, the result value is returned in the following structure.
interface Result {
ok: boolean;
messages: Record<string, unknown>[];
has_more: boolean;
}
Use Result Value
To use the result value in another step, write as follows.
return outputs.stepName.messages;