You're on your way to the next level! Join the Kudos program to earn points and save your progress.
Level 1: Seed
25 / 150 points
Next: Root
1 badge earned
Challenges come and go, but your rewards stay with you. Do more to earn more!
What goes around comes around! Share the love by gifting kudos to your peers.
Keep earning points to reach the top of the leaderboard. It resets every quarter so you always have a chance!
Join now to unlock these features and more
I'm trying to integrate a conditional Slack notification in a specific channel. The goal is to have the notification mention each user listed in a multi-user field so they can get certain urgent notifications.
When I have the smart value in the notification, the automation fails with an error of "Error rendering smart-values when executing this rule." If remove this bit, the rule runs fine.
{{#}}@{{issue.approvers}}{{/}}
Any advice on what I need to modify here is greatly appreciated. Thank you!
When you want to iterate over a list of values in a rule, the syntax is like this:
{{#someList}}{{someFieldOfTheList}}{{/}}
For your case, are you trying to mention on the user's display names? If so, that would be like this:
{{#issue.approvers}}@{{displayName}}{{^last}}, {{/}}{{/}}
That last handling adds a delimiter of ", " between values (leaving off the final one), so please change that as needed.
To learn more about list, smart values, please look here: https://confluence.atlassian.com/automation/jira-smart-values-lists-993924868.html
Kind regards,
Bill
Hi @Bill Sheboy
Thank you so much! Now we're getting somewhere. If I want the username to display instead, what would go there?
The automation worked this time, however it didn't tag users on the Slack side (just the @FirstName LastName without a tag) so I think maybe we should try the username.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You have to use the display name or the member ID that the user have in Slack for the @ mention to work. If all your users are using the default firstname.lastname as the display name then this should work for you:
{{#issue.approvers}}@{{displayName.replace(" ", ".").toLowerCase}}{{^last}}, {{/}}{{/}}
If some of your users have modified their display name in Slack then the only way you can @ mention them in automation is to use their member Id and the syntax for it would look like this:
<@memberId>
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.