Email launched by event not working.

santrym
Mega Expert

I'm really puzzled. I have an event triggered email working in our Dev environment, but I cannot get it to work in the Test environment. I have checked the even log, and the events are being triggered, but then when I check the email log, there is nothing there. My email notification is supposed to be triggered by the even seen in the log, but nothing is happening. Is there any known issues with firing emails from events? Any ideas of what I should check? I feel like I've tried everything. Any advice/thoughts would be appreciated. Thanks

1 ACCEPTED SOLUTION

santrym
Mega Expert

Turns out the issue was that when I passed an inactive user as a parameter, nothing would be sent, even if the user record had an email address. To get around this, I just passes the user's email as the parameter.


View solution in original post

13 REPLIES 13

Hey Berny,



      Yes it is showing up in System Logs >> Events. Still not showing up in the email logs though (System Logs >> Emails). I don't expect it to actually send, since it's in the test instance and emailing is disabled, but it should still appear in the email log correct?


Yeap. That's right. It should show in the email log.



Some additional things you could check:



a) validate the table on which your event and notification are configured on


b) within the notification record, at the advanced options, make sure the Send to Event creator is checked



Thanks,


Berny


If the event entry is in your event logs then your event is getting triggered.



The following step will be to make sure that your email is getting triggered by going to the email logs. If there's an entry for the email within the email logs then the next step is just to validate that your system is setup to send emails. This can be done from the email properties.



Since you said that the logic was working as expected in Dev but not in Test, the above validation is what i feel you need to go through.



Thanks,


Berny


Hi Michael,



I mean go to:     https://<your instance>.service-now.com/sysevent_register_list.do



and click new to register the event.     Without that, even the gs.eventQueue() call will do nothing.   (Even though it will show up in the Event Log when you trigger it.)



New Event Registration form will look like this:


find_real_file.png



Regards,



Trey Carroll


Pradeep Sharma
ServiceNow Employee
ServiceNow Employee

Hello Michael,



Navigate to the respective notification and under who will receive tab, please make sure send to event creator checkbox is set to true. You will see those fields on the form once you click on Advanced view related link.