Execution Context Types
Use the following descriptions to determine which contexts are important for your script or workflow to run in.
For SuiteScript scripts, each execution context type has an associated value in the runtime.ContextType enum. You can use these values to programmatically determine the context in which a script is executing and customize your script logic based on the context. For more information, see runtime.executionContext.
The following table describes the available execution context types. The table also includes usage notes (if appropriate) and links to other help topics to help you further understand the contexts.
Context |
Description |
Additional Information |
---|---|---|
Action |
Represents a workflow action |
|
Bank Connectivity |
Represents the Bank Connectivity plug-in |
|
Bank Statement Parser |
Represents the Parser plug-in or Bank Statement Parsers SuiteApp |
|
Bundle Installation |
Represents a bundle installation script |
|
Client |
Represents a client script |
|
CSV Import |
Represents a CSV import task To use this context, you must enable the Run Server SuiteScript and Trigger Workflows preference at Setup > Import/Export > CSV Import Preferences. |
|
Custom GL Lines |
Represents the Custom GL Lines plug-in |
|
Custom Mass Update |
Represents a mass update script |
|
Debugger |
Represents the SuiteScript Debugger |
|
Email Capture |
Represents the Email Capture plug-in |
|
Financial Institution Connectivity |
Represents the Financial Institution Connectivity plug-in |
|
Map/Reduce |
Represents a map/reduce script |
|
Other |
Represents a context that is not one of the other available contexts in this table |
— |
Payment PostBack |
Represents a payment postback task |
— |
Payment Processing |
Represents a payment processing task |
|
Platform Extension |
Represents a platform extension customization in Commerce |
|
Portlet |
Represents a portlet script |
|
Promotions |
Represents a promotion in Commerce |
|
Rate Adjustor |
Represents a currency rate adjustor |
— |
REST Web Services |
Represents a REST Web Services request |
|
RESTlet |
Represents a RESTlet script |
|
Revenue Management |
Represents an Advanced Revenue Management task |
Advanced Revenue Management (Essentials) and (Revenue Allocation) |
Scheduled Script |
Represents a scheduled script |
|
SDF Installation |
Represents an SDF installation script |
|
Shipping Partners |
Represents a shipping partners task |
— |
SOAP Web Services |
Represents a SOAP Web Services request To use this context, make sure that the Disable Server SuiteScript and Workflow Triggers preference is not enabled at Setup > Integration > SOAP Web Services Preferences. |
|
Suitelet |
Represents a Suitelet |
|
Tax Engine |
Represents a SuiteTax Engine task |
|
User Event Script |
Represents a user event script This context type represents cases in which records are generated on the backend (as opposed to being generated by the NetSuite UI). For example, the User Event Script context represents the case in which a bill payment record is submitted as part of a non-record page. In contrast, the User Interface context represents the case in which a single bill payment record is submitted from the UI. User event scripts cannot be executed by other user event scripts. Script deployments or workflows with the User Event Script context type cannot run other user event scripts. |
|
User Interface |
Represents an event in the NetSuite UI |
— |
Web Application |
Represents a web application task in Commerce |
|
Web Store |
Represents a web store task in Commerce |
|
Workflow |
Represents a SuiteFlow workflow |