The SEND_MESSAGE action sends a message to a Slack user, public channel, or private channel.
Use this action to deliver notifications, alerts, approval updates, status messages, and other process-driven communications directly within Slack. The action sends a message to a Slack recipient identified by either a channel or a user. The message content is defined using the text parameter and contain static text or dynamically generated content using process variables through FreeMarker expressions. The recipient can be specified using channel ID, channel name, user ID, or user email address.
The input parameters of the action are:
| Parameter | Type | Required | Description |
|---|---|---|---|
| channelId | String | Requires one recipient option | The ID of the Slack channel that will receive the message. |
| channelName | String | Requires one recipient option | The name of the Slack channel that will receive the message. |
| userId | String | Requires one recipient option | The ID of the Slack user who will receive the message. |
| userEmail | String | Requires one recipient option | The email address of the Slack user who will receive the message. |
| text | String | Required |
The message content to send. The text supports FreeMarker expressions, allowing process variables to be inserted dynamically. For example: Hello ${fullName.lastName},
your approval request has been completed.
where ${fullName.lastName} can be used from the metadata parameter to include variables. For more information on using FreeMarker, refer to Apache FreeMarker documentation. |
| metadata | JSON | Optional | A JSON object containing values that can be referenced by FreeMarker expressions in the message text. For more information on using FreeMarker, refer to Apache FreeMarker documentation. |
| requestResponse | String | Optional |
Controls whether the process waits for a reply. Use no to continue immediately, any to wait for a reply in the channel, or thread to wait for a reply in a thread. Use this capability when human input is required before the process can continue. |
The output parameters of the action are:
| Parameter | Type | Required | Description |
|---|---|---|---|
| message | String | Optional | The reply message received from Slack when requestResponse is configured as any or thread. |