How to suppress the notification email after RITM flow is triggered

Yuanquan Fu
Tera Contributor

I'm working migrating legacy data into ServiceNow RITM records. I tried to import legacy data in a csv file and generate related RITM records via transform map. 

 

In the OnAfter transform script, I added following code to trigger the flow: 

try {
        var inputs = {};
        inputs['table_name'] = 'sc_req_item';
        inputs['request_item'] = target; // GlideRecord of table: sc_req_item

        // Execute Synchronously: Run in foreground.
        sn_fd.FlowAPI.getRunner().flow('global.generic_flow_for_single_catalog_task_without_approval').inForeground().withInputs(inputs).run();

   } catch (ex) {
        var message = ex.getMessage();
        gs.error(message);
  }
 
With this: 
(1) assignment rule was triggered and assignment notification emails were sent out to RITM assignment groups. 
(2) For closed RITMs, a RTIM completion notification email was sent out. 
 
My question is: Is it possible to suppress these notification emails after the RITM flow is triggered?
 
Thanks in advance,
Yuanquan
2 REPLIES 2

Shivalika
Mega Sage

Hello @Yuanquan Fu  

 

Add one line on whatever table you are making the updates - just add "gr.setWorkflow(false)" 

 

That's how we do update in TMs without sending any notifications. 

 

Kindly mark my answer as helpful and accept solution if it helped you in anyway. This will help me be recognized for the efforts and also move this questions from unsolved to solved bucket. 

 

Regards,

 

Shivalika 

 

My LinkedIn - https://www.linkedin.com/in/shivalika-gupta-540346194

 

My youtube - https://youtube.com/playlist?list=PLsHuNzTdkE5Cn4PyS7HdV0Vg8JsfdgQlA&si=0WynLcOwNeEISQCY

Shivalika
Mega Sage

Hello @Yuanquan Fu 

 

Please confirm if you checked my answer. Kindly mark my answer as helpful and accept solution if it helped you in anyway. This will help me be recognized for my efforts and also it can move from unsolved bucket to solved bucket. 

 

Regards, 

Shivalika 

 

My LinkedIn - https://www.linkedin.com/in/shivalika-gupta-540346194

 

My youtube - https://youtube.com/playlist?list=PLsHuNzTdkE5Cn4PyS7HdV0Vg8JsfdgQlA&si=0WynLcOwNeE