Slack Chats

Slack integration

If your team uses a chat such as Slack to discuss projects, the ALM integration will be useful. The default integration (mapping) settings let you connect a chat bot that:

  • Notifies the team about a new Request or Issue, a Build status, test results, and so on;
  • Tells a project member about an assigned Issue or Task;
  • Notifies the assignee, author, or watchers about a new comment on an Issue or Task added in ALM;
  • Posts a detailed description of a Task or Issue to the chat when any message mentions its identifier, for example I-123 or T-234.

The integration settings can implement almost any scenario for notifying people about actions in the project. How to configure the integration is described below.

Starting the integration

First, register a bot in your Slack account settings. Open Apps & integrations, then Custom Integrations, then Bots, and add a new configuration (Add Configuration). Set the usual bot parameters and take API Token.

In ALM, open the project you want to connect to Slack chats, open the project settings, go to the integrations list, and add a new integration named "Slack". On the integration form, specify the default channel name, the API Token, and the bot name.

The integration is ready.

Configuring the mapping

ALM and Slack are already set up to implement the scenarios described at the beginning. You can add many more scenarios that are useful for your team. The mapping structure repeats the requests sent to Slack API for each entity, for example Issues, Tasks, Builds, and so on.

ALM users are matched to Slack users by email. You can therefore send messages to a specific Slack user's channel.

In request fields you can use any text and attribute substitutions, for example "A new Build is out: %Caption", where %Caption is replaced with the Build name (number). That's it.

You can send different requests when artifacts are created (add) or changed (update). When an artifact changes, a "Changed" attribute is added that lists the attributes that changed. You can specify extra conditions (filter) that are checked before the request is sent to the Slack API. In the filter field, write an XPath expression that can use the artifact's attributes or the attributes of its references.

Debugging the integration

As soon as you save the settings, the integration starts. Its results are shown on the "Log" tab. There you can see all available data, errors from the Slack API, and the reasons data was not sent.