Automation run once a day

I have an automation that puts my phone on silent when I enter a location. It’s no harm but the automation if I leave the building and come back fires again. Is there a way I can get mode, once to only fire once in a 12 hour period for example. Thanks

under action - turn off the automation.
and make another one that turns it on at night ex.

Doesn’t really help because it comes on numerous time in that twelve hour period as I enter and exit the zone, but thanks for suggestion.

create a template condition that returns true if the automation was last triggered longer than 12 hours ago:

{{ state_attr('automation.your_automation', 'last_triggered')|as_local > (now() - timedelta(hours=12) ) }}

Thank-you that worked a treat

1 Like