Skip to content

Instantly share code, notes, and snippets.

@sergsoares
Created April 23, 2018 00:21
Show Gist options
  • Save sergsoares/0085cac62f64c5d2dd71a1de479c4c10 to your computer and use it in GitHub Desktop.
Save sergsoares/0085cac62f64c5d2dd71a1de479c4c10 to your computer and use it in GitHub Desktop.
Simple curl to send a notification to firebase with a deviceID.
curl -d '{
"to": DEVICE_ID,
"notification": {
"title" : " This is my title new ",
"body" : " This is the body of my message "
}
}' \
-i -H "Application/json" \
-H "Content-type: application/json" \
-H "Authorization: key=YOUR_AUTH_KEY \
-X POST https://fcm.googleapis.com/fcm/send
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment