4

I was going through Google Cloud Messaging documentation and I came across this section:

http://developer.android.com/google/gcm/adv.html#canonical

Canonical IDs

If later on you try to send a message using a different registration ID, GCM will process the request as usual, but it will include the canonical registration ID in the registration_id field of the response. Make sure to replace the registration ID stored in your server with this canonical ID, as eventually the ID you're using will stop working.

How do we handle the Canonical Id update while using Amazon SNS Endpoint ANRs?

I checked the Amazon API documentation for

CreatePlatformEndpoint: http://docs.aws.amazon.com/sns/latest/api/API_CreatePlatformEndpoint.html

and

Publish: http://docs.aws.amazon.com/sns/latest/api/API_Publish.html

Please suggest. Thanks!

Community
  • 1
  • 1
Hari Krishna Ganji
  • 1,577
  • 1
  • 19
  • 33

1 Answers1

0

you can not get Canonical IDs via SNS ,but you can get it via Google GCM REST Api youself.

see this:GCM with PHP (Google Cloud Messaging)

result will have Canonical IDs.

Community
  • 1
  • 1
  • Note that [link-only answers](http://meta.stackoverflow.com/tags/link-only-answers/info) are discouraged, SO answers should be the end-point of a search for a solution (vs. yet another stopover of references, which tend to get stale over time). Please consider adding a stand-alone synopsis here, keeping the link as a reference. – kleopatra Aug 10 '15 at 15:55