email CC notifications to group members

Rafał Rataj
Tera Contributor

Hi, 

I was recently working with notifications

it seems if you add a group to the Notifikation CC via E-Mail script   email.addAddress("cc"

the group is added 

but additional Group features are not working 

I mean mainly the include members where the notification should be send to the group users and not to the group email 

// include members are working fine if the notification has the group in the receivers added the normal way 

 

do you know any configuration that would allow that or am I doomed to script that? 

3 REPLIES 3

Uncle Rob
Kilo Patron

Is there a particular reason why the group needs to be CC and not TO?

PrashantLearnIT
Tera Sage

Hi @Rafał Rataj 

 

You can create an email script and call that in email notifications.

 

email script name - addCCGroup

 

Code - 

var grMember = new GlideRecord('sys_user_grmember');

grMember.addQuery('group', current.assignment_group);

grMember.query();

while(grMember.next())

{

email.addAddress('cc', grMember.user.email, grMember.user.name);

}

 

Call email scripts as ${mail_script:addCCGroup}

@PrashantLearnIT 
thank you, the question was more conceptual if the script to resolve group members is the only way to do it.