Hello,
I want to send an email to people who have chosen to watch certain issues and to notify them when the issues reach a certain status.
I am using this structure:
I saw this from this article:
If this {{issue.watchers.emailAddress}} returns the watcher's email address shouldn't that rule send an email to all watchers by putting this smart value in the email address line. I also tried {{#issue.watchers.emailAddress}}{{/}}.
I get an error and no e-mails are sent over. The rule returns at least 1 item and I made sure that I am added as a watcher.
Any insight would be appreciated.
Thank you,
Artur
You are using {{lookupIssues}} to retrieve multiple issues and then use {{issue.watchers.emailAddress}} as a smart value to retrieve the To email address(es), but you have not specified / initiated an issue in your rule. That is why there is no email address found.
You could retrieve a list of unique email addresses through a lookup Issues action and then add a branch to your rule For each / Smart value, sending the email to each email address.
As an alternative, if you could also use a filter subscription to send email notifications. That is a lot easier to use, does not impact your automation rule limit for your site, but has 2 limitations against your current approach:
I suppose the amount of effort you should put into this relates to the desired outcome you're trying to achieve ...
Hope this helps!
Hello Walter,
Thank you for the reply! I assumed that it would at least pick up one watcher and started to think that there is an issue with the smart value.
I'll try what you suggested with retrieving the email addresses.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
+1 Walter, branching should get you there to process through each returned issue.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Adding to the other suggestions offered...
The watchers field is a list of users, and when this smart value expression is used in the Send Email action's To field:
{{issue.watchers.emailAddress}}
By default, it joins them with commas. However, the Send Email action uses a semicolon delimiter between email addresses. To solve this, please select that specifically with the join() function instead:
{{issue.watchers.emailAddress.join("; ")}}
Kind regards,
Bill
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Spend the day sharpening your skills in Atlassian Cloud Organization Admin or Jira Administration, then take the exam onsite. Already ready? Take one - or more - of 12 different certification exams while you’re in Anaheim at Team' 25.
Learn more
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.