This workflow posts a notification to Slack when an issue is created, resolved, or reopened.
|Modules||Send notification to slack when an issue is reported, resolved, or reopened (on-change rule)|
This workflow helps teams who use Slack as their primary communication hub to stay up to date with their issues in YouTrack.
While the workflow is written to post notifications to Slack when an issue is created, resolved, or reopened, you can easily customize this notification scheme to include other events that are important to you.
To use this workflow, you need to create an Incoming Webhooks Integration in Slack. This gives you the ability to post a message from an external source to a specific channel in Slack. For instructions, refer to the Slack App Directory.
When you add an Incoming Webhook, Slack generates a Webhook URL.
Copy this URL and use this as the value for the
var SLACK_WEBHOOK_URL statement in the on-change rule. You might also take a minute to read through the setup instructions on this page in Slack, as it explains exactly how this integration works and can help you identify how to customize this workflow should you want to modify the message content and appearance.
Note that Incoming Webhooks are channel-specific. If you want to send notifications to different channels on a per-project basis, you can add separate modules to this workflow for each project team. You can then configure copies of this rule to send notification to the channels that are used by each team.
When an is created, resolved, or reopened, this on-change rule posts a notification to Slack. The JSON payload that contains the message is defined in the
var payload statement.
If a message is not posted successfully, a warning is posted to the workflow console.
Send notification to slack when an issue is reported, resolved, or reopened