From f13cc4de2a09453e7df7164da005fd46a9cff9d6 Mon Sep 17 00:00:00 2001 From: tr4nt0r <4445816+tr4nt0r@users.noreply.github.com> Date: Thu, 9 Jan 2025 19:41:23 +0100 Subject: [PATCH 1/4] Add documentation for ntfy integration --- source/_integrations/ntfy.markdown | 77 ++++++++++++++++++++++++++++++ 1 file changed, 77 insertions(+) create mode 100644 source/_integrations/ntfy.markdown diff --git a/source/_integrations/ntfy.markdown b/source/_integrations/ntfy.markdown new file mode 100644 index 000000000000..38949c51c45c --- /dev/null +++ b/source/_integrations/ntfy.markdown @@ -0,0 +1,77 @@ +--- +title: ntfy +description: Instructions on how to integrate ntfy with Home Assistant. +ha_category: + - Notifications +ha_iot_class: Cloud Push +ha_release: 2025.2 +ha_config_flow: true +ha_codeowners: + - '@tr4nt0r' +ha_domain: ntfy +ha_integration_type: integration +ha_platforms: + - notify +--- + +The **ntfy** {% term integration %} allows publishing push notifications on [ntfy.sh](https://ntfy.sh/) or other ntfy services. + +## About ntfy + +**ntfy** is a simple HTTP-based pub-sub notification service to sernd notifications to phones or desktops. The official [ntfy](https://ntfy.sh/) service also offers notifications via e-mail or by phone calls using text-to-speech to read the message out loud. As Ntfy is 100% open-source, there are also alternative public ntfy services but can also be self-hosted. + +## How you can use this integration + +The ntfy integration can be used to send push notifications from automations and scripts in real-time to your mobile devices and desktops. + +## Prerequisites + +1. **Service URL** + + To set up the **ntfy** integration, you need the URL of the ntfy service you wish to use. + + - Use `https://ntfy.sh` for the official ntfy service. + - Provide the URL of an alternative public ntfy service or your self-hosted instance (for example, `https://your-ntfy-instance.com`). +2. **Topic name** + + Determine the topic name you want to publish notifications to. + + - Enter a **new topic name** to create a unique channel for notifications. + - Leave the topic field empty to allow the integration to generate a **random topic name** automatically. + - Use an **existing topic name** by retrieving it from the ntfy app or the ntfy service's website. Simply copy and paste the topic name into the configuration. + +{% include integrations/config_flow.md %} + +## Configuration parameters + +{% configuration_basic %} +"Service URL": + description: "Address of the ntfy service. Defaults to `https://ntfy.sh`." +"Topic": + description: "Name of the topic you want to publish to." +{% endconfiguration_basic %} + +## Notifiers + +The **ntfy** integration will add a notify entity with the name of the topic. To publish notifications you can use the `notify.send_message` action. To use notifications, please see the [getting started with automation page](/getting-started/automation/). + + +{% details "Example YAML configuration" %} + +{% raw %} + +```yaml +action: notify.send_message +data: + message: "Reminder: Have you considered frogs?" + entity_id: notify.mytopic +``` +{% endraw %} + +{% enddetails %} + +## Removing the integration + +This integration can be removed by following these steps: + +{% include integrations/remove_device_service.md %} \ No newline at end of file From 39cd95f7171e433688474dc28ccaa1725e4f3870 Mon Sep 17 00:00:00 2001 From: tr4nt0r <4445816+tr4nt0r@users.noreply.github.com> Date: Thu, 9 Jan 2025 20:13:36 +0100 Subject: [PATCH 2/4] typos --- source/_integrations/ntfy.markdown | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/source/_integrations/ntfy.markdown b/source/_integrations/ntfy.markdown index 38949c51c45c..b13f74c48d92 100644 --- a/source/_integrations/ntfy.markdown +++ b/source/_integrations/ntfy.markdown @@ -18,7 +18,7 @@ The **ntfy** {% term integration %} allows publishing push notifications on [ntf ## About ntfy -**ntfy** is a simple HTTP-based pub-sub notification service to sernd notifications to phones or desktops. The official [ntfy](https://ntfy.sh/) service also offers notifications via e-mail or by phone calls using text-to-speech to read the message out loud. As Ntfy is 100% open-source, there are also alternative public ntfy services but can also be self-hosted. +**ntfy** is a simple HTTP-based pub-sub notification service to send notifications to phones or desktops. The official [ntfy](https://ntfy.sh/) service also offers notifications via e-mail or by phone calls using text-to-speech to read the message out loud. As Ntfy is 100% open-source, there are also alternative public ntfy services but can also be self-hosted. ## How you can use this integration @@ -28,14 +28,14 @@ The ntfy integration can be used to send push notifications from automations and 1. **Service URL** - To set up the **ntfy** integration, you need the URL of the ntfy service you wish to use. - + To set up the **ntfy** integration, you need the URL of the ntfy service you wish to use. + - Use `https://ntfy.sh` for the official ntfy service. - - Provide the URL of an alternative public ntfy service or your self-hosted instance (for example, `https://your-ntfy-instance.com`). + - Provide the URL of an alternative public ntfy service or your self-hosted instance (for example, `https://your-ntfy-instance.com`). 2. **Topic name** Determine the topic name you want to publish notifications to. - + - Enter a **new topic name** to create a unique channel for notifications. - Leave the topic field empty to allow the integration to generate a **random topic name** automatically. - Use an **existing topic name** by retrieving it from the ntfy app or the ntfy service's website. Simply copy and paste the topic name into the configuration. @@ -53,7 +53,7 @@ The ntfy integration can be used to send push notifications from automations and ## Notifiers -The **ntfy** integration will add a notify entity with the name of the topic. To publish notifications you can use the `notify.send_message` action. To use notifications, please see the [getting started with automation page](/getting-started/automation/). +The **ntfy** integration will add a notify entity with the name of the topic. To publish notifications, you can use the `notify.send_message` action. To use notifications, please see the [getting started with automation page](/getting-started/automation/). {% details "Example YAML configuration" %} From 52ea430ea1bfd9ba3738d50f24b358ba61ddc293 Mon Sep 17 00:00:00 2001 From: tr4nt0r <4445816+tr4nt0r@users.noreply.github.com> Date: Thu, 9 Jan 2025 20:52:27 +0100 Subject: [PATCH 3/4] trailing spaces --- source/_integrations/ntfy.markdown | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/source/_integrations/ntfy.markdown b/source/_integrations/ntfy.markdown index b13f74c48d92..ebd7b236d2cf 100644 --- a/source/_integrations/ntfy.markdown +++ b/source/_integrations/ntfy.markdown @@ -27,7 +27,7 @@ The ntfy integration can be used to send push notifications from automations and ## Prerequisites 1. **Service URL** - + To set up the **ntfy** integration, you need the URL of the ntfy service you wish to use. - Use `https://ntfy.sh` for the official ntfy service. @@ -55,7 +55,6 @@ The ntfy integration can be used to send push notifications from automations and The **ntfy** integration will add a notify entity with the name of the topic. To publish notifications, you can use the `notify.send_message` action. To use notifications, please see the [getting started with automation page](/getting-started/automation/). - {% details "Example YAML configuration" %} {% raw %} @@ -74,4 +73,4 @@ data: This integration can be removed by following these steps: -{% include integrations/remove_device_service.md %} \ No newline at end of file +{% include integrations/remove_device_service.md %} From d65203762263729543ea6d545d9f57dcf1883e6d Mon Sep 17 00:00:00 2001 From: tr4nt0r <4445816+tr4nt0r@users.noreply.github.com> Date: Thu, 9 Jan 2025 21:03:15 +0100 Subject: [PATCH 4/4] improve --- source/_integrations/ntfy.markdown | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/source/_integrations/ntfy.markdown b/source/_integrations/ntfy.markdown index ebd7b236d2cf..11bb0e0b22b7 100644 --- a/source/_integrations/ntfy.markdown +++ b/source/_integrations/ntfy.markdown @@ -18,7 +18,7 @@ The **ntfy** {% term integration %} allows publishing push notifications on [ntf ## About ntfy -**ntfy** is a simple HTTP-based pub-sub notification service to send notifications to phones or desktops. The official [ntfy](https://ntfy.sh/) service also offers notifications via e-mail or by phone calls using text-to-speech to read the message out loud. As Ntfy is 100% open-source, there are also alternative public ntfy services but can also be self-hosted. +**ntfy** is a simple HTTP-based pub-sub notification service that allows you to send notifications to phones or desktops. The official [ntfy](https://ntfy.sh/) service also provides additional features, such as notifications via email or phone calls using text-to-speech to read messages aloud. Since ntfy is 100% open-source, you can choose to use alternative public ntfy services or even host your own instance. ## How you can use this integration