Send email from Business rule script
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎06-26-2017 04:32 AM
Hi,
I'm trying to find solution how to send e-mail from Business rule script. I have find GlideEmailOutbound() class, but I can only define its fields with setters. What to do next?
- Labels:
-
Best Practices
-
Scripting and Coding

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎06-27-2017 04:58 AM
Hi Denis,
Emails can be sent from business rules using an event. You can create an event (or use an existing one) in the Event Registry. Triggering the event in the BR is done using gs.eventQueue(). The notification is set up to react to the event being triggered.
Email Notifications - ServiceNow Wiki
Events and Email Notification - ServiceNow Wiki
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎06-27-2017 05:36 AM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎05-25-2021 11:05 PM
Is there any way to pass parameters from the business rule via the trigger into the email? I'd like to publish them into the email body
Thank you
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎05-25-2021 11:18 PM
Hi Greg,
Yes parameters can be passed in event. Below is the syntax:
gs.eventQueue('eventName',current,Parm1,Parm2);
Kindly mark this Helpful if it helps!