#arlo camera security integration

1 messages · Page 1 of 1 (latest)

fresh raft
#
alias: Arlo – Motion Alert + Siren When Away
description: >
  Triggers on Arlo motion, and if no one is home, takes a snapshot from the
  triggering camera, sends a notification, and activates sirens.
triggers:
  - entity_id:
      - binary_sensor.aarlo_motion_camera_1
      - binary_sensor.aarlo_motion_camera_2
      - binary_sensor.aarlo_motion_camera_3
      - binary_sensor.aarlo_motion_camera_4
      - binary_sensor.aarlo_motion_camera_5
      - binary_sensor.aarlo_motion_camera_6
      - binary_sensor.aarlo_motion_floodlight
    to: "on"
    trigger: state
conditions:
  - condition: state
    entity_id: group.family
    state: not_home
actions:
  - data:
      entity_id: "{{ camera }}"
      filename: "{{ filename }}"
    action: aarlo.camera_request_snapshot_to_file
  - delay: "00:00:08"
  - data:
      title: 🚨 Motion detected!
      message: >
        Motion at {{ camera.split('.')[1] | replace('_',' ') }} while no one is
        home.
      data:
        image: "{{ fileurl }}"
    action: notify.mobile_app_gabriels_iphone
  - data:
      volume_level: 1
    target:
      entity_id: siren.aarlo_all_arlo_sirens
    action: siren.turn_on
mode: single
variables:
  cam_map:
    binary_sensor.aarlo_motion_camera_1: camera.aarlo_camera_1
    binary_sensor.aarlo_motion_camera_2: camera.aarlo_camera_2
    binary_sensor.aarlo_motion_camera_3: camera.aarlo_camera_3
    binary_sensor.aarlo_motion_camera_4: camera.aarlo_camera_4
    binary_sensor.aarlo_motion_camera_5: camera.aarlo_camera_5
    binary_sensor.aarlo_motion_camera_6: camera.aarlo_camera_6
    binary_sensor.aarlo_motion_floodlight: camera.aarlo_floodlight
  camera: "{{ cam_map[trigger.entity_id] }}"
  filename: >
    /config/www/snapshots/{{ camera.split('.')[1] }}_{{
    now().strftime('%Y%m%d_%H%M%S') }}.jpg
  fileurl: >
    https://MYURL/local/snapshots/{{
    filename.split('/')[-1] }}
#

so im trying to make a integration that takes care of the security for us. I have tried making a script that checks if there is motion and if there is motion checks if anyone is home and if no one is home then it takes a snapshot from the camera where movement was detected and saves it to home assistant (arlo made it so you have to pay to store captures). I then wanted it to send the picture + some text as a notification to the phones that i have defined

the things is that im having trouble getting it to work
i have made the snapshot feature work and it does save it to the snapshots folder under the /www
can anyone help me fix this?

this is the current yaml code

#

but i keep gettign errors

#
2025-06-26 21:53:03.154 WARNING (MainThread) [homeassistant.helpers.template] Template variable warning: dict object has no element Undefined when rendering '{{ cam_map[trigger.entity_id] }}'
2025-06-26 21:53:03.155 WARNING (MainThread) [homeassistant.helpers.template] Template variable warning: list object has no element 1 when rendering '/config/www/snapshots/{{ camera.split('.')[1] }}_{{ now().strftime('%Y%m%d_%H%M%S') }}.jpg'
2025-06-26 21:53:03.158 ERROR (MainThread) [homeassistant.components.automation.security_arlo] Arlo – Motion Alert + Siren When Away: Error executing script. Invalid data for call_service at pos 1: not a valid value for dictionary value @ data['entity_id']
2025-06-26 21:53:03.158 ERROR (MainThread) [homeassistant.components.automation.security_arlo] Error while executing automation automation.security_arlo: not a valid value for dictionary value @ data['entity_id']
#

can anyone help with this?

#

also if possible i wanted the notification to have a button called false alarm that disables the sirens if pressed

fresh raft
#

never mind i have fixed it

ornate hinge
#

If you would share your solution, that would be helpful for the next person.

fresh raft
#

the solution was actually the code i already had sent the only difference was that i tried triggering it by changing the states but found out that i should just go in front of my camera and it worked it sent the notification with the picture + it saved it locally the only thing i added more was the sirens

ornate hinge
#

Only a tip, as file path for the notification you should be able to just use /local/snapshots/{{ filename.split('/')[-1] }}

And note that files in that folder are public.

fresh raft
#

what do you mean public?

#

and where are you saying i could use that /local/snapshots/{{ filename.split('/')[-1] }}?

#

nvm found the spot

#

still what do you mean public?

ornate hinge
# fresh raft what do you mean public?

There is no authentication needed. So if your HA is accessible from the internet, that folder is accessible for everybody (who knows / guessed the URL). No password etc

fresh raft
#

Where should I place it then?

ornate hinge
#

I'm not actually sure you can place it somewhere it does need login...

fresh raft
#

Hmm so there isn’t another place I can put it

#

Also I’m using tailscale so it would mean that somebody needs access to my tailscale account

#

Which also means that they have the password

#

So I don’t think it’s a problem

#

Because the only way to access my home assistant network is through tailscale

ornate hinge
#

if you only have acces via Tailscale aka VPN aka only local it's not a big deal indeed.