Forums

Articles
Create
cancel
Showing results for 
Search instead for 
Did you mean: 

Email a usergroup based on smartvalue

Nicholas Shaw June 1, 2022

So I have a select list that is used in various filters. For each of these values, we have an Atlassian group with the same name.

I want to use automation to send an email to the appropriate Atlassian group based on this field's value, but when I use what I think should be a simple smartvalue of {{issue.customField_xxxxx.value}} in the "To" field, it errors out with the "Could not send email, the 'To' address field is empty. If you have referenced a field it may be empty."

I've confirmed that the smart value returns the proper name of the field, and that name has an Atlassian group with the same text.

Is there something I'm missing, or is this functionality just not possible, and instead I need to use a huge block of explicit "if" conditions for the field value?

1 answer

1 accepted

0 votes
Answer accepted
Melo
Community Champion
June 1, 2022

Hi @Nicholas Shaw , 

I think that's even more simple, you don't need to use a smart value. Just click in the "To" dropdown and select the custom field.

I hope that helps.

Cheers,

Melo

Nicholas Shaw June 1, 2022

So unfortunately, the custom field is a Select List, not a Group Picker, so it doesn't show up as an option in the To dropdown.

Melo
Community Champion
June 1, 2022

I see. I mean, Idk the whole use case here. But if for some reason, the user can't use the group field directly, you can create an automation to synchronize the CF (Select List) with the Select Group field. And then use it to send the notifications, but the values on the Select List will need to match with the groups you have.

Cheers,

Melo

Nicholas Shaw June 2, 2022

This workaround worked perfectly. Thankya!

Suggest an answer

Log in or Sign up to answer
DEPLOYMENT TYPE
CLOUD
PRODUCT PLAN
PREMIUM
PERMISSIONS LEVEL
Product Admin
TAGS
AUG Leaders

Atlassian Community Events