Difference between script actions and script includes?

chenna
Kilo Contributor

Difference between script actions and script includes?

1 ACCEPTED SOLUTION

Ankur Bawiskar
Tera Patron
Tera Patron

Hi Chenna,

As such both are unique in their own ways;

I will list down their uses and that should help you differentiate

Script Action - server side

1) Used mostly to perform some transactions or updates asynchronously; such as close child incidents when parent incident is closed

2) requires event to trigger

3) when event is processed script action triggers 

Script Include - server side

1) holds reusable code which can be called from multiple server side scripts; such as business rule, workflow, script action or another script include itself

2) used by client scripts to perform GlideAjax calls

Mark Correct if this solves your issue and also mark 👍 Helpful if you find my response worthy based on the impact.
Thanks
Ankur

Regards,
Ankur
Certified Technical Architect  ||  9x ServiceNow MVP  ||  ServiceNow Community Leader

View solution in original post

2 REPLIES 2

Ankur Bawiskar
Tera Patron
Tera Patron

Hi Chenna,

As such both are unique in their own ways;

I will list down their uses and that should help you differentiate

Script Action - server side

1) Used mostly to perform some transactions or updates asynchronously; such as close child incidents when parent incident is closed

2) requires event to trigger

3) when event is processed script action triggers 

Script Include - server side

1) holds reusable code which can be called from multiple server side scripts; such as business rule, workflow, script action or another script include itself

2) used by client scripts to perform GlideAjax calls

Mark Correct if this solves your issue and also mark 👍 Helpful if you find my response worthy based on the impact.
Thanks
Ankur

Regards,
Ankur
Certified Technical Architect  ||  9x ServiceNow MVP  ||  ServiceNow Community Leader

Sanket Khabiya
Kilo Sage

Hello,

Below 2 links can explain you better:

Script Action

Script Include

 

Regards,

Sanket