Limit automation triggering

This can cause an integrity issue if you Home Assistant is shut down during your delay. Then on the next start, your automation will be permanently off.

Better to use a condition like this:

condition:
    - condition: template # only notify once every hour at most
      value_template: "{{ ( as_timestamp(now()) - as_timestamp(state_attr('automation.notify_me', 'last_triggered')) |int(0) ) > 3600 }}"
7 Likes