Jump to a Section

Overview

The first time that you add a Slack card to a flow, you’re prompted to set up a connection for that channel. Setting up a connection will allow you to connect the flow to your Slack account, save the data, and reuse that connection the next time you build a flow with this card.

  1. Add a Slack card to your flow. If you’ve already set up connections, select Add Account to create a new one.
  2. Name the connection. Be sure that each configuration has a uniquely identifiable name.
  3. Click Authorize.
  4. Select the Slack account to connect to. If you are not already signed into this Slack account, you will be prompted to do so.
  5. Click Authorize to grant access to your Slack data. Note that this allows the flow to send messages on your behalf.

You can reuse this connection any time that you use the Slack card in a flow. You can also set up and save multiple connections to share them with your teammates.

    Events

    • New Message in Channel

      Trigger a flow whenever a new message is added to a Slack Channel.

      Note: Pairing this event with a Send Message to Channel action may create a loop. Notifying the channel when a new message is added will cause the Flow to respond to its own messages.

      Unless otherwise indicated, field types are text.

      Options

      • Your Channels (drop-down): list of public channels you can monitor

      Output

      • Message
        • Text: text of the message
        • Timestamp: timestamp when the message was added
      • Author
        • Full Name: user’s full name
        • Username: user’s Slack username (without @ symbol)
        • User ID: user’s unique Slack ID
    • New Message in Private Channel

      Trigger a Flow whenever a new message is added to a private Slack Channel.

      Note: Pairing this event with a Send Message to Channel action may create a loop. Notifying the channel when a new message is added will cause the flow to respond to its own messages.

      Unless otherwise indicated, field types are text.

      Options

      • Your Channels (drop-down): list of private channels you can monitor

      Output

      • Message
        • Text: text of the message
        • Timestamp: timestamp when the message was added
      • Author
        • Full Name: user’s full name
        • Username: user’s Slack username (without @ symbol)
        • User ID: user’s unique Slack ID
    • New Pinned Message

      Trigger a Flow whenever a new pinned message is added to a Slack Channel.

      Note: Pairing this event with a Send Message to Channel action may create a loop. Notifying the channel when a new message is added will cause the flow to respond to its own messages.

      To configure this card, you must complete the following steps:

      1. Choose a Slack account that has already been configured, or select “New Account” to connect a new account.
      2. Choose the Slack Channel you would like to monitor from the drop-down list. This list only includes the Channels you are currently a member of.
      3. If you are unable to connect to your account, you will receive an “INVALID CONFIG” message and you will not be able to finish configuring the card. Click the Accounts tab to go back and select a different account.

      Unless otherwise indicated, field types are text.

      Options

      • Your Channels (drop-down): list of public channels you can monitor

      Output

      • Message
        • Text: text of the message
        • Timestamp: timestamp when the message was added
      • Author
        • Full Name: user’s full name
        • Username: user’s Slack username (without @ symbol)
        • User ID: user’s unique Slack ID
    • Slash Command

      Trigger a flow when someone sends a slash command to a Slack bot. Slash commands are submitted in the message box in Slack, though they are technically not messages. They cause a payload of data to be sent from Slack to an app. For additional information, view the Slack API documentation.

      This event should be paired with Respond to Command actions.

      Output

      • Command
        • Slash Command: command that was sent to the Slack bot
        • Text: user-entered content after the command
        • Response URL: URL for command response
        • Team ID: team ID of the user who sent the command
        • Team Domain: user’s team domain name
        • Channel ID: ID of the channel where the command was sent
        • Channel Name: name of the channel where the command was sent
        • User ID: user’s unique Slack user ID
        • User Name: user’s Slack username

    Actions

    • Archive Channel

      Archive a Slack channel and remove it from the list of active conversations. For more information, refer to Slack Help.

      Field type is text.

      Input

      • Name or ID: name or unique ID of the channel you want to archive (channel names are 20 lowercase characters or less and do not contain spaces or periods)
    • Create Channel

      Create a new channel in Slack.

      Unless otherwise indicated, field types are text.

      Input

      • Channel
        • Name: name of the channel (20 lowercase characters or less, no spaces or periods)
        • Purpose: purpose of the channel
        • Type (drop-down): visibility of the channel (Public or Private)

      Output

      • Channel
        • ID: ID of the new channel
    • Custom API Action

      Make a custom, authenticated HTTP call to the Slack API.

      NOTE: This action is unlike other Slack cards; refer to the Slack API documentation.

      Options

      • Request Type (drop-down): one of five supported HTTP request methods (sometimes called verbs) in custom API calls:
        • GET retrieves data from a web server based on your parameters. GET requests a representation of the specified resource. If successful, GET will receive a 200 OK response message with the requested content. Refer to additional documentation here.
        • POST sends data to a web server based on your parameters. POST requests include actions like uploading a file. Multiple POSTs may result in a different outcome than a single POST, so you should be cautious about unintentionally sending multiple POSTs. If a POST is successful, you will receive a 200 OK response message. Refer to additional documentation here.
        • PUT sends data to a location in the web server based on your parameters. PUT requests include actions like uploading a file. The difference between a PUT and POST is that PUT is idempotent, meaning that the result of a single successful PUT is the same as many identical PUT’s. If a PUT is successful, you will receive a 200 response message (usually 201 or 204). Refer to additional documentation here.
        • PATCH applies partial modifications to a resource on a web server based on your parameters. PATCH is not idempotent, meaning that multiple PATCHs could have unintended consequences. If a PUT is successful, you will receive a 200 response message (usually 204). Refer to additional documentation here.
        • DELETE deletes the specified resource from the web server based on your parameters (if the resource exists). If a DELETE is successful, you will receive a 200 OK response message. Refer to additional documentation here.

      Input

      • Relative URL (text): The address on the web server you are attempting to interact with. Relative URL means that you don’t have to explicitly specify the protocol at the beginning of the URL (such as “http://“). This suggests to the web server that the interaction is occurring on the server (in this instance).

        Example: /user/me
      • Query (object or text): JSON object that determines the action taken at the URL

        Example: {"name":"something-urgent"}
      • Headers (object): JSON object that determines the content type of the request. This will usually be a replica of the example below.

        Example: {"Content-type":"application/json"}

      Output

      • Status Code (number): success or failure of your HTTP request. Here is a list of all status codes.
      • Headers (object): A detailed context for the status code, unrelated to the output body. Response headers are dependent on your selected HTTP request option. Note that not all headers are response headers.
      • Body (object): data returned from your selected HTTP request (for example, the data from a GET request)
    • Invite User to Channel

      Invite a user to a Slack channel

    • Join Channel

      Join a Slack channel.

      Field types are text.

      Input

      • Channel Name: name of the channel you want to join

      Output

      • Channel ID: ID of the channel you joined
    • Leave Channel

      Leave a Slack channel.

      Field types are text.

      Input

      • Channel Name: name of the channel you want to leave

      Output

      • Channel ID: ID of the channel you left
    • Read Message History

      Retrieve information about messages received on Slack.

      Input

      • Channel
        • Name (text): name of the channel where the message was received
      • Range
        • Start Date (date): start of the date range
        • End Date (date): end of the date range
        • Maximum Messages Returned (number): number of messages to retrieve from the date range

      Output

      • Messages
        • Text (text): content of the message
        • Timestamp (time): timestamp when the message was sent
        • Author ID (text): ID of the user who sent the message
    • Read User

      Retrieve information about a Slack user.

      Unless otherwise indicated, field types are text.

      Options

      • Field Type (drop-down): User ID, Username, or Email. Note: Organizations with more than 10,000 Slack users should select User ID or Email.

      Input

      • User
        • User ID: user’s unique ID
        • Username: user’s Slack username
        • Email: user’s email address

      Output

      • User
        • Full Name: user’s full name
        • Email: user’s email address
        • User ID: user’s unique ID
        • Username: user’s Slack username
    • Respond to Command - Delayed

      Send a delayed response to a user’s slash command. Delayed responses should be used if your flow runtime is greater than three seconds. Slash commands are submitted in the message box in Slack, though they are technically not messages. They cause a payload of data to be sent from Slack to an app.

      This action should be paired with a Slash Command event.

      Unless otherwise indicated, field types are text.

      Input

      • Command
        • Response URL: URL for response
        • Message Text_: content of the message to send to the user
        • Response Type (drop-down): visibility of the response (Visible to Channel or Visible to User)
        • Attachments (object): JSON code formatted according to the Slack API documentation
    • Respond to Command - Real Time

      Send an immediate response to a user’s slash command. If your flow runtime is greater than three seconds, use the Respond to Command - Delayed action instead. Slash commands are submitted in the message box in Slack, though they are technically not messages. They cause a payload of data to be sent from Slack to an app.

      This action should be paired with a Slash Command event.

      Unless otherwise indicated, field types are text.

      Input

      • Command
        • Response URL: URL for response
        • Message Text_: content of the message to send to the user
        • Response Type (drop-down): visibility of the response (Visible to Channel or Visible to User)
        • Attachments (object): JSON code formatted according to the Slack API documentation
    • Search Channels

      Search for a Slack channel.

      Unless otherwise indicated, field types are text.

      Options

      • Result Set (drop-down)
        • First Matching Channel: first channel that meets search criteria
        • All Matching Channels: all channels that meet search criteria

      Input

      • Search
        • Name: name of the Slack channel
        • Creator ID: ID of the user who created the channel
        • Is Archived?: (true/false): indicator if the channel is archived
        • Are Member? (true/false): indicator if you are a member of the channel
    • Send Direct Message

      Send a direct message to a Slack user on your team. To send a Slack notification rather than a direct message, use Send Slackbot Message.

      Unless otherwise indicated, field types are text.

      Options

      • Unfurl URLs? (true/false): indicate whether Slack should scan links found in messages and create attachments based on the link’s contents
      • Field Type (drop-down): indicate which input field is used to identify the user (User ID or Username)

      Input

      Input fields are dependent on the field type selection.

      • Username: Slack username of the person to send the message to (without the @ symbol)
      • User ID: unique ID of the Slack user
      • Message: message text (may include emojis:, #channels, @users, and /commands)

      Output

      • Timestamp: timestamp when message was sent
    • Send Message to Channel

      Send a message to a channel

    • Send Slackbot Message

      Send a notification to a user’s @slackbot channel.

      Unless otherwise indicated, field types are text.

      Options

      • Unfurl URLs? (true/false): indicate whether Slack should scan links found in messages and create attachments based on the link’s contents

      Input

      • Username: user’s Slack username (without the @ symbol)
      • Message: message text (may include emojis:, #channels, @users, and /commands)
      • Slackbot Name: name of the sender from the slackbot channel (for example, Customer Tracking or Sales Bot)

      Output

      • Timestamp: timestamp when message was sent
    • Invite User to Channel

      Invite a user to a Slack channel.

      Option

      • Your Channels (drop-down): list of available channels

      Input

      • Username (text): name of the user you want to invite
    • Search User By Email

      Search by email address for a user’s Slack information. Searching is limited to the team you selected when you authenticated Slack. The card will return empty fields if the email address is not found.

      Unless otherwise indicated, field types are text.

      Input

      • User
        • Email: email address of the user

      Output

      • User
        • Full Name: full name of the user associated with the email address
        • Username: Slack username of the user associated with the email address (without the @ symbol)
        • User ID: unique user ID associated with the email address
    • Send Message to Channel

      Send a message to a Slack channel. You must be a member of the channel. You can send the message as a bot or from your own ID.

      When sending messages as bots, you will trigger any flows that look for a New Message in Channel event. If you are subscribed to channel notifications, you will receive a notification when you send messages as bots. Sending from your own ID will not trigger flows or notifications.

      Unless otherwise indicated, field types are text.

      Options

      • Your Channels (drop-down): available channels
      • Send as Bot? (drop-down): yes to send the message from a bot or no to send it from your own ID
      • Unfurl URLs? (true/false): indicate whether Slack should scan links found in messages and create attachments based on the link’s contents

      Input

      • Message Text: message text (may include emojis:, #channels, @users, and /commands)
      • Slackbot Name: name of the sender from the slackbot channel (if Send as Bot? option is yes)

      Output

      • Timestamp: timestamp when message was sent