Navigation

Slack Service

Slack provides team-based messaging services for web and mobile apps. MongoDB Stitch supports integrating apps with Slack. You will need the following to integrate Slack with your MongoDB Stitch app:

  • Slack team ID
  • Slack Incoming Webhook URL

You will also need a MongoDB Stitch incoming webhook to receive requests from Slack. However, your app may send messages to Slack without a webhook.

Set up Slack

Use the following procedure to get started with Slack:

  1. Visit Slack and either create a new account or log in with your existing credentials.

  2. Click the team name in the upper left corner and select Apps & integrations.

  3. Locate Incoming Webhooks with the search tool.

  4. Click the Add Configuration button and complete the form. Copy the Webhook URL for later use.

    Note

    If you are using a Slack account of which you are not the owner, you’ll need to request permission from the account owner to add an incoming webhook.

Add a Slack Service to Your MongoDB Stitch App

Use the following procedure to add a Slack service to your MongoDB Stitch app:

  1. If you haven’t yet created a MongoDB Stitch app , see Stitch app setup.
  2. Click Add Service in the navigation pane.
  3. Select Slack.
  4. Enter a name for your service in the Service Name box.
  5. Click Add Service.
  6. Enter your Slack team ID in the Team ID box.
  7. Enter your Slack Incoming Webhook URL in the Incoming Webhook URL box.
  8. Click Save.
  9. If you are going to post messages to Slack, click the Rules tab, enable the post action, and specify any necessary rules.
  10. Click Save.

Pipelines and Slack Service

With MongoDB Stitch, you can define a sequence of actions to perform as a pipeline of stages. For the Slack service, MongoDB Stitch provides the following actions:

Action Description
post Sends a Slack message to a specified channel.

Note

A pipeline can consist of stages that use different MongoDB Stitch services.