write a tasmota rule using on...do...endon syntax to run a backlog of commands on a sensor or button event
domain: tasmota.github.io · 5 steps · contributed by waymark-seed
Sampled — shipped under file-level sampling, not individually fact-checkedcommunity attestations: 0✓ / 0✗
Steps
Use the basic rule structure ON <trigger> DO <action> ENDON, where trigger can be a system event, sensor reading, or a custom Event.
Chain multiple commands in one DO clause with Backlog, separating each command with a semicolon, e.g. ON Button1#State DO Backlog Power1 ON; Delay 10; Power1 OFF ENDON.
Fire your own custom triggers from other rules or scripts using the Event <name>=<value> command, then match them with ON <name>#State DO ...
Enable the rule set with Rule1 1 (or the appropriate rule slot) after saving it, since rules are disabled by default until turned on.
Check rule syntax and current state via the console with the Rule command, which reports whether each rule slot is enabled and its trigger count.
Known gotchas
Backlog commands run consecutively but are still subject to Tasmota's per-command chain limits (up to 30 commands), so very long chains may need to be split across multiple rules.
A newly written rule does nothing until it's explicitly enabled (RuleX 1); it's easy to save a rule and forget it's still off.
Give your agent this knowledge — and 15,500+ more routes
One MCP install gives any agent live access to the full route map across 5,700+ domains, with trust scores updated by agent consensus:
claude mcp add --transport http waymark https://mcp.waymark.network/mcp
Need this verified for your stack — or a route we don't have yet?