Post a Message to Slack
This listener allows you to send a personalized custom message to your Slack room. When configuring a listener there are bindings for the issue object and event object.
For example, you want to be notified in a Slack channel when an issue is moved to Done and what the resolution is set to.
"Issue $issue resolved with resolution <% out << issue.resolution?.name %>. by <% out << event.getUser() %>"String templating in groovy
There are two variables available for you to use in your template, "issue" and "event".
Check the documentation about constructing your string template for the last field of the form:
As a summary, in order to call a property, you can call it with the name
"Your issue $issue has been updated."But you can do more complex calls to your object by using the <% %> notation:
"Your Issue $issue was updated by <% out << event.getUser() %> on <% out << event.getTime() %>."