šŸ“ø Send camera snapshot notification on motion

Here is my automation to record camera instead of snapshot: This automation will send 30 seconds video (mp4) thru gmail. Iā€™m only sending 30 sec video only to minimize the size of the file. You can adjust the camera resolution also to make file size smaller. Also I set the Yolink motion sensor to trigger motion every 15 minutes and I have 45 sec delay before sending the file.

  1. Iā€™m using different trigger like Yolink outside motion sensor, Garage door alarm switch, Eufy Video Door.
  2. Iā€™m using various Amcrest camera.
  3. I setup SMTP integration with Google.
  4. Optional, Iā€™m using Alarmo integration from HACS for ā€œconditionā€ in case if Iā€™m working in the yard not to trigger the automation.

id: ā€˜1658460748134ā€™
alias: ā€˜Notify: Driveway Camera Recordā€™
description: Camera Notification thru Gmail
trigger:

  • platform: state
    entity_id:
    • binary_sensor.driveway_motion_sensor_motion
      to: ā€˜onā€™
      condition:
  • condition: device
    device_id: a6a81ded68d8f61855eba5f210e47dc1
    domain: alarm_control_panel
    entity_id: alarm_control_panel.outside_motion
    type: is_armed_away
    action:
  • service: camera.record
    data:
    filename: /config/www/tmp/record/driveway.mp4
    duration: 30
    target:
    device_id: 0ee57ec95412bc287f53167def4fc936
  • delay:
    hours: 0
    minutes: 0
    seconds: 45
    milliseconds: 0
  • service: notify.google_mail
    data:
    message: ā€˜Camera: Driveway Camera Motion Recordā€™
    data:
    images:
    - /config/www/tmp/record/driveway.mp4
    title: ā€˜Camera: Driveway Camera Motion Recordā€™
    mode: single
3 Likes