--- title: Script includes description: Script includes are used to store JavaScript that runs on the server.Script includes have a name, description, and, script. They also specify whether they are active or not, and whether they can be called from a client script. View existing or create a new script include using the Script Include form.Script includes are found under System Definition or System UI. You can call existing script includes from a script or create a new script include.Glide AJAX enabled Script Includes make the script include available to client scripts, list/report filters, reference qualifiers, or if specified as part of the URL.Privacy settings for Glide AJAX enabled script includes determine who can access a Glide AJAX enabled script include.Change the privacy setting for a single Glide AJAX enabled script include by adding the isPublic\(\) function.Protect your Glide AJAX enabled script includes against unauthorized use. For all records which are created a customer application, recommendations display that may help reduce security risk.Discovery script includes define JavaScript classes that you can use to accomplish Discovery tasks.When writing Discovery sensors and sensor-related scripts, you may want to use DiscoveryException or AutomationException to indicate that an exception has come from Discovery. locale: en-US canonical_url: https://www.servicenow.com/docs/r/australia/api-reference/scripts/c\_ScriptIncludes.html release: australia product: Scripts classification: scripts topic_type: concept last_updated: "2026-03-12" reading_time_minutes: 10 breadcrumb: [Server-side scripting, Scripting, API implementation, API implementation and reference] --- # Script includes Script includes are used to store JavaScript that runs on the server. Create script includes to store JavaScript functions and classes for use by server scripts. Each script include defines either an object class or a function. Consider using script includes instead of global business rules because script includes are only loaded on request. See [Privacy settings on Glide AJAX enabled script includes](https://raw.githubusercontent.com/ServiceNow/ServiceNowDocs/australia/markdown/australia/api-reference/scripts/c_ScriptIncludes.md) and [Discovery script includes](https://raw.githubusercontent.com/ServiceNow/ServiceNowDocs/australia/markdown/australia/api-reference/scripts/c_ScriptIncludes.md) for more information. For additional examples of scripts, see [Useful scripts](https://raw.githubusercontent.com/ServiceNow/ServiceNowDocs/australia/markdown/australia/api-reference/scripts/usefulScripts.md). **Parent Topic:**[Server-side scripting](https://raw.githubusercontent.com/ServiceNow/ServiceNowDocs/australia/markdown/australia/api-reference/scripts/c_ServerScripting.md) ## Script include form Script includes have a name, description, and, script. They also specify whether they are active or not, and whether they can be called from a client script. View existing or create a new script include using the Script Include form. To access script includes, navigate to **All** > **System Definitions** > **Script Includes**.
| Field | Description |
|---|---|
| Name | The name of the script include. If you are defining a class, this must match the name of the class, prototype, and type. If you are using a classless \(on-demand\) script include, the name must match the function name. |
| API Name | The internal name of the Script Include. Used to call the Script Include from out-of-scope applications. |
| Glide AJAX enabled \(or Client callable\) | The script include is available to client scripts, list/report filters, reference qualifiers, or if specified as part of the URL. Glide AJAX enabled script includes are invoked from `GlideAjax` and require that users satisfy an ACL associated with the script include. When selected, the **Access Controls** Related Link is available. See [Privacy settings on Glide AJAX enabled script includes](https://raw.githubusercontent.com/ServiceNow/ServiceNowDocs/australia/markdown/australia/api-reference/scripts/c_ScriptIncludes.md) for more information. |
| Mobile callable | The script include is available to client scripts called from mobile devices. |
| Sandbox enabled | The script include is available to scripts invoked from the script sandbox, such as a query condition.**Important:** Script includes should only be made available to the script sandbox if necessary. For information about the script sandbox, see [Script sandbox evaluator](https://raw.githubusercontent.com/ServiceNow/ServiceNowDocs/australia/markdown/australia/api-reference/scripts/script-sandbox.md). |
| Application | The application where this script include resides. |
| Accessible from | Sets which applications can access this script include: - **All application scopes** Can be accessed from any application scope. - **This application scope only** Can be accessed only from the current application scope. |
| Active | Enables the script include when selected. Deselect the active field to disable the script include. |
| Description | Provides descriptive content regarding the script include. |
| Script | Defines the server side script to run when called from other scripts.The script must define a single JavaScript class or a global function. The class or function name must match the **Name** field. |
| Package | The package that contains this script include. |
| Created by | The user who created this script include. |
| Updated by | The user who most recently updated this script include. |
| Protection policy | Sets the level of protection for the script include: - **None** Allows anyone to read and edit this downloaded or installed script include. - **Read-only** Allows anyone to read values from this downloaded or installed script include. No one can change script values on the instance on which they download or install the script include. - **Protected** Provides intellectual property protection for application developers. Customers who download the script include cannot see the contents of the script field. The script is encrypted in memory to prevent unauthorized users from seeing it in plain text. |
| Related lists on the form view: | |
| Versions | Shows all versions of the script include. Use this list to compare versions or to revert to a previous version. See [Versions](https://raw.githubusercontent.com/ServiceNow/ServiceNowDocs/australia/markdown/application-development/c_Versions.md). |
| Access Controls | Becomes available when the **Glide AJAX enabled** is selected and is hidden from standard script includes. Use to protect a script include against unauthorized use when public access is not granted. |