ntfy

thumbnail

created  2023/07/12
modified 2023/09/18
category info

notify is a simple http-based publisher-subscriber notification service. it allows you to send notifications to your phone/desktop/other clients via scripts from any source with an internet connection

ntfy.sh

TODO: host a ntfy instance on zvava.org

how

so if you have a ntfy server running on example.com, there are several topics a client can subscribe or publish to through a page under the domain; example.com/mail; example.com/alerts; etc

examples

sh

curl -d "message" ntfy.sh/topic

js

let sendMessage(topic, message) =>
	fetch("https://ntfy.sh/" + topic, {
		method: "POST", body: message })

sendMessage("topic", "message")

clients

official clients exist for command-line, web, android, and ios

command-line interface
web interface (pwa)
android app
ios app

i was working on a cross-platform c# desktop app that i still need to finish (but probably won't thanks to the broken state of the ui library i used, perhaps a rewrite with a modern ui library is due?)

ntfy desktop

i also made a small node.js-based command line tool to subscribe to topics and execute scripts on certain events

ntfy.sh.sh

TODO: writeup of these projects

security

if you pay a subscription you can reserve topics on ntfy.sh, otherwise, you may host an instance of ntfy on a server of yours

you may lock subscribing/publishing to topics behind either access tokens or simple username/password authentication, passed in either the headers of the request or the query parameters

docs.ntfy.sh — authentication