Page 1 of 1
How to get GCM RegistrationID via JavaScript
Posted: Wed Oct 22, 2014 1:23 pm
by Diego Dillenburg Bueno
Hello,
is there any way that I can retrieve the Android's GCM RegistrationID that is replied when a device is successfully registered in the GCM Server when enabling push notifications here in Appery trhough JavaScript?
How to get GCM RegistrationID via JavaScript
Posted: Wed Oct 22, 2014 1:47 pm
by Evgene Karachevtsev
Hello Diego,
Device ID is stored in the local storage variable pushNotificationDeviceID. Please look here: https://getsatisfaction.com/apperyio/...
How to get GCM RegistrationID via JavaScript
Posted: Wed Oct 22, 2014 2:02 pm
by Diego Dillenburg Bueno
But this is the deviceID I have stored in the devices collection, right? When trying to post it directly to GCM I get the invalidRegistration error, which means that this ID isn't matching the one at GCM, am I right?
How to get GCM RegistrationID via JavaScript
Posted: Wed Oct 22, 2014 5:58 pm
by Diego Dillenburg Bueno
As stated here in this other answer: https://getsatisfaction.com/apperyio/... I'm able to grab the ID via JavaScript to directly send to GCM or APNS, but how to do so? That's what I tried to ask from the beggining, sorry for misundertoods.
The values I have at my devices table aren't the ones that I'm needing at the moment.
Thanks in advance,
Diego Dillenburg Bueno
How to get GCM RegistrationID via JavaScript
Posted: Thu Oct 23, 2014 12:29 pm
by Evgene Karachevtsev
Hello Diego,
If you are not using the services of Appery.io and want to send push notifications, you need to understand how the plugin for pushes work and use it as you wish. You may connect any other Cordova plugin for push and use it according to its API. But unfortunately this is out of scope of out support.
How to get GCM RegistrationID via JavaScript
Posted: Fri Oct 24, 2014 2:31 pm
by Diego Dillenburg Bueno
Oh thanks, that would be it then. I'll use the other plugin I had seen. Just one more question: how can I import the plugin? Because on the plugin list it doesn't appear the plugin I want. How do I manually add a plugin I want?
Thanks
How to get GCM RegistrationID via JavaScript
Posted: Fri Oct 24, 2014 2:36 pm
by Evgene Karachevtsev
Hello Diego,
Hope this link will help you: http://devcenter.appery.io/documentat...
How to get GCM RegistrationID via JavaScript
Posted: Fri Oct 24, 2014 2:39 pm
by Diego Dillenburg Bueno
Thanks Evgene, I have already read that documentation, but the plugin I want to add isn't listed there. If I put it in the "SOURCE" of the project, will it work?
How to get GCM RegistrationID via JavaScript
Posted: Sat Oct 25, 2014 5:53 pm
by Alena Prykhodko