1
0
ansible-home-assistant/configuration/automations/front-door-doorbell.yaml

32 lines
776 B
YAML
Raw Normal View History

- id: front-door-doorbell
2022-08-18 23:02:16 +00:00
alias: '[Front door] Doorbell'
2021-05-11 18:34:52 +00:00
mode: restart
trigger:
- platform: state
entity_id: switch.doorbell_button_switch
from: 'off'
to: 'on'
action:
- service: script.turn_on
entity_id: script.doorbell_bell
2022-08-17 00:25:51 +00:00
- service: notify.mobile_app_iphone_pg
2021-05-11 18:34:52 +00:00
data:
2022-08-17 00:25:51 +00:00
message: Doorbell
data:
actions:
- action: UNLOCK_DOOR
title: Unlock door
2021-05-11 18:34:52 +00:00
2022-08-18 23:02:16 +00:00
- id: font-door-doorbell-bell-burn-prevention
alias: '[Front door] Doorbell bell burn prevention'
2021-05-11 18:34:52 +00:00
mode: restart
trigger:
- platform: state
entity_id: switch.doorbell_bell
from: 'off'
to: 'on'
for:
seconds: 1
2021-05-11 18:34:52 +00:00
action:
- service: switch.turn_off
entity_id: switch.doorbell_bell