scheduled job Triggering events but Notification email Not Triggering

BiswalNayak
Tera Contributor

Hi Team, I have implemented a solution where I configured a Scheduled Job, created a custom Event, and set up a corresponding Email Notification. The scheduled job is running successfully and triggering the event using gs.eventQueue(). I have verified this in the Event Log (System Policy → Events → Event Log), and I can see that the events are getting generated with the correct parameters. However, the issue is that email notifications are not being triggered to the assignment group of that incident . I checked the Email Logs (System Logs → Emails), and there are no records being created for this notification.
What I have verified so far:
Scheduled Job is running properly
Event is correctly registered and triggered (incident table)
Event name matches in both script and notification
Event records are visible in Event Logs
Notification is active and configured (incident table) to trigger on the event.

I have attached my script with notification picture. Please give suggestions to trigger the email in the incident assignment group means it will trigger to all the members of that group.

6 REPLIES 6

Tanushree Maiti
Tera Patron

Hi @BiswalNayak 

 

1.  Ensure the members of the assignment group have Notification enabled on their sys_user profiles and that their primary email addresses are populated correctly

 

2. If you are passing an Assignment Group (or its corresponding members) dynamically through gs.eventQueue() , make sure - receipent you are passing property to notification.

  • Open the Email Notification form and go to the Who will receive tab.
  • Check the box for Event parm 1 contains recipient.

3.  Verify that your Email Notification is configured on the exact same table as the incident event  like incident table.

 

 

 

Please Accept the solution if it assisted you with your question & Mark this response as Helpful.
Regards
Tanushree Maiti
ServiceNow Technical Architect
LinkedIn: https://www.linkedin.com/in/tanushreemaiti

Hi,

Thank you for your suggestions.
I have already verified the points mentioned:

The Assignment Group members have email addresses populated and notifications are enabled on their user profiles.
In the Notification configuration, I have enabled “Event parm 1 contains recipient” since I am passing the Assignment Group through gs.eventQueue().
The Notification is configured on the same table (Incident) as defined in the Event Registry.
I have also attached the screenshot of my Notification configuration for reference.

Additionally, I can see that:
Events are getting triggered successfully (visible in Event Logs)
However, no entries are being created in Email Logs, and emails are not being sent

Despite verifying all of the above, the notification is still not triggering.
Could you please help identify if there is anything else I might be missing or any additional configuration that needs to be checked?

Thanks in advance for your help!

 

Hi @BiswalNayak , 

 

Can you please first test the event generation in a background or fix script and verify the following:

- is the group sys_id being retrieved correctly from inc.assignment_group

- is the group active

- is the event name the same as the one in the notification definition

- is the notification active

- is the event state being set to processed

 

If all else fails you could:

- create a test group, add a few members, and pass the sys_id directly in the eventQueue

- create a new event and use it for triggering the notification

- change the notification 'send when' to record inserted or updated, add your group to the definition, and do a test insert or update

- create a new notification with dummy text just for testing

 

Let me know your findings,

Marius

Hi @MariusAlinPopa 
I have tested the event generation as suggested.
The assignment group sys_id is correctly getting captured and is visible in the event logs However, the notification is not getting triggered
I also tried validating with a simple test script and basic setup, but the issue still persists in the Dev instance. The same configuration and logic are working as expected in my PDI and Test instances, where notifications are triggering correctly. Based on this, I suspect this is an instance-specific issue with the Dev environment, possibly related to configuration or email/notification processing.