Rule Engine: Overview and Introduction
SharpTools Rule Engine is a visual rule builder that can be used to create simple or powerful automations without any coding skills. Rules created in the Rule Engine can be triggered by events, time schedules or manually run from SharpTools dashboards.
Rule Engine supports multi-triggers, multi-If-conditions and multi-actions for users to create powerful automation in a simple interface.
How to create automation rules in Rule Engine?
What is a Trigger?
Triggers determine when to execute a rule. There are several types of triggers available including:
Event Triggers
Device status change
Ex: light is turned on, motion is active, door is opened, or temperature is changed
Location event
Ex: Mode changed, Hubitat Safety Monitor (HSM) state change, etc
Variable value change
Ex: True/False variable changes state, text or numeric value changes
HTTP / Webhook (learn more)
Ex: Trigger from IFTTT, iOS Shortcuts, Tasker, Home Assistant, etc.
Timer Triggers
- Schedule at specific time of the day and on specific day of the week
- Schedule at sunrise/sunset with offset on specific day of the week
What is the Flow?
The Rule Flow is the set of activities that will occur when the rule is triggered. The Flow can consist of multiple activities including conditions, actions, and delays. There are several activities that can be added in the Flow section:
IF Condition
Device condition
Check a device attribute's status/value is as specified (is, is not, greater then, greater then or equal to, less than, less than or equal to, and stayed)
Ex: light switch status is on, door contact status has stayed open for 10 minutes, bulb level is greater than 50, or temperature sensor is less than 30
Location condition
Check if the location's current mode or SHM/HSM status is as specified.
Ex: mode is 'Night', SHM/HSM is 'Armed away', etc
Day of the week
Check if the current day is the specific day of the week
Time of the day
Check if the current time is before or after a specific time or sunset/sunrise
Variable condition
Check if a custom variable or context variable is a specific value
IF Conditions can be added within another IF Condition to create nested condition logic
Action
Device action
Ex: turn the light on, close the door, set thermostat level, play music to smart speaker and etc.
Location action
Ex: change mode status or change SHM/HSM status.
Notification
Send a SMS (Premium, US only), Textbelt SMS (International), Twilio SMS (International), Email, Pushbullet, or Pushover notification.
Set Variable
Ex: store the triggering devices name in a variable or store the result of a condition
HTTP / Webhook (learn more)
Call a service on a third party website like IFTTT, WebCoRE, Voice Monkey and more