Slack integration with Bitbucket

Use Slack App to thread pull request messages

This application was acquired by Votazz.

Please seek support here - https://marketplace.atlassian.com/vendors/1219338/votazz

The new guides are here - https://docs.votazz.co/

Summary

Below you will find the details on how to create a simple Slack App that permits Slack notifications for Bitbucket App to create threads for each pull request instead of posting all messages as separated messages.

Slack Bot creation

Url to create a new Slack App: https://api.slack.com/apps

slack-bitbucket-integration-01.png

Click on “Create New App“.

Then choose: “From scratch”

slack-bitbucket-integration-02.png

Fill in the required information:

slack-bitbucket-integration-03.png

After the application is created required permissions should be added. Go to “OAuth & Permissions”

slack-bitbucket-integration-04.png

Scroll down to “Bot Token Scopes”. Add next permissions:

slack-bitbucket-integration-05.png

Then scroll up and install the app to the workspace:

slack-bitbucket-integration-06.png

Choose the channel to post messages:

slack-bitbucket-integration-07.png

Your token is ready:

slack-bitbucket-integration-08.png

Additional useful links:
https://api.slack.com/authentication/basics
https://api.slack.com/authentication/token-types

Using Bot token in Bitbucket Slack plugin

Bot token can be used in Bitbucket Slack plugin settings at any level instead of the Incoming Webhook URL.

slack-bitbucket-integration-09.png

If OAuth token is used then all messages related to the same pull request are grouped in a thread.

slack-bitbucket-integration-10.png

Which looks like this when open.

slack-bitbucket-integration-11.png

Updated: