Skip to content

Instantly share code, notes, and snippets.

@snijsure
Forked from sebastianbenz/gcm-high-prio.sh
Created April 29, 2017 02:12
Show Gist options
  • Save snijsure/be3541acdb9a2702ad628b5992f4e752 to your computer and use it in GitHub Desktop.
Save snijsure/be3541acdb9a2702ad628b5992f4e752 to your computer and use it in GitHub Desktop.
Send high priority GCM messages via curl (Android Doze mode & App Standby testing)
curl -X POST \
-H "Authorization: key= YOUR-API-KEY" \
-H "Content-Type: application/json" \
-d '{
"registration_ids": [
"YOUR-GCM-REGISTRATION-ID"
],
"data": {
"message": "Hello Message"
},
"priority": "high"
}' \
https://android.googleapis.com/gcm/send
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment