From 86a16e394471e8022cd39210b4e8367f7d73aef9 Mon Sep 17 00:00:00 2001
From: Philipp Heckel
+ There are many ways to use ntfy. You can send yourself messages for all sorts of things: When a long process finishes or fails (a backup, a long rsync job, ...), + or to notify yourself when somebody logs into your server(s). Or you may want to use it in your own app to distribute messages to subscribed clients. + Endless possibilities 😀. +
@@ -130,6 +135,14 @@
This is a notification
+
+ Here's an example of how to use this endpoint to send desktop notifications for every incoming message: +
+
+ while read msg; do
+ [ -n "$msg" ] && notify-send "$msg"
+ done < <(stdbuf -i0 -o0 curl -s ntfy.sh/mytopic/raw)
+
@@ -179,8 +192,7 @@ In addition to caching messages locally and delivering them to long-polling subscribers, all messages are also published to Firebase Cloud Messaging (FCM) (if FirebaseKeyFile is set, which it is on ntfy.sh). This is to facilitate instant notifications on Android. I tried really, really hard to avoid using FCM, but newer - versions of Android made it impossible to implement background services>. - I'm sorry. + versions of Android made it impossible to implement background services.