Skip to main content

Receive Message

Listens for incoming messages from Slack in real-time.

Common Properties

  • Name - The custom name of the node.
  • Color - The custom color of the node.
  • Delay Before (sec) - Waits in seconds before executing the node.
  • Delay After (sec) - Waits in seconds after executing node.
  • Continue On Error - Automation will continue regardless of any error. The default value is false.
info

If the ContinueOnError property is true, no error is caught when the project is executed, even if a Catch node is used.

Options

  • Bot Token - The Slack bot token credential used to authenticate with Slack.
  • App Level Token - The Slack app-level token credential required for Socket Mode connections.
  • Channel Id - (Optional) Filter to receive messages only from a specific channel.
  • User Id - (Optional) Filter to receive messages only from a specific user.

Output

  • Client ID - The unique identifier for the Slack client connection that can be used in other Slack nodes.
  • Message - The complete message object received from Slack, including text, channel, user, and other metadata.

How It Works

The Receive Message node establishes a real-time connection to Slack using Socket Mode and listens for incoming messages. When a message is received, the node:

  1. Establishes a WebSocket connection to Slack using the provided tokens
  2. Optionally filters messages based on Channel Id or User Id if specified
  3. Processes incoming message events from Slack
  4. Emits a new flow execution for each received message
  5. Provides the message data and client connection ID as outputs

The node runs continuously while the flow is active and will trigger a new execution for each matching message received.

Requirements

  • A valid Slack bot token with appropriate permissions
  • A valid Slack app-level token for Socket Mode connections
  • The bot must be installed in the workspace where you want to receive messages
  • Appropriate scopes for the bot to receive messages (channels:history, groups:history, im:history, mpim:history)

Error Handling

The node will return specific errors in the following cases:

  • Empty or invalid bot token credential
  • Empty or invalid app-level token credential
  • Invalid Slack tokens that cannot establish a connection
  • Network connectivity issues
  • Slack API errors

Usage Notes

  • This node is designed to be a trigger node that starts new flow executions
  • The node does not have input connectors since it initiates flows based on incoming messages
  • Filtering by Channel Id or User Id can help reduce unnecessary flow executions
  • The message output contains the complete Slack message object with all available fields
  • The Client ID can be used with other Slack nodes that require a connection
  • Make sure your app is configured for Socket Mode in the Slack API settings
  • The bot must be added to channels where you want to receive messages