Doorbell - Notify Google and send camera snapshot to app

If you ever find out then let me know! I’ve been using my own automation to do the same as this blueprint for a while now and this has always been one of the more annoying issues.

As far as I’m aware it’s not possible unless you send out a “broadcast”. I can’t see an easy way of doing that without using something like “assistant-relay” to issue the broadcast command but that’s just a pain to setup and is a bit memory/cpu intensive on a Pi4.

Is it possible to use a switch as trigger instead of a binary sensor?

Have you tried typing in the switch entity into the selection line?

Thank you, sometimes it’s simple :grinning:

Hi,
Im getting this error:

While executing automation automation.doorbell_notify_google_and_send_camera_snapshot_to_app
Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/components/automation/__init__.py", line 404, in async_trigger
    await self.action_script.async_run(
  File "/usr/src/homeassistant/homeassistant/helpers/script.py", line 1033, in async_run
    await asyncio.shield(run.async_run())
  File "/usr/src/homeassistant/homeassistant/helpers/script.py", line 246, in async_run
    await self._async_step(log_exceptions=False)
  File "/usr/src/homeassistant/homeassistant/helpers/script.py", line 254, in _async_step
    await getattr(
  File "/usr/src/homeassistant/homeassistant/helpers/script.py", line 464, in _async_call_service_step
    await service_task
  File "/usr/src/homeassistant/homeassistant/core.py", line 1395, in async_call
    raise ServiceNotFound(domain, service) from None
homeassistant.exceptions.ServiceNotFound: Unable to find service tts.google_translate_say```

Logger: homeassistant.components.automation.doorbell_notify_google_and_send_camera_snapshot_to_app
Source: helpers/script.py:1145
Integration: Automation (documentation, issues)
First occurred: 2:50:27 PM (1 occurrences)
Last logged: 2:50:27 PM

Havelågen - Notify Google and send camera snapshot to app: Error executing script. Service not found for call_service at pos 1: Unable to find service tts.google_translate_say

This is in my config file

# Text to speech

tts:
  - platform: google_translate
    service_name: google_say
    language: 'da'

notify:
  - platform: tts
    name: in_the_living_room
    tts_service: tts.google_say
#    language: 'da'
    media_player: media_player.alle_hojtalere   ```

If you remove sevice_name: google_say from your config it will fall back to the default service name of google_translate_say

1 Like

Thank u it works now :slight_smile:

1 Like

Thanks for this. Could you make an adjustment : Cast specific camera-stream to Nest Hub for x-seconds in stead of sending a snapshot ? That would really be nice. Thanks in advance

2 Likes

Thanks for this awesome blueprint! Is there a way to notify multiple IOS devices at once or use a notification group with a single version of this blueprint? I’ve now added it per IOS device from which one with the Google announce option active

1 Like

Have you tried manually typing in the multiple devices as a comma separated list or manually typing in the group?

Tried all combinations I could think of but comma separated list didn’t work for me on multiple IOS devices to notify. I’ll just use 2 automations, 1 for each phone :slight_smile:

1 Like

This was incredible and worked great, thanks!

1 Like

Heya!

I am unable to get the above blueprint to work. Any chance you can share your setup?

Not working for me. Get the following error:

Logger: homeassistant.components.automation.doorbell_notify_gh_devices
Source: helpers/script.py:1147
Integration: Automation ([documentation](https://www.home-assistant.io/integrations/automation), [issues](https://github.com/home-assistant/home-assistant/issues?q=is%3Aissue+is%3Aopen+label%3A%22integration%3A+automation%22))
First occurred: 9:20:34 PM (3 occurrences)
Last logged: 9:25:11 PM

Doorbell - Notify GH devices: Error executing script. Invalid data for call_service at pos 1: not a valid value for dictionary value @ data['entity_id']

That sounds great. It would be really interesting to see a blueprint for that.

Finally got it to work, manually entered automation:

- id: '1613070806688'
  alias: Notify test 11 feb
  description: ''
  trigger:
  - type: turned_on
    platform: device
    device_id: 4246c6651674863d84c58895d05bf457
    entity_id: binary_sensor.front_door_ding
    domain: binary_sensor
  condition: []
  action:
  - service: tts.google_translate_say
    entity_id: media_player.office_display,media_player.master_bedroom_display,media_player.office
    data:
      message: Someone is at the door
  mode: single

Here is my YAML. This workes great, BUT there’s one big issue! The very big delay when i press the aqara switch and the stream played on the Google Nest Hub, there’s about 3-5 seconds delay.

Someone has a good solution? Like change the yamlcode or upgrade my home assistant config?

Right now it runs on a RaspberryPi 3 with a Blitzwolf 64GB Class 10, UHS-3 V30 microsd. Does it help to upgrade to a RPI4 maybe with a SSD instead of a MicroSD? Please shout out in the comments :slight_smile:

What happens when i press the aqara switch (doorbel switch):

  • sets volume on all google devices (because during the day it will change)
  • the doorbelsound mp3 plays on 2 google mini’s in my house
  • a stream for 45 seconds from the camera shows on the Google Nest Hub (after 3-5 sec. delay)
  • a snapshot from the camera is send to telegram on my iPhone
  • sets volume back to ‘normal volume’ on all google devices
  • ends stream on google nest hub
alias: 'Press doorbel to camera/telegram'
trigger:
  - platform: device
    domain: mqtt
    device_id: 11d8851f3d92ad3a8ed03509xxxx
    type: action
    subtype: single
    discovery_id: 0x00158d000xxxxx action_single 
condition: []
action:
  - service: media_player.volume_set
    data:
      volume_level: 0.5
    entity_id: media_player.googlemini2
  - service: media_player.volume_set
    data:
      volume_level: 0.8
    entity_id: media_player.googlemini
  - service: media_player.play_media
    data:
      media_content_id: 'http://192.168.xx.xxx:8123/local/doorbell.mp3'
      media_content_type: audio/mp3
    entity_id:
      - media_player.googlemini2
      - media_player.googlemini
  - data:
      data:
        entity_id: camera.maindoor
        photo:
          content-type: jpeg
          hide-thumbnail: false
          url: >-
            http://192.168.xx.xxx/url.from.stream.reolink.camera/
        push:
          category: camera
      message: test
    service: notify.ha_message
  - service: camera.play_stream
    data:
      media_player: media_player.ghnest
    entity_id: camera.maindoor
  - delay: '00:00:45'
  - service: media_player.volume_set
    data:
      volume_level: 0.3
    entity_id: media_player.googlemini2
  - service: media_player.volume_set
    data:
      volume_level: 0.3
    entity_id: media_player.ghnest
  - service: media_player.turn_off
    data: {}
    entity_id: media_player.ghnest
mode: single

1 Like

Really cool recipe. Thanks for sharing!

Does checking the Preload Stream box help speed? That will mean that the stream is decoding in the background making it faster to load rather than dealing with startup overhead at event time. But it will mean HA is always streaming from the cam.