Slack Integration

Slack is a team communication tool that provides real-time messaging. AlertSite can be integrated with Slack, so that you can receive updates in a Slack channel whenever a monitor alert is triggered in AlertSite.

AlertSite UXM alerts in Slack

In This Guide

About Slack Templates

The key point in getting Slack alerts to work is to create Slack-compatible alert templates in AlertSite. This is required because the default alert format used by AlertSite is not recognized by Slack. You will need two templates – one for “error” messages and another for “all clear”. Remember that custom templates apply only to recipient groups, so you will also need to create a recipient group for Slack and your custom templates. This guide will walk you through all those steps.

The alerts templates must follow Slack message format. You can create simple text messages using the text field:

  "username": "AlertSite",
  "icon_url": "",
  "text": "$DESCRIP is ERROR at $LOCDESC as of $DTSTATUS."

or add attachments and fields to create richly-formatted messages like those on the image at the top of this page.

  "username": "AlertSite",
  "icon_url": "",
  "attachments": [
      "color": "danger",
      "title": "$DESCRIP is ERROR at $LOCDESC",
      "fallback": "[PROBLEM] $DESCRIP is ERROR at $LOCDESC as of $DT_STATUS",
      "fields": [
          "title": "Last Checked",
          "value": "$DT_STATUS",
          "short": true
          "title": "Last Status",
          "value": "$STATUS - $MSG",
          "short": true

Note: The actual templates used in this guide can be found in the Creating Alert Templates section below.

If you want to create your own templates:

Creating a Slack Webhook

First you need to set up an incoming webhook integration in Slack:

Configuring AlertSite

Creating Alert Templates

Next, create alert templates in the format recognized by Slack:

Note: These templates are just examples. You can design your own templates as explained above.

Adding a Slack Recipient

Once you set up alert templates, you can add Slack as an alert recipient in AlertSite:

Creating a Recipient Group

Finally, you need to associate the Slack alert templates with the Slack recipient. This is done by creating a recipient group that contains the Slack recipient, the custom templates, and the monitors whose alerts you want to send to Slack:

Now you will receive updates in Slack when the selected monitors trigger alerts.

Testing Slack Alerts

To send a test alert from AlertSite to Slack, do the following:

Note: If you get a 500 Internal Server Error when sending an alert, verify your template syntax in the Slack message builder and make sure the Slack webhook URL is correct.


How can I route alerts from different monitors to different Slack channels?

Configure webhooks and AlertSite recipients for each channel, then create separate recipient groups for each Slack channel and the corresponding monitors.

See Also

© 2017 SmartBear Software. All rights reserved.      Terms of Use · Privacy Policy