Ok, thank you and for the tips.
FAQ: How do I include the sensor name that triggered the automation in the message?
If you have many sensors (e.g., all your window sensors), you can configure the notification to indicate which sensor triggered the automation. This helps you identify what happened more easily.
1. For getting your entity ID in the message use this
{{ trigger.entity_id }}
Or in a custom action
service: notify.mobile_app_your_device_here
data:
title: Window Open
message: "{{ trigger.entity_id }}"
2. For getting the friendly name of your entity in the message use this
{{ states[trigger.entity_id].attributes.friendly_name }}
Or in a custom action
service: notify.mobile_app_your_device_here
data:
title: Window Open
message: "{{ states[trigger.entity_id].attributes.friendly_name }}"
Enjoy
Blacky
Back to FAQ: Click Here
No problem, your welcome.
Blacky
Just to follow up, and in case anyone else runs into the issues, still looking lol, Iām leaning towards some Samsung setting or restriction. Iāve scoured the settings.
Last change was AOD on. In searching Iāve seen similar issues with Samsung, mostly unresolved where some notifications donāt come thru until unlocked or awakened. All those unrestricted etc settings are there, run in background for HA, etc. etc.
If the phones open, theyāre instant.
I use biometrics, fingerprints.
I looked at HA itself, donāt fully understand all yet, still reading about priorities and channels etc. in the companion app. Or an HA bug perhaps. Iām using HA Beta.
Your blueprint is working fine. I havenāt added actions or refined further until I figure out this HA, Samsung issue.
Iām leaning Samsung S23 Ultra and/or Android.
Why only one notification āthat Iām awareā of does this is beyond me so far. Iāll keep searching.
Further, Iām reading this with interest, flagged as the solution in a post in HA forum. How I implement, I have to figure out.
The article I linked appears to have the fix for Androids not getting notifications on lock screen. Added at bottom of Blueprint Yaml appears to fix, so far. I am not a programmer. Lol
data:
ttl: 0
priority: high
Edit; or maybe not.
Hi Dave
Thanks for reaching out. I understand the code, but all of this is already under development. I am currently waiting for Home Assistant (HA) as there might be a bug, not in what youāre doing, but elsewhere in the notifications. I have reported it to HA, and I am confident they will resolve it in due time. Once this is fixed, we can resume testing, and when it all checks out, we will release an update. This applies to all my notification blueprints.
Edit: Development has started again and will be an option to just select.
Blacky
FAQ - A Guide to Notification Options on iOS and Android Devices
iOS ONLY OPTIONS
What are Notification Interruption Levels on iOS?
On devices running iOS 15 and later, you can configure the interruption level for your notifications to ensure they are delivered according to your preferences. This feature allows you to choose how notifications are presented and how they interrupt your activities.
Interruption level | Breaks through Focus | Overrides Ring/Silent switch on iPhone and iPad |
---|---|---|
Default | No | No |
Critical Notification | Yes | Yes |
Time Sensitive Notification | Yes - Must be enabled in focus | No |
Quiet notifications without waking screen | No | No |
ANDROID ONLY OPTIONS
What are High Priority Notifications?
Notifications will appear immediately in most cases. However, in some cases (such as when the phone is stationary or when the screen has been turned off for a prolonged period of time), default notifications will not ring the phone until the screen is turned on. High priority notifications are designed to alert you to important events or updates that require your immediate attention, ensuring they are received promptly even in these situations.
What are Sticky Notifications?
Sticky notifications are a type of notification that remain on your deviceās notification shade until they are manually dismissed by the user. Unlike regular notifications, which can disappear when they are tapped, sticky notifications ensure that important messages are persistently visible until you actively clear or swipe them away, ensuring that critical information stays visible until addressed.
Notification Channels
What are Notification Channels?
Notification channels are a feature for Android devices only. They allow you to categorize notifications, making it easier to manage and prioritize them. Each channel can have its own settings, such as notification style, sound, vibration, blink light, app icon badges, locked screen, and do not disturb, ensuring that you receive notifications in the manner most appropriate for each type of notification you receive.
How Do I Create a Notification Channel?
Before creating channels, it is best to consider what channels you would like to have for your notifications. This will help you structure it correctly, as once you create a channel, it can be removed but will never be deleted unless you reset your app. Taking the time to consider how you would like it structured will help you in the long run.
Some ideas for a channel structure are as follows:
You could just set the notification type. Emergency, General Notification, Dinner Ready, Time for Bed, Appliance Finished, etc.
Or maybe something like this.
- Critical
- Sound and pop-up.
- Vibrate.
- Blink light.
- Locked screen.
- Ignore Do Not Disturb.
- Description : Notifications for emergency situations (e.g., fire alarm, flood alert, smoke detector, carbon monoxide detector, security breaches).
- High
- Sound and pop-up.
- Vibrate.
- Locked screen.
- Ignore Do Not Disturb.
- Description : Notifications for reminders (e.g., upcoming appointment, power outage, rubbish reminder).
- General (Default)
- Sound.
- Vibrate.
- Description : Notifications for general updates (e.g., appliance finished, battery low).
- Low
- Silent.
- Vibrate.
- Description : Notifications for less critical updates (e.g., appliance started, unavailable sensor, battery low).
- Minimal
- Silent and minimized.
- Description : Notifications for non-urgent updates (e.g., reminder, Home Assistant update avalible).
To create a new channel, simply enter a name in the input. When your automation sends the first notification, it will create the channel on your device. After the channel is created, you can customize its notification settings to your preference directly on your device.
How Do I Edit a Notification Channel?
There are a few ways to do this:
- On your device, go into Settings > Notifications > Home Assistant and you will see categories. These are your channels. Select the one you would like to customize and make your adjustments.
- When a notification is received, slowly slide it to the left and you will see a settings icon. Click on it, and it will take you to categories. These are your channels. Select the one you would like to customize and make your adjustments.
How Do I Delete a Notification Channel?
I have a blueprint that will help you remove a notification channel. See link below.
Android Notification Channel Manager
Hope this helps to explain some of the settings
Enjoy
Blacky
Back to FAQ: Click Here
This is a big update hope you like it.
Previously, if you selected an Android device, Sticky Notification was automatically included by default, with no option to disable it. Now, you have the flexibility to enable or disable this feature. If you wish to maintain the previous behavior, please ensure that the Sticky Notification option is enabled in both the start and end notify settings.
New Feature - Collapsible Sections
-
Collapsible Sections - Added collapsible sections to the blueprint. This enhancement improves the blueprint user interface by making it cleaner and more organized, allowing sections to be collapsed.
This feature was introduced in Home Assistant 2024.6, so you must have this version or later for the blueprint to work.
New Feature - Confirmation Message
- Confirmation Message - You can now have a different confirmation messages depending on your actions.
New Feature For iOS
- Interruption Level - On devices running iOS 15 and later, you can now configure the interruption level for your notifications to ensure they are delivered according to your preferences. Choose the desired interruption level from the dropdown list. Critical and time-sensitive notifications must be turned ON within the Home Assistant App, and time-sensitive notifications must be allowed in your Focus settings.
New Feature For Android
-
High Priority notifications ensure that you receive important alerts immediately. These notifications bypass normal delivery delays and are delivered instantly to your device.
-
Sticky Notification ensure that important alerts are not dismissed when selected. They remain on your notification screen until you actively clear or swipe them away, ensuring that critical information stays visible until addressed.
-
Notification Channel allow you to easily organize different notification settings, including notification sounds, vibrations, and other device-specific features. Before crating a channel make sure you understand them and how they work. I have a FAQ that has information on channels, click here.
Maintenance
- Set blueprint to my new layout.
- Update input descriptions.
- Clean up of some code
Performance Upgrade
- Some performance enhancements.
If you like this blueprint? Consider hitting the button in the top post
If you like my blueprints, and would like to show your support or just say thank you? Click Here
Enjoy
Blacky
Blacky, Thanks for all the hard work on your blueprints. I am working with a couple of the notification blueprints and they both are having the same issue. If I use a standard notification it works fine. I receive it right away on my phone. however, once I enable Action button. I stop getting notified. nothing comes to the phone. Looking at a trace it looks to hang at waiting for a response but without the notification I canāt respond. I have checked and enabled all notification settings on the app on the phone. but I canāt seem to find the issue. Using a pixel 7. any help would be much appreciated.
Thanks.
Hi Tom, welcome to the community.
I just tested it here on a iPhone and Galaxy S8 and it is all working fine. Make sure you understand channels if you are using them.
Could you please provide us your YAML of the automation? This YAML code are the settings you have selected in the automation so I can help. To do this go into your automation, top right 3 dots, Edit in YAML, copy all the code, come back to the forum and in your reply at the top tool bar click on ā</>ā and paste code in there.
Blacky
Thanks for your help on this. This is a test automation I created to troubleshoot. Nothing fancy. I feel like itās something simple. maybe even on the phone itself. I did test with āHigh Priorityā āStickyā and āNotification Channelā same result. they all work fine until I enable the Start action button. Thanks again for your help on this.
To add: I created a quick automation manually but this time I used the Call Service Notification: this does work and presents the button in the notification just fine. Not sure what is different between the two methods.
`alias: Test-Notify
description: ""
use_blueprint:
path: Blackshome/state-notifications-and-actions.yaml
input:
entity_a_trigger:
- switch.living_room
entity_a_state: "off"
include_start_notify: enable_start_notify_options
start_notify_device:
- 0cb6a2d576dfe8bbf2d25d7bcc4cdb2b
start_title: Not sure
start_message: Will this work
start_notify_data:
- high_priority
include_start_action_buttons:
- enable_start_action_button_1
start_action_button_1: Work Please
include_start_auto_actions: []
start_action_1:
- service: switch.turn_off
metadata: {}
data: {}
target:
device_id: e32dcfd1b314bcc632dbb603dfb35d85
start_time_delay:
hours: 0
minutes: 1
seconds: 0
include_start_action_button_confirmation: disable_start_action_button_confirmation
start_notify_interruption_level: active`
Hi Tom,
I can see the problem now. It is not really a bug, but I will need to address it. With Android if you donāt put a name in the cancel button it will not work . With iOS it will work . So others donāt have this problem into the future I will have to add a default in. Below is your YAML. Copy and paste it in as I also saw there were quotes that shouldnāt be there, I think it was when you pasted it into this forum
Thanks for reaching out and letting us know as this will help other in the future
Your YAML below, copy it and replace your YAML.
alias: Test-Notify
description: ""
use_blueprint:
path: Blackshome/state-notifications-and-actions.yaml
input:
entity_a_trigger:
- switch.living_room
entity_a_state: "off"
include_start_notify: enable_start_notify_options
start_notify_device:
- 0cb6a2d576dfe8bbf2d25d7bcc4cdb2b
start_title: Yep Working!
start_message: Your Welcome, Blacky :)
start_notify_data:
- high_priority
include_start_action_buttons:
- enable_start_action_button_1
start_action_button_1: Work Please
include_start_auto_actions: []
start_action_1:
- service: switch.turn_off
metadata: {}
data: {}
target:
device_id: e32dcfd1b314bcc632dbb603dfb35d85
start_time_delay:
hours: 0
minutes: 1
seconds: 0
include_start_action_button_confirmation: disable_start_action_button_confirmation
start_notify_interruption_level: active
start_action_button_stop: Cancel?
Let us know how you go.
Blacky
Blacky,
That worked perfect. such a simple thing. Thanks so much. I do appreciate all your help with this.
T
Tom,
No problem your welcome, it is updated with a warning now. Push the update and you will receive it.
Blacky
Maintenance
- Updated descriptions warnings on action buttons that may prevent the automation from functioning correctly and could result in not receiving the notification.
If you like this blueprint? Consider hitting the button in the top post
If you like my blueprints, and would like to show your support or just say thank you? Click Here
Enjoy
Blacky
is there a way to show the action button direct, without expand the notification manuelly?
I am assuming this is for iOS devices. To my knowledge no I wish there wasā¦ and I also wish there was an option to keep it there when you tap on it and it just doesnāt disappear. Android allows this but iOS doesnāt.
Blacky
Im using Android
But no problem, its only nice to have, blueprint works great thanks for that.