Comment on page
StackState Self-hosted v4.6.x
Functions in StackState are predefined scripts that transform input into an output. They are called by StackState on-demand. For example, when a component changes state, new telemetry flows in or a user triggers an action. Advanced users can develop their own functions to customize StackState. These functions can then be exported and packaged with a custom StackPack.
Functions in StackState run with either synchronous or asynchronous execution. For some functions it is possible to choose the execution type.
- Synchronous execution - functions do not have access to the StackState script APIs. If the function offers the possibility to be run with either asynchronous or synchronous execution, it is recommended to use asynchronous execution.
To improve performance, some default StackState functions have been implemented as native functions. It is not possible to view or edit the script body of a native function in the StackState UI. It is not possible to create a custom native function.