Scripts
Use scripts to implement custom logic for handling edge cases that aren't covered by the standard product functionality. Scripts are maintained on the Settings > Scripts page and can be used across each of your workspaces.
SquaredUp currently supports two types of scripts:
Tile data scripts
Most of the time, you'll be able to use the data streams provided by a plugin to visualize the data how you want. However, there may be circumstances where you want to fetch data that isn't provided by the available data streams. In cases such as these, you can instead use a tile script.
These scripts scripts allow you to write your own logic to query the map and data streams in any way you want, and give you the ability to manipulate data in ways that data streams can't. For example, you can create tile scripts to:
- Combine multiple graph queries.
- Combine multiple data streams.
- Make data streams dependent on the results of a graph query (and vice versa).
- Filter graph data and data streams in ways you normally can’t.
- Further manipulate your data before visualizing it.
See Tile Data Scripts for a comprehensive guide.
Monitor condition scripts
This feature is available with an Enterprise plan
When adding a monitor to a tile, you might occasional find that you're unable to configure a state or threshold using the available data. Or you may want to evaluate a state based on some complex logic. In cases such as these, you can instead use a monitoring condition script.
These scripts allow you to write your own logic for returning error states to the tile editor. You can also define parameters in your scripts which you can then populate using your data stream data when configuring a tile.
See Monitor Condition Scripts for a comprehensive guide.