I am looking for a way to send a notification to my iPhone that my garage door is left open at a particular time, say 8:00 pm or at sundown, etc, as a trigger. It doesn’t happen often, but sometimes the garage door gets left open all night. I’m reasonably new to Home Assistant (since Mid April, like many newbies). I’ve been trying to figure it out in Automations, but so far I haven’t found the right combination.
Here’s mine:
- alias: Garage Door Open
initial_state: true
trigger:
platform: numeric_state
entity_id: sun.sun
value_template: '{{ state.attributes.elevation }}'
below: -0.5
condition:
condition: state
entity_id: binary_sensor.garage_door
state: 'on'
action:
service: notify.heartbeat
data:
message: Reid St - garage door still open!
I send via SMS, if you want a notification through IOS on your phone you’ll have to read up on the IOS integration I assume:
Generic example of setting up a notification on the IOS page:
automation:
- alias: 'Send Notification'
trigger:
...
action:
- service: notify.mobile_app_<your_device_id_here>
data:
message: "Notification text"