Scripts and Automations

11. Scripts and Automations

The Scripts and Automations feature in SLZB-OS lets you create and run your own automation logic directly on the coordinator, without needing an external controller to send every command. Scripts can respond to events, toggle GPIOs, interact with the Zigbee hub, or perform other custom actions.


image.png

11.1 Overview

For examples and full API documentation, refer to the official repository:
???? https://github.com/smlight-tech/slzb-os-scripts


11.2 Script Manager

The Script Manager section contains the list of available scripts and their control options:

Field / Button Description
Status Shows whether the script is enabled/disabled.
Filename The name of the script file stored in the coordinator.
Run on boot Toggle to run the script automatically after the device boots.
Actions Buttons to edit, run, stop, or delete the script.

11.3 Adding a Script

  1. Click the “+” button in Script Manager to create a new script.

  2. Enter your code in the built-in script editor.

  3. Save the script — it will appear in the list with its filename.

  4. Optionally enable Run on boot.


11.4 Running a Script


11.5 Editing / Updating a Script


11.6 Removing a Script


11.7 Notes & Best Practices


Revision #1
Created 14 August 2025 20:32:34 by Support3
Updated 14 August 2025 20:33:11 by Support3