quickstart-unity
quickstart-unity copied to clipboard
Update readme.md under messaging quickstart with new FCM REST API
Please, update link to send a push notification from command line curl.
not working: https://android.googleapis.com/gcm/send
working: https://fcm.googleapis.com/fcm/send
I found a few problems with this issue:
- I couldn't figure out how to label this issue, so I've labeled it for a human to triage. Hang tight.
- This issue does not seem to follow the issue template. Make sure you provide all the required information.
This bug report is for the file messaging/testapp/readme.md. Two samples there are:
curl --header "Authorization: key=<Server Key>" --header "Content-Type: application/json" https://android.googleapis.com/gcm/send -d '{"notification":{"title":"Hi","body":"Hello from the Cloud"},"data":{"score":"lots"},"to":"<Registration Token>"}'
and
curl --header "Authorization: key=<Server Key>" --header "Content-Type: application/json" https://android.googleapis.com/gcm/send -d '{"notification":{"title":"Hi","body":"Hello from the Cloud"},"data":{"score":"lots"},"to":"/topics/<Topic>"}'
It appears that they should be:
curl --header "Authorization: key=<Server Key>" --header "Content-Type: application/json" https://fcm.googleapis.com/fcm/send -d '{"notification":{"title":"Hi","body":"Hello from the Cloud"},"data":{"score":"lots"},"to":"<Registration Token>"}'
and
curl --header "Authorization: key=<Server Key>" --header "Content-Type: application/json" https://fcm.googleapis.com/fcm/send -d '{"notification":{"title":"Hi","body":"Hello from the Cloud"},"data":{"score":"lots"},"to":"/topics/<Topic>"}'
Which would match the reference docs for the Legacy HTTP Server Protocol.
We may want to take this a step forward and see if we can use the test interface here.