1
0
ansible-home-assistant/configuration/automations/camera.yaml

46 lines
1.2 KiB
YAML

- id: camera_kitchen_notification
alias: '[Camera] Kitchen notification'
condition:
- condition: state
entity_id: alarm_control_panel.home_alarm
state: armed_away
trigger:
- platform: state
entity_id: binary_sensor.kitchen_motion_sensor
from: 'off'
to: 'on'
action:
- service: notify.mobile_app_iphone
data:
message: Motion Detected in Kitchen!
data:
entity_id: camera.kitchen
url:
_: "/lovelace-tablet/cctv"
mode: single
- id: camera_hallway_notification
alias: '[Camera] Hallway notification'
condition:
- condition: state
entity_id: alarm_control_panel.home_alarm
state: armed_away
trigger:
- platform: state
entity_id: binary_sensor.hallway_motion_sensor
from: 'off'
to: 'on'
- platform: state
entity_id: binary_sensor.hallway_sensor_2_home_security_motion_detection
from: 'off'
to: 'on'
action:
- service: notify.mobile_app_iphone
data:
message: Motion Detected in Hallway!
data:
entity_id: camera.hallway
url:
_: "/lovelace-tablet/cctv"
mode: single