74 lines
1.9 KiB
YAML
74 lines
1.9 KiB
YAML
- id: front-door-open-notify
|
|
alias: '[INFO] Front door left open'
|
|
mode: single
|
|
trigger:
|
|
- platform: state
|
|
entity_id: lock.front_door_lock_doorlock
|
|
to: unlocked
|
|
for:
|
|
hours: 0
|
|
minutes: 30
|
|
seconds: 0
|
|
action:
|
|
- service: notify.mobile_app_iphone
|
|
data:
|
|
message: Front Door left unlock for 30 minutes, would you like to close it?
|
|
data:
|
|
actions:
|
|
- action: LOCK_DOOR
|
|
title: Lock door
|
|
|
|
- id: front-door-knock
|
|
alias: '[Front Door] Knock'
|
|
trigger:
|
|
- type: vibration
|
|
platform: device
|
|
device_id: f5e5356b4a45190ec2dad08ca9f991e8
|
|
entity_id: binary_sensor.front_door_vibration
|
|
domain: binary_sensor
|
|
condition:
|
|
- condition: state
|
|
entity_id: binary_sensor.front_door_open_close
|
|
state: 'off'
|
|
- condition: state
|
|
entity_id: binary_sensor.hallway_motion_sensor
|
|
state: 'off'
|
|
action:
|
|
- service: notify.mobile_app_iphone
|
|
data:
|
|
message: Someone knock
|
|
data:
|
|
actions:
|
|
- action: LOCK_DOOR
|
|
title: Lock door
|
|
- service: script.turn_on
|
|
entity_id: script.doorbell_bell
|
|
|
|
- id: front-door-open-close
|
|
alias: '[Front Door] Open door'
|
|
mode: single
|
|
trigger:
|
|
- type: opened
|
|
platform: device
|
|
device_id: 671a24524db60c56b0a182ac816faf20
|
|
entity_id: binary_sensor.front_door_open_close
|
|
domain: binary_sensor
|
|
action:
|
|
- service: script.hallway_lights_on
|
|
|
|
- id: front-door-invalid-state
|
|
alias: '[Front Door] Notify about wrong state'
|
|
mode: single
|
|
trigger:
|
|
- platform: state
|
|
entity_id: binary_sensor.front_door_open_close
|
|
to: 'on'
|
|
condition:
|
|
- condition: state
|
|
entity_id: lock.front_door_lock_doorlock
|
|
state: locked
|
|
action:
|
|
- service: notify.mobile_app_iphone
|
|
data:
|
|
message: Front door opens but lock is still in status 'locked'
|