Slack Message Post Block

Post messages to Slack channels or threads

The Slack Message Post block enables users to send messages to specified Slack channels or threads within Scout workflows. This block supports dynamic content using Jinja templating, allowing for personalized and context-aware messaging.

Configuration (Required)

Slack Integration
string

Select which Slack workspace to post to. This field is optional and defaults to an empty string.

Channel ID
stringRequired

The ID of the channel to post the message to. Ensure the channel ID is correct to avoid posting messages to unintended locations. This field supports Jinja templating for dynamic ID construction.

Thread ID
string

The ID of the thread to post the message to. If not specified, the message will be posted as a new thread. This field supports Jinja templating for dynamic ID construction and defaults to an empty string.

Slack Message
stringRequired

The content of the message to be posted. This field supports Jinja templating for dynamic message construction.

Username
string

The username to post the message as. This field supports Jinja templating and defaults to “Scout”.

Icon URL
string

The URL of the icon to post the message as. This field supports Jinja templating and defaults to an empty string.

Slack Blocks
string

The blocks to post in the message. This field supports Jinja templating and JSON format for dynamic block construction and defaults to an empty string.

See Slack’s Block Kit Builder for more on how to construct formatted Slack Blocks.

See Workflow Logic & State > State Management for details on using dynamic variables in this block.

Outputs

The block outputs the response from Slack after posting the message, including details of the posted message. This response is in JSON format and provides information such as the message timestamp and channel ID.

Usage Context

Use this block to send messages to Slack channels or threads, integrating dynamic content using Jinja templating for personalized interactions. It is ideal for notifications, alerts, or any communication that needs to be integrated into Slack.

Best Practices

  • Ensure the channel ID and thread ID (if applicable) are correct to avoid posting messages to unintended locations.
  • Use Jinja templating to dynamically construct messages, usernames, and other fields for context-aware communication.
  • Verify that the Slack integration is properly configured and that the necessary OAuth tokens are available.