Last active
February 23, 2026 15:18
-
-
Save Blackshome/180ca4a24af81cd5d843acfc039039bc to your computer and use it in GitHub Desktop.
Revisions
-
Blackshome revised this gist
Aug 29, 2025 . 1 changed file with 81 additions and 6 deletions.There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -3,7 +3,7 @@ blueprint: description: > # 📢 Notifications & Announcements **Version: 1.5** State your trigger and spread the word 💬🔉 @@ -34,7 +34,7 @@ blueprint: - Specify precise start and end times along with weekday selections to define when the automation can run. - **Global Conditions:** - Enter any custom conditions to further customize the automation process. @@ -208,6 +208,20 @@ blueprint: default: Enter Notify Message Here 🙂 selector: text: notify_tag: name: Notification Tag description: > Use a tag to keep your notifications organized. When a new notification with the same tag is sent, it replaces the old one, so you won't get cluttered with duplicates. If this input is left blank, no tag will be applied and each notification will be treated as separate. For best results, use short, unique tags for each automation - for example: `dinner-ready`, `time-for-bed`, `front-door-bell`, etc. default: [] selector: text: notify_interruption_level: name: Interruption Level - iOS Only description: > @@ -255,6 +269,10 @@ blueprint: **Notification Channel** allow you to easily organize different notification settings, including notification sounds, vibrations, and other device-specific features. If you choose this option, please enter your desired channel name below. **Icon** allows you to replace the default Home Assistant icon with one of your choice. If selected, choose your preferred icon using the **Icon - Android Only** option below, and set the icon colour using **Icon Colour - Android Only**. default: [] selector: select: @@ -266,6 +284,8 @@ blueprint: value: "sticky" - label: Notification Channel value: "channel" - label: Icon value: "icon" notify_channel: name: Notification Channel - Android Only description: > @@ -279,6 +299,22 @@ blueprint: default: [] selector: text: notify_icon: name: Icon - Android Only description: > Select a custom icon to replace the default Home Assistant icon in the notification. This setting applies only if the **Icon** option is selected in **Android Only Options** above. default: "mdi:emoticon-happy-outline" selector: icon: notify_icon_colour: name: Icon Colour - Android Only description: > Choose a colour for your custom notification icon. This setting applies only if the **Icon** option is selected in **Android Only Options** above. default: [0, 200, 83] selector: color_rgb: include_notify_zone: name: Use The Notify Zone Option (Optional) description: > @@ -333,6 +369,20 @@ blueprint: default: Enter UI Message Here 🙂 selector: text: persistent_id: name: Notification ID description: > Use a **Notification ID** to keep your notifications organized. When a new notification with the same **Notification ID** is sent, it replaces the old one, so you won't get cluttered with duplicates. If this input is left blank, no **Notification ID** will be applied and each notification will be treated as separate. For best results, use short, unique **Notification ID** for each automation - for example: `dinner-ready`, `time-for-bed`, `front-door-bell`, etc. default: [] selector: text: tts_notify_settings: name: "Text-to-Speech Announcement" icon: mdi:bullhorn-outline @@ -496,15 +546,19 @@ variables: notify_device: !input notify_device notify_title: !input notify_title notify_message: !input notify_message notify_tag: !input notify_tag notify_interruption_level: !input notify_interruption_level notify_sound: !input notify_sound notify_data: !input notify_data notify_channel: !input notify_channel notify_icon: !input notify_icon notify_icon_colour: !input notify_icon_colour include_notify_zone: !input include_notify_zone notify_zone: !input notify_zone include_persistent_notification: !input include_persistent_notification persistent_title: !input persistent_title persistent_message: !input persistent_message persistent_id: !input persistent_id include_tts_announcement: !input include_tts_announcement text_to_speech_engine: !input text_to_speech_engine media_player: !input media_player @@ -540,6 +594,29 @@ variables: {% if 'sticky' in notify_data %} {% set message.data = dict(message.data, **{ 'sticky': "true" }) %} {% endif %} {% if 'icon' in notify_data %} {% set message.data = dict(message.data, **{ 'notification_icon': notify_icon }) %} {% if notify_icon_colour | length == 3 %} {% set icon_colour = '#%02x%02x%02x' | format(notify_icon_colour[0], notify_icon_colour[1], notify_icon_colour[2]) %} {% set message.data = dict(message.data, **{ 'color': icon_colour }) %} {% endif %} {% endif %} {% if notify_tag != [] %} {% set message.data = dict(message.data, **{ 'tag': notify_tag }) %} {% endif %} {{ message.data }} ui_message_data: >- {% set message = namespace(data={}) %} {% if persistent_title != [] %} {% set message.data = dict(message.data, **{ 'title': persistent_title }) %} {% endif %} {% if persistent_message != [] %} {% set message.data = dict(message.data, **{ 'message': persistent_message }) %} {% endif %} {% if persistent_id != [] %} {% set message.data = dict(message.data, **{ 'notification_id': persistent_id }) %} {% endif %} {{ message.data }} filtered_devices: > @@ -555,7 +632,6 @@ variables: {{ notify_device }} {% endif %} triggers: - trigger: state id: "t0" @@ -635,16 +711,15 @@ action: title: !input notify_title message: !input notify_message data: "{{ device_message_data }}" continue_on_error: true - choose: - alias: "Use the persistent notification is enabled" conditions: - condition: template value_template: "{{ include_persistent_notification == 'enable_persistent_notification' }}" sequence: - action: persistent_notification.create data: "{{ ui_message_data }}" - choose: - alias: "Check if tts announcement is enabled" conditions: -
Blackshome revised this gist
Jan 11, 2025 . 1 changed file with 1 addition and 0 deletions.There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -28,6 +28,7 @@ blueprint: - Opt to send messages to one or multiple devices. Compatible with Apple iOS and Android devices. - Opt to display your notifications directly within the Home Assistant user interface (UI). - Opt to send Text-to-Speech Announcement to your selected media players. - Opt to use a custom action. - **Time-Based Automation:** -
Blackshome revised this gist
Jan 11, 2025 . 1 changed file with 77 additions and 3 deletions.There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -3,7 +3,7 @@ blueprint: description: > # 📢 Notifications & Announcements **Version: 1.4** State your trigger and spread the word 💬🔉 @@ -278,6 +278,29 @@ blueprint: default: [] selector: text: include_notify_zone: name: Use The Notify Zone Option (Optional) description: > Home Assistant can track the location of your devices, such as mobile phones, within designated zones using the Mobile App's device tracker integration. To utilize this feature, you need to set up zones in Home Assistant, such as Home, Work, or Gym, and ensure your devices are configured for location tracking via the Home Assistant mobile app. When this option is enabled, notifications will only be sent to devices currently located within the selected zone. default: zone_disabled selector: select: options: - label: Enable the zone option value: "zone_enabled" - label: Disable the zone option value: "zone_disabled" notify_zone: name: Notify Zone description: > Choose the notify zone for your notifications. default: [] selector: entity: filter: domain: zone persistent_notify_settings: name: "Notifications" icon: mdi:bell-outline @@ -353,6 +376,32 @@ blueprint: selector: text: multiline: true custom_actions_settings: name: "Custom Actions" icon: mdi:code-tags collapsed: true input: include_custom_actions: name: Use The Custom Action Options (Optional) description: > Customize your automation with any action you desire. It is commonly used for playing announcements on The Voice (HA), Google, Alexa, etc. Additionally, it can be utilized for other notification services or any other actions you would like to perform. default: disable_custom_actions selector: select: options: - label: Enable Custom Actions value: "enable_custom_actions" - label: Disable Custom Actions value: "disable_custom_actions" custom_actions: name: Custom Actions description: > Enter the custom actions you would like to run. default: [] selector: action: time_settings: name: "Time" icon: mdi:clock-outline @@ -450,13 +499,17 @@ variables: notify_sound: !input notify_sound notify_data: !input notify_data notify_channel: !input notify_channel include_notify_zone: !input include_notify_zone notify_zone: !input notify_zone include_persistent_notification: !input include_persistent_notification persistent_title: !input persistent_title persistent_message: !input persistent_message include_tts_announcement: !input include_tts_announcement text_to_speech_engine: !input text_to_speech_engine media_player: !input media_player notify_tts_message: !input notify_tts_message include_custom_actions: !input include_custom_actions custom_actions: !input custom_actions include_time: !input include_time after_time: !input after_time before_time: !input before_time @@ -488,6 +541,20 @@ variables: {% endif %} {{ message.data }} filtered_devices: > {% if include_notify_zone == 'zone_enabled' %} {% set zone_name = notify_zone.split('.')[1] %} {% set device_trackers = notify_device | map('device_entities') | list %} {% set devices_in_zone = expand(device_trackers) | selectattr('state', 'eq', zone_name) | map(attribute='entity_id') | list %} {{ devices_in_zone }} {% else %} {{ notify_device }} {% endif %} triggers: - trigger: state id: "t0" @@ -556,10 +623,11 @@ action: - alias: "Check if notification is enabled" conditions: - "{{ include_notify == 'enable_mobile_app_notify' }}" - "{{ filtered_devices | length > 0 }}" sequence: - alias: Send a notification to each device repeat: for_each: "{{ filtered_devices }}" sequence: - action: "notify.mobile_app_{{ device_attr(repeat.item, 'name') | slugify }}" data: @@ -586,4 +654,10 @@ action: entity_id: !input text_to_speech_engine data: media_player_entity_id: !input media_player message: !input notify_tts_message - choose: - alias: "Perform the custom action" conditions: - condition: template value_template: "{{ 'enable_custom_actions' in include_custom_actions }}" sequence: !input custom_actions -
Blackshome revised this gist
Nov 28, 2024 . 1 changed file with 34 additions and 12 deletions.There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -3,7 +3,7 @@ blueprint: description: > # 📢 Notifications & Announcements **Version: 1.3** State your trigger and spread the word 💬🔉 @@ -229,6 +229,18 @@ blueprint: value: "time-sensitive" - label: Quiet Notifications Without Waking Screen value: "passive" notify_sound: name: Notification Sound - iOS Only description: > The Home Assistant app for iOS includes built-in notification sounds, and you can import sounds from your iOS device into the app. Custom sounds can also be added via iTunes or from your cloud storage. When entering a sound, ensure you use the full filename, including the extension. For more information on using sounds in the Home Assistant app, [Click Here](https://community.home-assistant.io/t/728100/13) default: [] selector: text: notify_data: name: Android Only Options (Optional) description: > @@ -321,15 +333,17 @@ blueprint: default: [] selector: entity: filter: domain: tts media_player: name: Media Player description: > Select the Media Player/s that will play your Text-to-Speech announcement message. default: [] selector: entity: filter: domain: media_player multiple: true notify_tts_message: name: Announcement Message @@ -433,6 +447,7 @@ variables: notify_title: !input notify_title notify_message: !input notify_message notify_interruption_level: !input notify_interruption_level notify_sound: !input notify_sound notify_data: !input notify_data notify_channel: !input notify_channel include_persistent_notification: !input include_persistent_notification @@ -452,8 +467,15 @@ variables: device_message_data: >- {% set message = namespace(data={}) %} {% set push = namespace(data={}) %} {% if notify_interruption_level in ['active', 'critical', 'time-sensitive', 'passive'] %} {% set push.data = dict(push.data, **{ 'interruption-level': notify_interruption_level }) %} {% endif %} {% if notify_sound != [] %} {% set push.data = dict(push.data, **{ 'sound': notify_sound }) %} {% endif %} {% if push.data %} {% set message.data = dict(message.data, **{ 'push': push.data }) %} {% endif %} {% if 'high_priority' in notify_data %} {% set message.data = dict(message.data, **{ 'ttl': 0, 'priority': 'high' }) %} @@ -466,22 +488,22 @@ variables: {% endif %} {{ message.data }} triggers: - trigger: state id: "t0" entity_id: !input trigger_state_entity for: !input time_delay_state - trigger: state id: "t1" entity_id: !input trigger_state_entity to: !input trigger_state for: !input time_delay_state - trigger: numeric_state id: "t2" entity_id: !input trigger_numeric_entity above: !input above_state for: !input time_delay_state - trigger: numeric_state id: "t3" entity_id: !input trigger_numeric_entity below: !input below_state @@ -539,7 +561,7 @@ action: repeat: for_each: !input notify_device sequence: - action: "notify.mobile_app_{{ device_attr(repeat.item, 'name') | slugify }}" data: title: !input notify_title message: !input notify_message @@ -550,7 +572,7 @@ action: - condition: template value_template: "{{ include_persistent_notification == 'enable_persistent_notification' }}" sequence: - action: persistent_notification.create data: title: !input persistent_title message: !input persistent_message @@ -559,7 +581,7 @@ action: conditions: - "{{ include_tts_announcement == 'enable_tts_announcement' }}" sequence: - action: tts.speak target: entity_id: !input text_to_speech_engine data: -
Blackshome revised this gist
Sep 7, 2024 . 1 changed file with 8 additions and 8 deletions.There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -6,7 +6,7 @@ blueprint: **Version: 1.2** State your trigger and spread the word 💬🔉 **If you like my blueprints, and would like to show your support or just say thank you?** [Click Here](https://www.paypal.com/donate/?hosted_button_id=WAZS3QSDTPGA8) 🙂 @@ -172,16 +172,16 @@ blueprint: collapsed: true input: include_notify: name: Use The Mobile App Notify Option (Optional) description: > Enabling this option will send notifications to the selected devices below. default: disable_mobile_app_notify selector: select: options: - label: Enable Mobile App Notify Options value: "enable_mobile_app_notify" - label: Disable Mobile App Notify Options value: "disable_mobile_app_notify" notify_device: name: Devices Notified @@ -279,9 +279,9 @@ blueprint: selector: select: options: - label: Enable UI Notifications value: "enable_persistent_notification" - label: Disable UI Notifications value: "disabled_persistent_notification" persistent_title: name: Title @@ -310,9 +310,9 @@ blueprint: selector: select: options: - label: Enable Text-to-Speech Announcements value: "enable_tts_announcement" - label: Disable Text-to-Speech Announcements value: "disable_tts_announcement" text_to_speech_engine: name: Text-to-Speech Service Provider -
Blackshome revised this gist
Aug 16, 2024 . 1 changed file with 69 additions and 42 deletions.There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -3,7 +3,7 @@ blueprint: description: > # 📢 Notifications & Announcements **Version: 1.2** State your trigger and spread the word 💬 🔉 @@ -55,7 +55,8 @@ blueprint: input: trigger_state: name: Trigger - State * description: > Please select what state you would like for your trigger. You can choose from ten options available in the dropdown menu. If your option is not in the dropdown menu then just type the state you would like to use in and click the save button. @@ -112,21 +113,27 @@ blueprint: value: "numeric_state_above_below" trigger_state_entity: name: State Entities description: > **Used in options 1, 2, 3, 4, 5, 6 or 7**. Enter the entities that will trigger the automation on state change. default: [] selector: entity: multiple: true trigger_numeric_entity: name: Numeric State Entities description: > **Used in options 8, 9 or 10**. Enter the entities that will trigger the automation numeric state change. default: [] selector: entity: multiple: true above_state: name: Numeric State Above Option description: > **Used in options 8, or 10**. Set the above value. The numeric state trigger will be when the value crosses over to above the set value. default: 0 selector: number: @@ -136,7 +143,10 @@ blueprint: unit_of_measurement: value below_state: name: Numeric State Below Option description: > **Used in options 9 or 10**. Set the below value. The numeric state trigger will be when the value crosses over to below the set value. default: 0 selector: number: @@ -146,22 +156,25 @@ blueprint: unit_of_measurement: value time_delay_state: name: Time Delay description: > **Used in options 1, 2, 3, 4, 5, 6, 7, 8, 9 or 10** Specifies the duration that the trigger must maintain its state before the automation is executed. The automation will only proceed if the trigger condition is met continuously for this entire time delay. default: hours: 0 minutes: 0 seconds: 0 selector: duration: device_notify_settings: name: "Mobile App Notify" icon: mdi:devices collapsed: true input: include_notify: name: Use The Mobile App Notify Opion (Optional) description: > Enabling this option will send notifications to the selected devices below. default: disable_mobile_app_notify selector: select: @@ -172,7 +185,8 @@ blueprint: value: "disable_mobile_app_notify" notify_device: name: Devices Notified description: > Select the devices to be notified when the automation is triggered. default: [] selector: device: @@ -181,19 +195,22 @@ blueprint: multiple: true notify_title: name: Title description: > Enter in the title of your notification. default: 📢 Enter Notify Title Here selector: text: notify_message: name: Message description: > Enter in the message of your notification. default: Enter Notify Message Here 🙂 selector: text: notify_interruption_level: name: Interruption Level - iOS Only description: > 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. 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. @@ -214,7 +231,8 @@ blueprint: value: "passive" notify_data: name: Android Only Options (Optional) description: > **High Priority** notifications ensure that you receive important alerts immediately. These notifications bypass normal delivery delays and are delivered instantly to your device. @@ -223,7 +241,7 @@ blueprint: **Notification Channel** allow you to easily organize different notification settings, including notification sounds, vibrations, and other device-specific features. If you choose this option, please enter your desired channel name below. default: [] selector: select: @@ -237,7 +255,8 @@ blueprint: value: "channel" notify_channel: name: Notification Channel - Android Only description: > If you have chosen to use a notification channel, simply enter the name of an existing channel to apply its pre-configured settings. If you don't have a channel yet, you can create a new one by entering a name here. 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. @@ -254,7 +273,8 @@ blueprint: input: include_persistent_notification: name: Use The UI Notification Option (Optional) description: > Enabling this option will display notifications directly within the Home Assistant user interface (UI). default: disabled_persistent_notification selector: select: @@ -265,13 +285,15 @@ blueprint: value: "disabled_persistent_notification" persistent_title: name: Title description: > Enter in the title of your UI notification. default: 📢 Enter UI Title Here selector: text: persistent_message: name: Message description: > Enter in the message of your UI notification. default: Enter UI Message Here 🙂 selector: text: @@ -282,7 +304,8 @@ blueprint: input: include_tts_announcement: name: Use The Text-to-Speech Announcement Option (Optional) description: > Enabling this option will send a Text-to-Speech notification to the selected Media Players below. default: disable_tts_announcement selector: select: @@ -293,22 +316,25 @@ blueprint: value: "disable_tts_announcement" text_to_speech_engine: name: Text-to-Speech Service Provider description: > Select the Text-to-Speech service provider. default: [] selector: entity: domain: tts media_player: name: Media Player description: > Select the Media Player/s that will play your Text-to-Speech announcement message. default: [] selector: entity: domain: media_player multiple: true notify_tts_message: name: Announcement Message description: > Enter in the message of your Text-to-Speech announcement. default: Enter TTS Message Here selector: text: @@ -320,9 +346,10 @@ blueprint: input: include_time: name: Use The Time Options (Optional) description: > Use the "Start Time", **End Time** and the **Weekdays** values to only run the automation between the time periods. This option allows you to disable the automation during sleeping hours to avoid disturbing anyone. Another example is setting the time between 5pm and 9pm for the 'Dinner is Ready' call. This way, if you accidentally activate the trigger outside these hours, the automation will not run. default: time_disabled selector: @@ -334,19 +361,22 @@ blueprint: value: "time_disabled" after_time: name: Start Time description: > Set the start time. default: 00:00:00 selector: time: before_time: name: End Time description: > Set the end time. default: 00:00:00 selector: time: weekday_options: name: Weekdays description: > Select the days of the week you would like the automation to run. You must select "Enable the time options" above for the weekdays selections to work. default: - mon @@ -382,7 +412,8 @@ blueprint: input: global_conditions: name: Global Conditions description: > Enter any global conditions you would like to apply to the automation. default: [] selector: condition: @@ -439,26 +470,22 @@ trigger: - platform: state id: "t0" entity_id: !input trigger_state_entity for: !input time_delay_state - platform: state id: "t1" entity_id: !input trigger_state_entity to: !input trigger_state for: !input time_delay_state - platform: numeric_state id: "t2" entity_id: !input trigger_numeric_entity above: !input above_state for: !input time_delay_state - platform: numeric_state id: "t3" entity_id: !input trigger_numeric_entity below: !input below_state for: !input time_delay_state # All Conditions condition: -
Blackshome revised this gist
Jul 26, 2024 . 1 changed file with 361 additions and 253 deletions.There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -3,7 +3,7 @@ blueprint: description: > # 📢 Notifications & Announcements **Version: 1.1** State your trigger and spread the word 💬 🔉 @@ -48,258 +48,344 @@ blueprint: Required = * domain: automation input: trigger_settings: name: "Triggers *" icon: mdi:cog-outline collapsed: true input: trigger_state: name: Trigger - State * description: Please select what state you would like for your trigger. You can choose from ten options available in the dropdown menu. If your option is not in the dropdown menu then just type the state you would like to use in and click the save button. 1 - Button Or Any State 2 - ON 3 - OFF 4 - Unavailable 5 - Unknown 6 - Home 7 - Not Home 8 - Numeric State - Above 9 - Numeric State - Below 10 - Numeric State - Above & Below A numbering system has been implemented to facilitate navigation within the dropdown selections. Each number corresponds to a specific configuration, aiding users in identifying and adjusting the settings used within each selection. For instance, when selecting "8 - Numeric State - Above" as a dropdown option, settings marked "Used in options 8, 9 or 10" are required for that respective selection because number 8 is included in those options. default: button_any_state selector: select: custom_value: true mode: dropdown options: - label: 1 - Button Or Any State value: "button_any_state" - label: 2 - ON value: "on" - label: 3 - OFF value: "off" - label: 4 - Unavailable value: "unavailable" - label: 5 - Unknown value: "unknown" - label: 6 - Home value: "home" - label: 7 - Not Home value: "not_home" - label: 8 - Numeric State - Above value: "numeric_state_above" - label: 9 - Numeric State - Below value: "numeric_state_below" - label: 10 - Numeric State - Above & Below value: "numeric_state_above_below" trigger_state_entity: name: State Entities description: "**Used in options 1, 2, 3, 4, 5, 6 or 7** - Enter the entities that will trigger the automation on state change." default: [] selector: entity: multiple: true trigger_numeric_entity: name: Numeric State Entities description: "**Used in options 8, 9 or 10** - Enter the entities that will trigger the automation numeric state change." default: [] selector: entity: multiple: true above_state: name: Numeric State Above Option description: "**Used in options 8, or 10** - Set the above value. The numeric state trigger will be when the value crosses over to above the set value." default: 0 selector: number: min: -20 max: 100 step: 1 unit_of_measurement: value below_state: name: Numeric State Below Option description: "**Used in options 9 or 10** - Set the below value. The numeric state trigger will be when the value crosses over to below the set value." default: 0 selector: number: min: -20 max: 100 step: 1 unit_of_measurement: value time_delay_state: name: Time Delay description: "**Used in options 1, 2, 3, 4, 5, 6, 7, 8, 9 or 10** - The state trigger will only fire if the state holds for the set time delay. It is used as a buffer to stop false triggers." default: 0 selector: number: min: 0 max: 10 step: 0.5 unit_of_measurement: minutes device_notify_settings: name: "Mobile App Notify" icon: mdi:devices collapsed: true input: include_notify: name: Use The Mobile App Notify Opion (Optional) description: Enabling this option will send notifications to the selected devices below. default: disable_mobile_app_notify selector: select: options: - label: Enable Mobile App Notify Opion value: "enable_mobile_app_notify" - label: Disable Mobile App Notify Opion value: "disable_mobile_app_notify" notify_device: name: Devices Notified description: Select the devices to be notified when the automation is triggered. default: [] selector: device: filter: - integration: mobile_app multiple: true notify_title: name: Title description: Enter in the title of your notification. default: 📢 Enter Notify Title Here selector: text: notify_message: name: Message description: Enter in the message of your notification. default: Enter Notify Message Here 🙂 selector: text: notify_interruption_level: name: Interruption Level - iOS Only description: 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. 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. For more information on interruption levels [Click Here](https://community.home-assistant.io/t/728100/13) default: active selector: select: mode: dropdown options: - label: Default value: "active" - label: Critical Notifications value: "critical" - label: Time Sensitive Notifications value: "time-sensitive" - label: Quiet Notifications Without Waking Screen value: "passive" notify_data: name: Android Only Options (Optional) description: "**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. If you choose this option, please enter your desired channel name below." default: [] selector: select: multiple: true options: - label: High Priority value: "high_priority" - label: Sticky Notification value: "sticky" - label: Notification Channel value: "channel" notify_channel: name: Notification Channel - Android Only description: If you have chosen to use a notification channel, simply enter the name of an existing channel to apply its pre-configured settings. If you don't have a channel yet, you can create a new one by entering a name here. 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. For more information on notification channels [Click Here](https://community.home-assistant.io/t/728100/13) default: [] selector: text: persistent_notify_settings: name: "Notifications" icon: mdi:bell-outline collapsed: true input: include_persistent_notification: name: Use The UI Notification Option (Optional) description: Enabling this option will display notifications directly within the Home Assistant user interface (UI). default: disabled_persistent_notification selector: select: options: - label: Enable UI Notification value: "enable_persistent_notification" - label: Disable UI Notification value: "disabled_persistent_notification" persistent_title: name: Title description: Enter in the title of your UI notification. default: 📢 Enter UI Title Here selector: text: persistent_message: name: Message description: Enter in the message of your UI notification. default: Enter UI Message Here 🙂 selector: text: tts_notify_settings: name: "Text-to-Speech Announcement" icon: mdi:bullhorn-outline collapsed: true input: include_tts_announcement: name: Use The Text-to-Speech Announcement Option (Optional) description: Enabling this option will send a Text-to-Speech notification to the selected Media Players below. default: disable_tts_announcement selector: select: options: - label: Enable Text-to-Speech Notify Opions value: "enable_tts_announcement" - label: Disable Text-to-Speech Notify Opions value: "disable_tts_announcement" text_to_speech_engine: name: Text-to-Speech Service Provider description: Select the Text-to-Speech service provider. default: [] selector: entity: domain: tts media_player: name: Media Player description: Select the Media Player/s that will play your Text-to-Speech announcement message. default: [] selector: entity: domain: media_player multiple: true notify_tts_message: name: Announcement Message description: Enter in the message of your Text-to-Speech announcement. default: Enter TTS Message Here selector: text: multiline: true time_settings: name: "Time" icon: mdi:clock-outline collapsed: true input: include_time: name: Use The Time Options (Optional) description: Use the "Start Time", "End Time" and the "Weekdays" values to only run the automation between the time periods. This option allows you to disable the automation during sleeping hours to avoid disturbing anyone. Another example is setting the time between 5pm and 9pm for the 'dinner is ready' call. This way, if you accidentally activate the trigger outside these hours, the automation will not run. default: time_disabled selector: select: options: - label: Enable the time options value: "time_enabled" - label: Disable the time options value: "time_disabled" after_time: name: Start Time description: Set the start time. default: 00:00:00 selector: time: before_time: name: End Time description: Set the end time. default: 00:00:00 selector: time: weekday_options: name: Weekdays description: Select the days of the week you would like the automation to run. You must select "Enable the time options" above for the weekdays selections to work. default: - mon - tue - wed - thu - fri - sat - sun selector: select: multiple: true mode: list options: - label: Monday value: "mon" - label: Tuesday value: "tue" - label: Wednesday value: "wed" - label: Thursday value: "thu" - label: Friday value: "fri" - label: Saturday value: "sat" - label: Sunday value: "sun" global_conditions_settings: name: "Global Conditions" icon: mdi:earth collapsed: true input: global_conditions: name: Global Conditions description: Enter any global conditions you would like to apply to the automation. default: [] selector: condition: mode: single max_exceeded: silent @@ -315,6 +401,9 @@ variables: notify_device: !input notify_device notify_title: !input notify_title notify_message: !input notify_message notify_interruption_level: !input notify_interruption_level notify_data: !input notify_data notify_channel: !input notify_channel include_persistent_notification: !input include_persistent_notification persistent_title: !input persistent_title persistent_message: !input persistent_message @@ -328,6 +417,24 @@ variables: weekday_options: !input weekday_options global_conditions: !input global_conditions # Notify device option data device_message_data: >- {% set message = namespace(data={}) %} {% if notify_interruption_level in ['active', 'critical', 'time-sensitive', 'passive'] %} {% set message.data = dict(message.data, **{ 'push': {'interruption-level': notify_interruption_level }}) %} {% endif %} {% if 'high_priority' in notify_data %} {% set message.data = dict(message.data, **{ 'ttl': 0, 'priority': 'high' }) %} {% endif %} {% if 'channel' in notify_data %} {% set message.data = dict(message.data, **{ 'channel': notify_channel }) %} {% endif %} {% if 'sticky' in notify_data %} {% set message.data = dict(message.data, **{ 'sticky': "true" }) %} {% endif %} {{ message.data }} trigger: - platform: state id: "t0" @@ -409,6 +516,7 @@ action: data: title: !input notify_title message: !input notify_message data: "{{ device_message_data }}" - choose: - alias: "Use the persistent notification is enabled" conditions: -
Blackshome revised this gist
May 11, 2024 . 1 changed file with 1 addition and 1 deletion.There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -410,7 +410,7 @@ action: title: !input notify_title message: !input notify_message - choose: - alias: "Use the persistent notification is enabled" conditions: - condition: template value_template: "{{ include_persistent_notification == 'enable_persistent_notification' }}" -
Blackshome revised this gist
May 11, 2024 . 1 changed file with 1 addition and 1 deletion.There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -413,7 +413,7 @@ action: - alias: "Use the persistent notification options" conditions: - condition: template value_template: "{{ include_persistent_notification == 'enable_persistent_notification' }}" sequence: - service: persistent_notification.create data: -
Blackshome revised this gist
May 11, 2024 . 1 changed file with 1 addition and 1 deletion.There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -241,7 +241,7 @@ blueprint: name: Use The Time Options (Optional) description: Use the "Start Time", "End Time" and the "Weekdays" values to only run the automation between the time periods. This option allows you to disable the automation during sleeping hours to avoid disturbing anyone. Another example is setting the time between 5pm and 9pm for the 'dinner is ready' call. This way, if you accidentally activate the trigger outside these hours, the automation will not run. default: time_disabled selector: -
Blackshome created this gist
May 11, 2024 .There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -0,0 +1,432 @@ blueprint: name: Notifications & Announcements description: > # 📢 Notifications & Announcements **Version: 1.0** State your trigger and spread the word 💬 🔉 **If you like my blueprints, and would like to show your support or just say thank you?** [Click Here](https://www.paypal.com/donate/?hosted_button_id=WAZS3QSDTPGA8) 🙂 <details> <summary><b>The Automation Process:</b> - Click here to expand</summary> - **Trigger Options:** - Specify the state change of one or more entities that will initiate the automation from a dropdown list. You can also specify your own custom state if it is not available from the dropdown list. - State Change Options: The available state changes include: - **General States:** Button or any state, ON, OFF, Unavailable or Unknown - **Location-Based States:** Home or Not Home - **Numeric States:** Numeric state above, Numeric state below or Numeric state above & below - **Notification Options:** - Opt to send messages to one or multiple devices. Compatible with Apple iOS and Android devices. - Opt to display your notifications directly within the Home Assistant user interface (UI). - Opt to send Text-to-Speech Announcement to your selected media players. - **Time-Based Automation:** - Specify precise start and end times along with weekday selections to define when the automation can run. - **Custom Conditions:** - Enter any custom conditions to further customize the automation process. </details> Need help? See our FAQ: [Click Here](https://community.home-assistant.io/t/notifications-announcements/728100/2?u=blacky) Let us know what you think of this blueprint and for community support including updates: [Click Here](https://community.home-assistant.io/t/notifications-announcements/728100?u=blacky) Required = * domain: automation input: trigger_state: name: Trigger - State * description: Please select what state you would like for your trigger. You can choose from ten options available in the dropdown menu. If your option is not in the dropdown menu then just type the state you would like to use in and click the save button. 1 - Button Or Any State 2 - ON 3 - OFF 4 - Unavailable 5 - Unknown 6 - Home 7 - Not Home 8 - Numeric State - Above 9 - Numeric State - Below 10 - Numeric State - Above & Below A numbering system has been implemented to facilitate navigation within the dropdown selections. Each number corresponds to a specific configuration, aiding users in identifying and adjusting the settings used within each selection. For instance, when selecting "8 - Numeric State - Above" as a dropdown option, settings marked "Used in options 8, 9 or 10" are required for that respective selection because number 8 is included in those options. default: button_any_state selector: select: custom_value: true mode: dropdown options: - label: 1 - Button Or Any State value: "button_any_state" - label: 2 - ON value: "on" - label: 3 - OFF value: "off" - label: 4 - Unavailable value: "unavailable" - label: 5 - Unknown value: "unknown" - label: 6 - Home value: "home" - label: 7 - Not Home value: "not_home" - label: 8 - Numeric State - Above value: "numeric_state_above" - label: 9 - Numeric State - Below value: "numeric_state_below" - label: 10 - Numeric State - Above & Below value: "numeric_state_above_below" trigger_state_entity: name: Trigger - State Entities description: "**Used in options 1, 2, 3, 4, 5, 6 or 7** - Enter the entities that will trigger the automation on state change." default: [] selector: entity: multiple: true trigger_numeric_entity: name: Trigger - Numeric State Entities description: "**Used in options 8, 9 or 10** - Enter the entities that will trigger the automation numeric state change." default: [] selector: entity: multiple: true above_state: name: Trigger - Numeric State Above Option description: "**Used in options 8, or 10** - Set the above value. The numeric state trigger will be when the value crosses over to above the set value." default: 0 selector: number: min: -20 max: 100 step: 1 unit_of_measurement: value below_state: name: Trigger - Numeric State Below Option description: "**Used in options 9 or 10** - Set the below value. The numeric state trigger will be when the value crosses over to below the set value." default: 0 selector: number: min: -20 max: 100 step: 1 unit_of_measurement: value time_delay_state: name: Trigger - Time Delay description: "**Used in options 1, 2, 3, 4, 5, 6, 7, 8, 9 or 10** - The state trigger will only fire if the state holds for the set time delay. It is used as a buffer to stop false triggers." default: 0 selector: number: min: 0 max: 10 step: 0.5 unit_of_measurement: minutes include_notify: name: Use The Mobile App Notify Opion (Optional) description: Enabling this option will send notifications to the selected devices below. default: disable_mobile_app_notify selector: select: options: - label: Enable Mobile App Notify Opion value: "enable_mobile_app_notify" - label: Disable Mobile App Notify Opion value: "disable_mobile_app_notify" notify_device: name: Mobile App Notify - Devices Notified When Started description: Select the devices to be notified when the automation is triggered. default: [] selector: device: filter: - integration: mobile_app multiple: true notify_title: name: Mobile App Notify - Title description: Enter in the title of your notification. default: 📢 Enter Notify Title Here selector: text: notify_message: name: Mobile App Notify - Message description: Enter in the message of your notification. default: Enter Notify Message Here 🙂 selector: text: include_persistent_notification: name: Use The UI Notification Option (Optional) description: Enabling this option will display notifications directly within the Home Assistant user interface (UI). default: disabled_persistent_notification selector: select: options: - label: Enable UI Notification value: "enable_persistent_notification" - label: Disable UI Notification value: "disabled_persistent_notification" persistent_title: name: UI Notification - Title description: Enter in the title of your UI notification. default: 📢 Enter UI Title Here selector: text: persistent_message: name: UI Notification - Message description: Enter in the message of your UI notification. default: Enter UI Message Here 🙂 selector: text: include_tts_announcement: name: Use The Text-to-Speech Announcement Option (Optional) description: Enabling this option will send a Text-to-Speech notification to the selected Media Players below. default: disable_tts_announcement selector: select: options: - label: Enable Text-to-Speech Notify Opions value: "enable_tts_announcement" - label: Disable Text-to-Speech Notify Opions value: "disable_tts_announcement" text_to_speech_engine: name: Text-to-Speech Service Provider description: Select the Text-to-Speech service provider. default: [] selector: entity: domain: tts media_player: name: Media Player description: Select the Media Player/s that will play your Text-to-Speech announcement message. default: [] selector: entity: domain: media_player multiple: true notify_tts_message: name: Announcement Message description: Enter in the message of your Text-to-Speech announcement. default: Enter TTS Message Here selector: text: multiline: true include_time: name: Use The Time Options (Optional) description: Use the "Start Time", "End Time" and the "Weekdays" values to only run the automation between the time periods. This option allows you to disable the automation during sleeping hours to avoid disturbing anyone. Another example is setting the time between 5 p.m. and 9 p.m. for the 'dinner is ready' call. This way, if you accidentally activate the trigger outside these hours, the automation will not run. default: time_disabled selector: select: options: - label: Enable the time options value: "time_enabled" - label: Disable the time options value: "time_disabled" after_time: name: Start Time description: Set the start time. default: 00:00:00 selector: time: before_time: name: End Time description: Set the end time. default: 00:00:00 selector: time: weekday_options: name: Weekdays description: Select the days of the week you would like the automation to run. You must select "Enable the time options" above for the weekdays selections to work. default: - mon - tue - wed - thu - fri - sat - sun selector: select: multiple: true mode: list options: - label: Monday value: "mon" - label: Tuesday value: "tue" - label: Wednesday value: "wed" - label: Thursday value: "thu" - label: Friday value: "fri" - label: Saturday value: "sat" - label: Sunday value: "sun" global_conditions: name: Global Conditions description: Enter any global conditions you would like to apply to the automation. default: [] selector: condition: mode: single max_exceeded: silent variables: trigger_state: !input trigger_state trigger_state_entity: !input trigger_state_entity trigger_numeric_entity: !input trigger_numeric_entity above_state: !input above_state below_state: !input below_state time_delay_state: !input time_delay_state include_notify: !input include_notify notify_device: !input notify_device notify_title: !input notify_title notify_message: !input notify_message include_persistent_notification: !input include_persistent_notification persistent_title: !input persistent_title persistent_message: !input persistent_message include_tts_announcement: !input include_tts_announcement text_to_speech_engine: !input text_to_speech_engine media_player: !input media_player notify_tts_message: !input notify_tts_message include_time: !input include_time after_time: !input after_time before_time: !input before_time weekday_options: !input weekday_options global_conditions: !input global_conditions trigger: - platform: state id: "t0" entity_id: !input trigger_state_entity for: minutes: !input time_delay_state - platform: state id: "t1" entity_id: !input trigger_state_entity to: !input trigger_state for: minutes: !input time_delay_state - platform: numeric_state id: "t2" entity_id: !input trigger_numeric_entity above: !input above_state for: minutes: !input time_delay_state - platform: numeric_state id: "t3" entity_id: !input trigger_numeric_entity below: !input below_state for: minutes: !input time_delay_state # All Conditions condition: #Trigger conditions - condition: or conditions: - condition: and # trigger for button or any state conditions: - condition: trigger id: 't0' - "{{ trigger_state == 'button_any_state' }}" - condition: and # trigger not for button or any state conditions: - condition: trigger id: 't1' - "{{ (trigger_state != 'button_any_state') or (trigger_state != 'numeric_state_above') or (trigger_state != 'numeric_state_below') or (trigger_state != 'numeric_state_above_below') }}" - condition: and # trigger for numeric above state conditions: - condition: trigger id: 't2' - "{{ (trigger_state == 'numeric_state_above') or (trigger_state == 'numeric_state_above_below') }}" - condition: and # trigger for numeric below state conditions: - condition: trigger id: 't3' - "{{ (trigger_state == 'numeric_state_below') or (trigger_state == 'numeric_state_above_below') }}" # Check The Time Options - condition: or conditions: - "{{ include_time == 'time_disabled' }}" - condition: and conditions: - condition: time after: !input after_time before: !input before_time weekday: !input weekday_options - "{{ include_time == 'time_enabled' }}" # Global Conditions - condition: and conditions: !input global_conditions action: - choose: - alias: "Check if notification is enabled" conditions: - "{{ include_notify == 'enable_mobile_app_notify' }}" sequence: - alias: Send a notification to each device repeat: for_each: !input notify_device sequence: - service: "notify.mobile_app_{{ device_attr(repeat.item, 'name') | slugify }}" data: title: !input notify_title message: !input notify_message - choose: - alias: "Use the persistent notification options" conditions: - condition: template value_template: "{{ (include_persistent_notification == 'enable_persistent_notification') or (include_persistent_notification == 'enable_persistent_okay_notification') }}" sequence: - service: persistent_notification.create data: title: !input persistent_title message: !input persistent_message - choose: - alias: "Check if tts announcement is enabled" conditions: - "{{ include_tts_announcement == 'enable_tts_announcement' }}" sequence: - service: tts.speak target: entity_id: !input text_to_speech_engine data: media_player_entity_id: !input media_player message: !input notify_tts_message