Rest Call Trigger !!

sanyalshubh
Tera Contributor

How to trigger Rest Call?

1. Using Flow ?? or BusinessRule which one is best practice

3 ACCEPTED SOLUTIONS

Dr Atul - LNG
Tera Patron

Hi @sanyalshubh 

 

if you want to  go low code/ no code go for Flow else BR. The recommendation is flow.

View solution in original post

Ravi Gaurav
Giga Sage

Hi @sanyalshubh 

Both way you can use ..
for Scripting you can use :-

We can write server side script by using below REST API class.
sn_ws.RESTMessageV2('rest_message_name','method_name');
for Flow you can create a flow action and perform call that action on main flow with the API call configured

View solution in original post

Sandeep Rajput
Tera Patron

@sanyalshubh The both can be used in this case but making a rest call via an aync business rule will be a more performant approach than a flow/workflow. Adding a flow context to a record for an API call is going to make entries in a lot of flow related tables in ServiceNow on the flip side making the API call from an aync business rule will not  have such overheads.

View solution in original post

4 REPLIES 4

Dr Atul - LNG
Tera Patron

Hi @sanyalshubh 

 

if you want to  go low code/ no code go for Flow else BR. The recommendation is flow.

Ravi Gaurav
Giga Sage

Hi @sanyalshubh 

Both way you can use ..
for Scripting you can use :-

We can write server side script by using below REST API class.
sn_ws.RESTMessageV2('rest_message_name','method_name');
for Flow you can create a flow action and perform call that action on main flow with the API call configured

Sandeep Rajput
Tera Patron

@sanyalshubh The both can be used in this case but making a rest call via an aync business rule will be a more performant approach than a flow/workflow. Adding a flow context to a record for an API call is going to make entries in a lot of flow related tables in ServiceNow on the flip side making the API call from an aync business rule will not  have such overheads.

Ankur Bawiskar
Tera Patron

@sanyalshubh 

well it depends on your requirement and how complex the REST call is

If it's pretty straight forward then use low-code, no code Flow

If it's complex then use Business rule or script include.

If my response helped please mark it correct and close the thread so that it benefits future readers.