Skip to main content

Slack Connection

The Slack connection type enables automations to send messages, post to channels, and interact with a Slack workspace through the Slack Web API. It is used by the plugin-slack plugin, which delegates to the slack-connector.

Connection Type

PropertyValue
Type enumSLACK
Type IDslack
CategoryEnterprise Apps
Connector classSlackConnectionDetails

Friendly Example

What you enterExample
Connection nameSlack - Support Alerts
Used forPosting alerts and summaries into Slack channels
Main details to collectBot token, workspace, and target channel
Best person to provide itSlack workspace administrator

After it is saved, workflow builders select Slack - Support Alerts in a node instead of entering these details again.

Mandatory Fields

FieldTypeRequiredDescription
botTokenStringYesThe Bot User OAuth Token, starting with xoxb-. This is the primary authentication credential. Encrypted at rest.

Advanced Fields

FieldTypeRequiredDescription
apiBaseUrlStringNoOverride the Slack API base URL. Defaults to https://slack.com/api. Useful for Slack Enterprise Grid with custom endpoints.
workspaceIdStringNoThe Slack workspace ID (e.g., T01ABCDEF). Informational; helps identify the target workspace.
workspaceNameStringNoHuman-readable workspace name for documentation purposes.

Creating a Slack App

  1. Go to https://api.slack.com/apps and click Create New App.

  2. Choose "From scratch" and provide an app name (e.g., Qinfinite Automation) and select the target workspace.

  3. Navigate to OAuth & Permissions in the left sidebar.

  4. Add Bot Token Scopes. The minimum scopes depend on what your automations need:

ScopePurpose
chat:writePost messages to channels the bot is a member of
chat:write.publicPost messages to any public channel without joining
channels:readList public channels and get channel info
groups:readList private channels the bot is a member of
files:writeUpload files to channels
users:readLook up user information
users:read.emailLook up users by email address
  1. Install the app to your workspace by clicking Install to Workspace at the top of the OAuth & Permissions page.

  2. Copy the Bot User OAuth Token (xoxb-...) displayed after installation. This is the value for the botToken field.

  3. Invite the bot to any channels where it needs to post. In Slack, go to the channel and type /invite @YourBotName.

Token Rotation

Slack bot tokens do not expire by default, but they can be revoked if the app is reinstalled or uninstalled. If your organization requires token rotation:

  • Enable Token Rotation in the app settings under OAuth & Permissions.
  • When enabled, tokens have a limited lifespan and a refresh token is provided. The connector will need to handle token refresh (not currently automated; update the connection when the token is rotated).

Troubleshooting

SymptomLikely Cause
invalid_authThe bot token is invalid, revoked, or the app was uninstalled and reinstalled (generating a new token)
channel_not_foundThe channel ID or name is wrong, or the bot has not been invited to a private channel
not_in_channelThe bot needs to be invited to the channel. Use /invite @BotName in the channel.
missing_scopeThe bot token does not have the required OAuth scope. Add the scope in app settings and reinstall.
ratelimitedSlack enforces rate limits (typically 1 message per second per channel). Add delays between bulk sends.