This blueprint is one that I made to slightly simplify the process of sending notifications to Alexa devices while using Alexa Media Player, in a way inspired by Grumblezz’s Notify Mobile Companion Devices script. While the notify service provided by AMP isn’t super complex, I wasn’t aware of some of its functionality (namely the Announce notification type) and wanted a GUI-driven way to quickly set those parameters.
Getting started
First, you need to install Alexa Media Player and make sure it’s working.
Once you’ve done that, click the below button to add the blueprint to your install, then create a script from it. Make sure to give it a memorable name!
tts - Alexa will speak using Alexa’s Simon Says skill and will not sync between devices. This does not work with an Alexa Whole House Audio group (WHA). This does allow messages to phone apps which the Announce function does not.
announce - This functionality will result in a beep prior to speaking. It can also allow display on Echo Shows/Spots. Whole House Audio groups are supported. It does not appear to sync across devices.
push - This will send a mobile push notification to any Alexa apps linked to the target Alexa device.
title (optional) - The title to display. Only works with announce and push notifications.
devices (optional) - The device(s) to direct the notifications to. These take device IDs, and translates them to entity IDs. If this is not supplied, all Alexa devices will be notified.
Despite what the UI says, there is no response variable support.
Hopefully some of you find this useful! It’s my first blueprint, but I think it has value.
UPDATES
2024.03.7
Fixed a small issue where it would try to include a title when none is supplied, leading to spurious log file messages. Thanks @masterpete!
2024.03.29
Added a description for when you’re first creating a script using this blueprint. Thanks @Tockra and nothra on Github!
Just did some testing and it seems like that message gets logged when you don’t have a title set. That’s definitely a bug, not sure why that’s happening…
Just fixed the issue and pushed an update to it! As I don’t think blueprints have any sort of automatic update capability, you’ll need to go to Settings → Automations & Scenes → Blueprints and re-import the blueprint like so:
I don’t think restarting HA from here is a necessary step, but it couldn’t hurt.
After I successfully did my alexa media player integration I installed your blueprint and wanted to test it.
The blueprint for Alexa notify has no input:
There are no configurable inputs during that initial setup; all of the configuration comes when you’re actually using the created script in automations. Once created, the options described in the OP should all show up as expected.
Apologies for not making that clearer; I’d meant to add some text to that screen to explain it but forgot. Whoops…
As an update, I just updated the script with a little introduction! It should be a bit clearer that you need to make the script first before you have access to the configuration options. Thanks again for the suggestion!
Just found your blueprint and testing it right now, am i right when i say the it send a mobile push but (even if the alexa app is open) it does not read the message?
Is this blueprint still the way to go If I want notifications through my alexa speakers?
At least this is one prominent search result of my google search.
I’d say yes, though I am a bit biased on this front Ultimately this is just a wrapper around Alexa Media Player so strictly speaking this isn’t needed, but it’s nice to have.
The major uncertainty with this as of late, I’d say, is the weird spot that Alexa Media Player itself is in. AMP apparently isn’t actively maintained anymore outside of community contributed patches, which was demonstrated by the v4.12.13 memory leak and how long it took for an update to drop that fixed it once the cause was isolated. There was a discussion about bringing AMP out of HACS into HA Core on the HA Discord, but I don’t know if or when that’s going to happen.
However when using your script to select them I never receive any of the notifications. The syntax or the action doesn’t seems to execute properly.
ie: this is the config of the automation when I create each notification manually:
alias: Notification
description: ""
triggers:
- trigger: state
entity_id:
- binary_sensor.dome_leak_sensor_water_leak_detected
conditions: []
actions:
- action: notify.mobile_app_patricks_iphone
metadata: {}
data:
message: "A water leak has been detected in the bathroom downstairs. "
title: Warning!
- action: notify.alexa_media_home_echo_bathroom
metadata: {}
data:
message: "A water leak has been detected in the bathroom downstairs. "
title: Warning!
- action: notify.alexa_media_home_echo_kitchen_hub
metadata: {}
data:
message: "A water leak has been detected in the bathroom downstairs. "
title: Warning!
- action: notify.alexa_media_home_echo_living_room_bar
metadata: {}
data:
message: "A water leak has been detected in the bathroom downstairs. "
title: Warning!
- action: notify.alexa_media_home_echo_entrance
metadata: {}
data:
message: "A water leak has been detected in the bathroom downstairs. "
title: Warning!
- action: notify.alexa_media_garage_echo_office
metadata: {}
data:
message: "A water leak has been detected in the bathroom downstairs. "
title: Warning!
- action: notify.alexa_media_garage_echo_arcade
metadata: {}
data:
message: "A water leak has been detected in the bathroom downstairs. "
title: Warning!
- action: notify.alexa_media_home_echo_guest_room_downstairs
metadata: {}
data:
message: "A water leak has been detected in the bathroom downstairs. "
title: Warning!
- action: notify.alexa_media_home_echo_guest_room_upstairs
metadata: {}
data:
message: "A water leak has been detected in the bathroom downstairs. "
title: Warning!
- action: notify.alexa_media_home_echo_master_bathroom
metadata: {}
data:
title: Warning!
message: "A water leak has been detected in the bathroom downstairs. "
- action: notify.alexa_media_home_echo_laundry_room
metadata: {}
data:
message: "A water leak has been detected in the bathroom downstairs. "
title: Warning!
- action: notify.alexa_media_home_echo_master_bedroom
metadata: {}
data:
message: "A water leak has been detected in the bathroom downstairs. "
title: Warning!
type: push
mode: single