Hi! Remember this video? Some people had some questions about how you can show a snapshot of your camera on your phone when the doorbell rings when you are away from your home. Yeah, it’s true, I only showed a way how you can show the video on your phone when you are at home in that tutorial. So, I had to fix this and I will show you how you can get a snapshot of your camera on your phone remotely in this video.
โญโญโญ NOTE: โญโญโญ
This article accompanies a YouTube video. I wrote it for people who would rather read than watch a video. To keep doing this, I want to ask you to check out the video, leave a comment under the video, give the video a thumbs up, and subscribe to my YouTube channel. This means that the video is offered more often to new visitors so that they also stay informed of the latest Home Assistant tutorials.
Thank you for your support!
Ed
Introduction
So, I explained in my Reolink Video Doorbell video how you can show the camera on your phone when someone rings the doorbell. But, what I explained in that video is that the snapshot was only visible while you were connected to WiFi. So it did not work when you are away from home. To make sure that it can be shown while you are not at home, you need to take another approach. This approach will work for all types of cameras. You need to be able to connect to your Home Assistant server remotely of course. There are various ways to do this, but the easiest way is to make use of Nabu Casa and you support the development of Home Assistant with it. Basically, the snapshot of the video should be available remotely so that you can watch it from a remote location. There is one folder in Home Assistant that can be accessed from the outside and that is the www folder within the config folder on your Home Assistant server. So, we need to make sure that a snapshot of the camera will be stored in that folder as soon as someone rings the doorbell.
Now there is one thing that you need to know here. The www folder on your home assistant server can be accessed by replacing /www with /local. So, let’s say that your image is called snapshot-doorbell.jpg and that it is stored on your server in the location /config/www/tmp. Then, you can access this image through the following url: https://your.homeassistentserver.com/local/tmp/snapshot-doorbell.jpg.
Create the automation to show the camera snapshot on your phone.
Now that this is clear, let’s set up the automation to show the snapshot on your phone as soon as someone rings the doorbell.
Store the snapshot on your server
- For that, go to settings > automations and scenes.
- Click on Create automation.
- Select Create New Automation.
- Click on Add Trigger.
- Now select your doorbell. In my case, it’s the Reolink Video Doorbell.
- Select the trigger that detects when someone pushes the doorbell button.
- Now go to Actions.
- Click Add Action.
- Click Call Service.
- Select the service Camera: Take Snapshot.
- Click Choose Entity.
- Select your doorbell camera or the camera that is close to your doorbell.
- Enter the following in the Filename field: /config/www/tmp/snapshot-doorbell.jpg
Show the snapshot on your phone
- Click on Add Action.
- Select Call Service.
- Select the service that sends a notification to your phone.
- Enter a meaningful message in the message field. Something like “There is someone at the front door” will do.
- Enter a title like “Doorbell rings”.
- Now we are going to add some YAML to the data field.
- First, we are defining the image location of the snapshot that we’ve just taken. Make sure you use the url that can be accessed remotely for this.
- Then, we define the entity_id of our camera so that we can view the camera live stream if we open the notification on our phone.
- And we are also defining an action here to jump to a camera page on our dashboard.
- The action is URI.
- The title of the action is Open Cameras. This means that a link will be added to our notification with the title Open Cameras.
- And, if we click on that link, we will open this URL to our dashboard.
- Click on Save and give your automation a meaningful name.
- Click Save.
You can type the code from the screen, but you can also download the code that I used in this video via the download link in the description below. It will save you time and frustration and you sponsor me so that I can keep creating these tutorials for you.
Test if the camera snapshot is shown when someone is at the door.
Now our Automation is ready. Let’s push the doorbell button to see if we get a message on our phone. As you can see, a message is shown with a tiny snapshot on my phone. My phone is an iPhone and this might look a bit different on Android, but when I long press on the notification I will get to see the live stream of my camera. There is some delay and I don’t know exactly why it is there, but it will start streaming after a couple of seconds. You also see the Open Cameras link below the image. If I click it, the dashboard page that I entered in the automation will open.
In next week’s video, I will show you how you can open a video stream automatically on your tablet as soon as someone rings the doorbell. Make sure to subscribe so that you do not miss it.
Conclusion
So, you will get a camera snapshot on your phone now, even when you are not at home. Please let me know in the comments if this tutorial helped. If you like my tutorials, please consider sponsoring me just like these awesome people do. Because of these people, I can keep making these videos. I am completely dependent on sponsorship to pay for my daily expenses. See the links to Patreon, Ko-Fi, and YouTube Memberships in the description below to sponsor me too. And don’t forget to give this video a thumbs up and subscribe to my channel so that you won’t miss any of my tutorials! I will see you soon in my next video!
Bye Bye.