📸 Send camera snapshot notification on motion

SOLVED: in the setting up of the automation you have to set a value for Delay even though it says optional. as soon as I set it to 1 it works.

Getting the same. Any luck figuring that out?

Is it possible to add an action to point the notification to a specific view on the mobile application using :

actions:
  - action: "URI"
    title: "Open Cameras"
    uri: "/lovelace/cameras"

I managed to add that action manually into the blueprint, and it worked fine:

{"attachment":{"url":"%s","content_type":"JPEG","actions":[{"action":"URI","title":"Open Cameras","uri":"/lovelace/snap"}]}}

I think it will be very useful if joined with what @Viss did in his post https://community.home-assistant.io/t/send-camera-snapshot-notification-on-motion/254565/231?u=hatemzidi

1 Like

this is handy! I’ll try and implement it! I would really love to find a way to touch the android notification for these and have it show me the whole, full resolution image, versus take me to a view where i still just see a thumbnail. No idea how to do that.

My current related issue is that the axis integration is outdated and has stopped functioning for certain M models of axis camera. They changed the API and didnt tell anybody (i have learned this by watching my camera motion sensor notifications just outright fail). I have an axis m3206-lve camera with a zooz motion sensor right next to it, and when the motion sensor detects motion, I use this technique to grab a snapshot from the camera, and lob it to several android phones. But one day the m3206-lve ‘just stopped producing images’.

the issue is that at some point last year they pushed new firmware that changed what happens under the hood for amberealla SoC based cameras, claiming the cpu doesnt have enough oomph, and not permitting the camera to take a jpg snapshot from the same stream as a video is currently being taken - however if you specify “half the sensors resolution” (1280x960) it will still produce a picture. I have been trying to work with the developer of the axis plugin (Axis Camera Integration needs a refresh · Issue #89967 · home-assistant/core · GitHub) in an attempt to get him to reconfigure the code allowing users to specify a resolution for the snapshotting of images, and I have also spent a full year talking to axis and begging them to change the api for the M series cameras so that if users request an image, and the camera cant fulfil it, to produce a half-resolution image, so that we get SOMETHING BACK instead of an error.

Neither of these pursuits have yet bore fruit, but I am open to hacking the axis integration myself to include a default resolution for snapshots so that this works again. Happy to take any help I can get here!

Hi,

Great work with this blueprint!!! Its amaizng tool :slight_smile:
-Is it possible to add more devices to send a same notification in one automation?
-Could you upgrade your blueprint to add several motion sensors and connect them with camera?

In that case I want to send a notification to 3 devices. I have 8 camera’s and 14 motion detection. I had to created 24 automations with your blueprint and I only solved 8 motion detection…
It would be great to have one blueprint for many devices, many motion detections and many cameras.

Something like:
-Choose how many cameras do you have?
-Put a list of sensors for each camera
-Put a list of devices for notification for each camera
-Put title and text for notification for each camera
-Put a conditional (if alarm set or time is between sunrise/sunset) for each camera

Thank you in advance for respond.

Hello,
Thank you very much for your blueprint. I have also installed it in my Home Assistant. Unfortunately, it does not work as desired. I have integrated my cameras via onvif. Normally i use synology surveillance station. There it detect motion.
I have tested “InputCellMotion Detection” and “InputMotionAlarm” as motion sensors. Unfortunately, I do not receive a notification when motion is detected. If I run through the automation as a test, it works. Here is my automation. I use my outdoor cameras from Anke (Hikvision). Does anyone have an idea what the problem is and can they help me?


Same problem here.

Nope. Not using Telegram at all.

There is a media folder in HA, shouldnt it be possible to save it there?

Yes, they are saved in /media, but every time the event is triggered the image is replaced (there is a way to save them with time and date, so as not to rewrite it, but I don’t use this function)

I am using Tplink tapo c200.

I have used this code to send video to telegram, but i have following two issues.

  1. Audio is not recorded.
  2. The video recording starts a litlle late after the motion is detected.

Am i doing sometging wrong?

Kindly guide how to fix this.

Does anyone use this with iOS?

The picture does not show up for me in the notification… only the text. Am I doing anything wrong?

Hi, difficult to say with what you’re sharing.
Did you conduct a search: Search results for 'ios snapshot camera' - Home Assistant Community

I did…
Hmmm, I think I figured it out though. For whatever strange reason, a SECOND device for my iPhone was created … the first one was “iPhone” and the second one was “iPhone (5)”. Crazy.

Both pointed to the same iPhone but had different information (e.g. battery level was different). Sending a message to both worked. But images only worked with the former one.

I deleted both devices and when restarting the app the device was re-created.

Hi all

first off I wanted to thank the author for this awesome blueprint. It worked right away for me. Secondly, I’d like to ask if there’s a way to reduce the number of notifications it sends somehow. I noticed that the camera motion sensor detects persons continuosly (like every 3 seconds or so), so if someone stands just under the camera for a while, it is continuosly monitored, therefore I receive a loooot of notifications (an unmanageable number).
Is there a way to reduce these notifications? I was thinking to use the delay setting, but I don’t want that to impact the time it detects somebody and I receive the notification for the first time… any suggestions?

This blueprint worked like a charm for me on my reolink E1.

Could someone please tell me which exact lines of code are used to retrieve and then save the image, I’d like to use them elsewhere as my usual snapshot method does not seem to work on this camera.

Also, is there any way to save the image to my phone?

I made a version that uses conditions:

will a generic binary sensor work? I made a version that uses any binary sensor:

@DeimicUser
This may be closer to what you wanted:

Thank you! I’ll give it a try asap!

1 Like

Hey, I went through all the replies and didnt find any solution that would work :frowning: The automation used to work perfectly on my HA app on my iPhone and now when im connected to local URL I only get a small preview of the snapshot and when i tap and hold on the notification a large snapshot no longer appears. AND when im connected to an external URL, I only get a text notification without even the small preview of the snapshot. Both used to work with both the preview and a large snapshot appearing after tap and holding on the notification. Also used to work on my apple watch. Is there a fix? Nothing changed in my HA as far as i know. Thanks!!

also - for some reason with this automation (📸 Notification with camera snapshot with blocking condition and clickaction) when on local i can at least do the tap and hold to see the larger snapshot… really strange - with this automation only the external doesnt work (at all, not even the small preview image)

Hey, how do I send the notification to several devices?
I should modify the blueprint? And create a group of devices? What if it’s a mix of ios and android devices?

This blueprint has started to spam my logs:

Template variable warning: 'None' has no attribute 'object_id' when rendering '/config/www/tmp/snapshot_{{ states[camera].object_id }}.jpg'

When run manually (or automatically) it works just fine. Anyone got any ideas?