Could someone please help to write an automation to trigger whenever any of the 500 entities i have become unavailable for 30 seconds or more. I cant seem to find any info on how to do this. i thought maybe with trigger event on state_changed but i have no idea how to do something like this.
Could someone help me with this.