Getting Started
NotifyHero lets you send push notifications to your phone or desktop via scripts from any computer, using simple HTTP PUT or POST requests. Use it to notify yourself when scripts fail, or long-running commands complete.
Step 1: Get the app
To receive notifications on your phone, install the app from your preferred store:
Once installed, open it and subscribe to a topic of your choosing. Topics don't have to explicitly be created, so just pick a name and use it later when you publish a message.
Note: Topic names are public, so it's wise to choose something that cannot be guessed easily.
For this guide, we'll just use mytopic as our topic name.
Step 2: Send a message
Now let's send a message to our topic. It's easy in every language, since we're just using HTTP PUT/POST. The message is in the request body.
Using curl
curl -d "Backup successful 😀" https://app.notifyhero.com/mytopic
Using JavaScript
fetch('https://app.notifyhero.com/mytopic', {
method: 'POST',
body: 'Backup successful 😀'
})
Using Python
import requests
requests.post("https://app.notifyhero.com/mytopic",
data="Backup successful 😀".encode(encoding='utf-8'))
Using Go
http.Post("https://app.notifyhero.com/mytopic", "text/plain",
strings.NewReader("Backup successful 😀"))
Using PHP
file_get_contents('https://app.notifyhero.com/mytopic', false, stream_context_create([
'http' => [
'method' => 'POST',
'header' => 'Content-Type: text/plain',
'content' => 'Backup successful 😀'
]
]));
What's next?
That's it! You're all set. Go play and read the rest of the docs:
- Publishing messages - Learn about all the features for sending notifications
- Phone app - Detailed guide on using the Android/iOS app
- API reference - Full API documentation
- Examples - Real-world usage examples