Create a gist now

Instantly share code, notes, and snippets.

What would you like to do?
Push Me bash script
#!/bin/sh
message="$1"
curl -so \
- --data "title=$message&token=[token-here]" \
https://pushmeapi.jagcesar.se
Owner

JagCesar commented May 16, 2017

Save this to a .sh file, and don't forget to make it executable using the command chmod +x pushMe.sh.

Then you execute it by writing ./pushMe.sh Hello!

malinnikov commented Oct 16, 2017

Hello there, thanks for the cool service! I have a question: should parameter be "token" or "identifier", as mentioned in the iOS app? I managed to send notifications before but now I can't see pushes on device with either parameter name.

Ah, never mind, both do work. I just had to change the script to make it work on macOS Sierra:

message="$1"

curl -d "title=$message&token=my_token" -X POST https://pushmeapi.jagcesar.se
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment