Create Event action in flow design

shidhartha
Tera Contributor

How to Create Event action to trigger data loads from active directory from Flow design to sync Scheduled jobs -- LDAP group.

 

 

when the existing flow for Add/remove user from group catalog item includes a Create Event action to trigger data loads from active directory from flow "Add or Remove Users from SNOW Group" to sync scheduled jobs -- LDAP group.

Scheduled jobs -- LDAP group sync

please provide me steps to complete it.

 

1. How to Triger a event via flow designer with syntax to define the event.

2. how to call that sub flow from actually flow "Add or Remove Users from SNOW Group" and from when.

3.How to call Scheduled jobs --" LDAP Group Import " sync.

4. How to test it.

 

3 REPLIES 3

Sumit Pandey1
Kilo Guru
Kilo Guru

Check this article on how to trigger an event from flow designer - 

 

https://community.servicenow.com/community?id=community_article&sys_id=3450a52fdbcf2740afc902d5ca96190b

shloke04
Kilo Patron

Hi,

Please find the response below for your query:

1.How to Triger a event via flow designer with syntax to define the event. --> Please make use of Action named as "Create Record" in Flow Designer as shown below:

find_real_file.png

Now within this action, fill out the details of your Event and this action will create Event Record in Event table which you can leverage to trigger your Scheduled Job using a Script action as shown in next steps below

find_real_file.png

2. how to call that sub flow from actually flow "Add or Remove Users from SNOW Group" and from when.

In order to call Subflow from Flow, there is a button click on that you can call your Sub Flow as shown below:

find_real_file.png

3.How to call Scheduled jobs --" LDAP Group Import " sync.

Now after your first step as soon as the event gets generated you can define a Script action to trigger your Scheduled Job.

Navigate to the module "Script Action" as shown below:

find_real_file.png

Now in the Script Action select your Event Name and then use the script below:

var rec = new GlideRecord('sysauto_script');
rec.get('name', 'YOUR_JOB_NAME_HERE');
if (typeof SncTriggerSynchronizer != 'undefined')
   SncTriggerSynchronizer.executeNow(rec);
else
   Packages.com.snc.automation.TriggerSynchronizer.executeNow(rec);

find_real_file.png

Hope this helps. Please mark the answer as correct/helpful based on impact.

Regards,
Shloke

Hope this helps. Please mark the answer as correct/helpful based on impact.

Regards,
Shloke


Hi,

If your query is resolved, please mark the answer as correct and close this thread for others.


Regards,

Shloke

Hope this helps. Please mark the answer as correct/helpful based on impact.

Regards,
Shloke