<slack>

<slack> is a built-in communication tag used either as a workflow trigger or inside <notify>.

Why use it

Use it when Slack should admit message-driven runs or carry approval and lifecycle notifications through Socket Mode.

Common use cases

  • Start a workflow from an app mention.
  • Start a workflow from a direct message.
  • Deliver approval buttons to one or more channels.
  • Send a lifecycle notification to operators.

Syntax

WOML
<slack
  id="agentMessage"
  events="app-mention,direct-message"
  channels="woml-testing"
  bot-token="{{secrets.SLACK_BOT_TOKEN}}"
  app-token="{{secrets.SLACK_APP_TOKEN}}"
/>

Rules and behavior

  • A trigger requires id, events, bot-token, and app-token; channels is an optional comma-separated filter.
  • Trigger channels use names without # or Slack conversation IDs.
  • Notification channels are whitespace-separated and accept lowercase #channel aliases or conversation IDs.
  • Slack uses one shared Socket Mode connection per credential pair.
  • services.slack.send() is not a public v1 service.