# Stripe Workflows for Slack

Send automated notifications to Slack channels from Stripe Workflows.

Use the Stripe Workflows for Slack app to send automated notifications to your Slack channels when events occur in Stripe. Combine it with [Stripe Workflows](https://docs.stripe.com/workflows.md) to notify your team about payments, subscriptions, disputes, and other Stripe events in real time.

The app supports:

- **Custom message templates**: Include dynamic data from Stripe events and format messages with Slack’s text styling.
- **Dashboard deep links**: Optionally include a link to the relevant Stripe Dashboard page in each notification.
- **Multiple channels**: Route different notifications to different Slack channels based on your workflow logic.

## Install the app 

1. Find the **Slack** app in the [Stripe App Marketplace](https://marketplace.stripe.com/).
1. Select the account you want to install the app to from the account dropdown.
1. Click **Install**.

After installation, the app appears as an icon in the right sidebar on any page of the account you installed it on. Look for the icon in the upper-right corner of your screen, next to the **Apps** button.

## Connect to Slack 

After you install the app, connect it to a Slack workspace:

1. Open the app from the right sidebar. It prompts you to visit the app’s settings page.
1. Click the **Go to Settings** link in the app, or right-click the overflow menu (⋯) in the upper-right corner, and select **View app settings**.
1. On the settings page, click the **Add to Slack** link.
1. Select the workspace you want to connect from the dropdown. This page shows the permissions the app requests, which allow it to read basic channel information and send messages.
1. Click **Allow** to complete the connection.

The settings page displays “Connected to <workspace>” when the connection is successful. If the connection doesn’t display immediately, refresh the page.

To change the connected workspace, click **Remove connection** on the settings page and repeat the process to select a different workspace.

## Configure channels 

### Add a channel 

Add channels from within Slack:

1. Open the channel you want to enable.
1. Type “/invite @Stripe” in the channel.
1. Stripe joins the channel and you can see it in the app’s **Channels** list. If you don’t see it immediately, click **Refresh** to update the list.

### Remove a channel 

Remove channels from within Slack:

1. Open the channel you want to remove.
1. Type “/remove @Stripe” in the channel.
1. Confirm the removal when prompted. Click **Refresh** in the Stripe app to update the list.

### Send a test notification 

From the app settings page in Stripe, you can verify that a channel is connected:

1. Click **Test** next to the channel name.
1. The button temporarily displays “Sending…” and then confirms the test was sent.
1. Check the channel in Slack. A test message from the app confirms the channel is connected and ready to receive notifications.

## Create a workflow with Slack notifications 

You can find **Workflows** in the left menu bar of Stripe, either under the **Shortcuts** section or under **Products** > **More**.

To add a Slack notification to a workflow:

1. Click **Create workflow**.
1. Add your trigger and any preceding steps that provide the data you need.
1. Click **Add a step**, and select **Add action**.
1. Search for “Slack” or select the **Apps** tag, then choose **Send Slack Notification**.

### Configure the action 

The **Edit action** panel contains three required fields:

| Field                      | Description                                                                                                                                                                                                                                                                                      |
| -------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
| **Slack channel**          | Select the channel for the notification from the dropdown. This list contains all channels you’ve authorized the app to send messages in.                                                                                                                                                        |
| **Message template**       | Enter the notification text. Click the **+** button in the bottom-right corner of the input to insert variables from your trigger or previous steps. You can also use [message formatting](https://docs.stripe.com/use-stripe-apps/stripe-workflows-slack.md#format-messages) to style the text. |
| **Include dashboard link** | Select **true** to include a deep link to the relevant page in the Stripe Dashboard. When set to **true**, an additional **Event object ID** field appears. Set it to the ID of the object you want to link to, using a variable from your trigger or a previous step.                           |

> Add a trigger or data step before configuring this action. The plus symbol (+) for inserting variables only displays if a previous step provides selectable data.

To test the workflow, click **Publish**. In a sandbox environment, perform the trigger action and verify that the notification displays in your Slack channel. You can then edit the workflow and republish as needed.

### Format message templates 

Message templates support most Slack text formatting:

| Syntax         | Result             |
| -------------- | ------------------ |
| `_text_`       | *Italic text*      |
| `*text*`       | **Bold text**      |
| `~text~`       | Strikethrough text |
| `> text`       | Block quote        |
| ``code``       | Inline code        |
| ```` code ```` | Code block         |
| `:emoji-name:` | Named emoji        |

Line breaks in the text input are preserved when sent to Slack. Create lists using a symbol followed by a space:

```text
* Item 1
* Item 2
```

For numbered lists:

```text
1. Item 1
2. Item 2
```

#### Add URL hyperlinks 

To display a URL with custom text, use angle brackets with a pipe separator:

```text
<http://example.com|Display text>
```

#### Mention users, channels, and groups 

Use Slack IDs (not display names) to mention users, channels, and groups in your message templates:

| Type    | Syntax                                 | How to find the ID                                                                                                |
| ------- | -------------------------------------- | ----------------------------------------------------------------------------------------------------------------- |
| User    | `<@U012AB3CD>`                         | Open the user’s profile in Slack, click the overflow menu (⋯), and select **Copy member ID**.                     |
| Channel | `<#C123ABC456>`                        | Click the overflow menu (⋯) on a channel, select **Open channel details**, and copy the channel ID at the bottom. |
| Group   | `<!subteam^SAZ94GDB8>`                 | Admin privileges are required. Find the Group ID from the URL when viewing the user group’s profile.              |
| Special | `<!everyone>`, `<!here>`, `<!channel>` | Use these to mention everyone, active members, or all channel members.                                            |

## Workflow examples 

### Send a notification for large payments 

Create a workflow that notifies a channel when a payment over 1,000 USD comes in:

1. Click **Add a trigger**, and select **Payment intent succeeded**.
1. Under **Trigger conditions**, click **Add condition**. Set the condition to **Amount received** is greater than or equal to 1,000.00 USD.
1. Click **Add a step**, and select **Add action**. Search for **Retrieve a customer** and set the **Customer ID** using the plus symbol (+) to select **Customer ID** from the trigger.
1. Click **Add a step**, and select **Add action**. Search for **Send Slack Notification** and configure it:
   - **Slack channel**: Select your channel (for example, `#wins`).
   - **Message template**: Compose your message using variables. For example:
     ```text
     *Big win!* :tada:
     We just closed a large deal!
     {Payment intent | Amount received} from {Customer | Name}
     {Payment intent | Description}
     Payment processed on {Payment intent | Created}
     ```
   - **Include dashboard link**: Set to **true**.
   - **Event object ID**: Select **Payment intent ID** from the trigger.
1. Click **Publish** and send a test payment to see the workflow in action.

This example demonstrates trigger conditions, retrieving data from related objects, composing messages with variables, and including Dashboard deep links.

### Route notifications by subscription type 

Create a workflow that sends notifications to different channels based on the subscription plan a customer signs up for:

1. Click **Create workflow**, and set the trigger to **Customer subscription is created**.
1. Add a **Send Slack Notification** action to notify a general channel about all new subscriptions:
   - **Slack channel**: Select your general subscriptions channel.
   - **Message template**: For example, “New subscription alert! {Subscription | Description}”.
   - **Include dashboard link**: Set to **true**, with **Event object ID** set to **Subscription ID**.
1. Add a **Retrieve a customer** action and set **Customer ID** using the plus symbol (+).
1. Add a **condition** step to split the workflow:
   - Set the condition to check whether **Items (collection)** from the trigger contains at least one item where **Price** > **Product ID** equals your Enterprise plan.
1. On the **true** branch, add a **Send Slack Notification** action:
   - **Slack channel**: Select your `#enterprise` channel.
   - **Message template**: For example, “New enterprise client! Welcome {Customer | Name} to our group!”
   - **Include dashboard link**: Set to **true**, with **Event object ID** set to **Customer ID**.
1. On the **false** branch, add a **Send Slack Notification** action:
   - **Slack channel**: Select your `#hobby` channel.
   - **Message template**: For example, “A new hobbyist has landed! Welcome {Customer | Name} to the crew!”
   - **Include dashboard link**: Set to **true**, with **Event object ID** set to **Customer ID**.

This example demonstrates multiple Slack notifications to different channels, conditional workflow logic, and messages that add more context with data from multiple steps.
