Notification to be sent to RITM Reference Variable

Steve Brown1
Tera Expert

Hi Community,

I am very near to completing an End to End Joiner process, however, I am stuck trying to get a Notification to send to a Variable stated on the Request Item once the Request is Closed Complete.

This Notification is to replace the generic Request Closed Notification that is sent for all other Requests as it will contain next-steps information for the Manager.

Currently I have configured:

Create Event Workflow Stage:

find_real_file.png

Which calls the Event ad.account.created:

find_real_file.png

Which is set on the Notification:

Table:                                                     sc_req_item

Type:                                                       EMAIL

When to Send

Send when:                                     Event is Fired

Event name:                                   ad.account.created

Weight:                                                 0

Conditions:                                       None listed

Who will receive

Event Parm 1 recipient       TRUE

What will it contain:

Message HTML:                           Generic email

**Also, how do I reference the jml_joiner_manager variable so the manager name is visible?**

The Event is getting added to the Event Log and is getting processed but no emails are coming out of ServiceNow.

Does anyone have any suggestions?

Regards,

Steve

6 REPLIES 6

pabitras
Giga Contributor

I tried this now which is similar to Steve's approach but I need variable name in To in the notification.

1. Created Create Event Activity in Workflow and mentioned even name.

2. Created an event in event registry in servicenow.

3. Created a Notification and selected event to trigger the notification.

But the email is not coming to email logs... Please see the updated workflow and workflow status when RITM closed:-

find_real_file.png

find_real_file.png

find_real_file.png

Thanks,

Pabitra


Hi Pabitra,

The way I setup the workflow to call out the variable is explained below:

Within the Workflow I added a Run Script Stage with the following script:

var eventParm1 = current.variables.iiq_joiner_manager.email;

gs.eventQueue("ad.account.created", current, eventParm1);

Where it states 'current.variables.iiq_joiner_manager.email' you need to change this to your variable name.

Where I have 'ad.account.created' you need to change this to call your Event name.

 

Complete the Event info to your requirements

Name - ad.account.created

Table - Requested Item

Fired By - Service Catalog workflow

Desc - AD Account created

 

Within the Notification:

WHEN TO SEND

Send when - Event if fired

Event Name - ad.account.created

 

WHO WILL RECEIVE 

Event parm 1 contains recipient - TRUE

 

Let me know if you need any further help.

Regards, 

Steve