I’m trying to generate two different notificaion sounds, for different events, at the Home Assistant Companion App on my Android. For this I’m trying to use channels.
automations.yaml
- alias: Button Test
trigger:- platform: state
entity_id: input_button.test_button
action: - action: notify.mobile_app_darren_mobile
data:
message: Button pressed!
title: Button Notification
id: 2efb7233a3774d02a85359d97ae3ec7d
- platform: state
- alias: Garage Door Open
trigger:- platform: state
entity_id: binary_sensor.garage_door_opening
action: - action: notify.mobile_app_darren_mobile
data:
message: The Garage Door is open!
title: Garage Door
id: 8b8fa400180b41f2a4755f6b4366f36b
- platform: state
- alias: Garage Door Open Alarm
trigger:- platform: state
entity_id: binary_sensor.garage_door_opening
action: - action: notify.mobile_app_darren_mobile
data:
message: Close the Garage Door. It’s still open!
title: “This is Alarming”
channel: alarm
importance: high
id: 87ac8c0ed25d47738c3840d665e9448e
- platform: state
The Button Test was proof of concept: Can I get a notificaiton to the phone from a button on the dashboard? This works.
I also have the garage door trigging the default “General” channel via the “Garage Door Open” automation.
However the “Garage Door Open Alarm” automation is not working.
So as not to wear out the physical door (or wake the neighbours - because I’ve been pulling my hair out over this into the wee hours), I’ve been trigging using System → Automations & Scenes → [Automations Tab] … |> Run
This generates the System → Logs error:
Logger: homeassistant.components.automation.garage_door_open_1
Source: components/automation/__init__.py:776
integration: Automation (documentation, issues)
First occurred: 11:13:33 AM (1 occurrences)
Last logged: 11:13:33 AM
Error while executing automation automation.garage_door_open_1: extra keys not allowed @ data['channel']
Commenting out the channel results in an error on the importance tag:
extra keys not allowed @ data['importance']
Commenting out this, in addition to the channel line, works insofar as a notification is sent to the phone. However the automation has degenerated to being equivalent to “Garage Door Open” and I can’t indicate an alternative alert sound, which was the whole point!
Guidance would be appreciated
Thanks in advance.