This is a work-in-progress. The idea is that you receive a message that was sent via the Pushover Service.
- Download the Pushover client to your phone (good for trouble-shooting)
- Send a pushover message from the Pushover website, and receive it on your phone
- Send a pushover message from the command-line, and receive it on your phone
- Send a message from the CLI, and receive it via a CLI websocket
A. Install the iPhone app on your phone (might cost $5 ?) B. Purchase the Open Client Desktop license (costs $5)
- Create your account at the Pushover website
- Install the iPhone App
- Login to your account
- <There might be another step, but I did it back in 2012, so I can't remember the exact details. Feel free to open an issue if you've got more detail here>
- Go to your Pushover dashboard, and find your email address (which delivers to all your devices)
- Send a short email to that address
- Enjoy the sweet sound of the notification (and message) on your iPhone
- Didnt' work ? Keep working at it, no sense going on until you figured this out
- Login to your favorite Linux box
- Go to the Pushover website (https://pushover.net)
- At the top right, in big giant letters is "Your User Key". SAVE THIS (needed below, called "user")
- Scroll down to "Your Applications"
- Click on "Create an Application/API Token" (or click here: https://pushover.net/apps/build)
- Name: test01
- Type: Other
- Description: test cli pushover client
- URL:
- Icon:
- Go back to your dashboard, click on your new application
- In big giant letters, will tell you your new "API Token/Key". SAVE THIS (needed below, called "token")
- Clone this repository
- Create a file called "pushover.config" (use "user" and "token" from above)
[pushover]
token = apadskSuperFakeTokendkgasd
user = aakdgThisisaFakeUseradksVaS
- Run this command
./pushoverSend.py -v --message "Now is the time for all good men to come to the aid of their country"
- Enjoy the sound of notification on your phone
-
This next part needs to be done once, and can only be done via the command-line
-
Login to a Linux box
-
Request your secret token
- curl --form-string "email=[your-email-address]" --form-string "password=[pushover-acct-password]" https://api.pushover.net/1/users/login.json
{"status":1,"id":"<your-user-key>","secret":"<secret-token>","request":"<request-id>"}
- Again, as the same Linux CLI
- Create your Desktop app, and get your secret key
- curl --form-string "secret=[secret-token]" --form-string "name=[app-name]" --form-string "os=O" https://api.pushover.net/1/devices.json
{"id":"<device-id>","status":1,"request":"<request-id>"}
OK, whew ! You should now have these two items:
- Secret Key (we'll call this "secet")
- Device ID (we'll call this "device_id")
- Log in to your linux box again
- Go back to same directory where you cloned this repository
- Create a file called "pushoverListen.config" in the following format (without the "<>" brackets, of course)
[pushoverListen]
secret=<secret>
device_id=<device-id>
- Use python 2.7 (check via 'python -V')
- (Optional) Create a virtual python environment
- virtualenv venv --python=python2
- source venv/bin/activate
- Install pycurl (which also needs unix command "curl" to be there)
- pip install pycurl
- pip install websocket
NOTE: Here's a bit of detail if you're using Cygwin and a virtualenv like me:
- export PYCURL_SSL_LIBRARY=openssl
- python venv/bin/pip install pycurl
- That last part isn't really all that scary, just wanted you to know.
- It's just how the API works, no way around it
- OK, ready ?
- Run this command "./pushoverListener.py -v"
- It won't return your command-prompt, it's running in the shell foreground
- Every 30s or so, you should see "Received tickler"
- You can send that test message however you want (easiest way is the website, I guess)
- That command-line listener in the previous step should have woken up, and showed you the message
- If you don't get the message with 5s, it's not coming