I've been following this guide
and still dont get it (Im quite new to the whole android-stuff, Im sorry).
"1. Create a servlet (or other server-side mechanism) that can be used by the Android application to send the registration ID received by GCM . The application might also need to send other information—such as the user's email address or username—so that the server can associate the registration ID with the user owning the device.
2. Similarly, create a servlet used to unregister registration IDs."
I dont think this guide is very thorough overall but right here I ran into some trouble. Is there any kind code-cracker out there who can help me?
How do I make a "servlet" for GCM?
Thank you in advance!PS. Im using eclipse
You should probably take a look at the GCM Demo Application page, specifically the Setting Up the Server section which shows two methods for setting up a GCM server. I have seen a few other GCM developers using Google App Engine for their GCM servers as detailed in point two of the link.
There are also commercial solutions out there such as AirBop (which I happened to help create), Urban Airship, and a few others.
Related
I know how to implement GCM in my App but I don't know how to build a server able to send notification to ALL the users.
I need something quite simple (just sending notification), could you advise me any services and tutorial in order to set up the server?
I wish something not to complex, because everything that I will need from my app is receiving whether simply notifications to display or to tell the app that some new data is available for downloading.
Thank you!!
Prerequisite for GCM Application
Google API Server Key
GCM RegId of the Android Device to communicate via GCM
If you get clear concept about GCM, please visit here
If you want to use java for server side then visit my answer.
Related Links:
Android Push Notifications using Google Cloud Messaging (GCM), PHP and MySQL
Android Warriors
If you're using PHP, you could use this approach to send GCM message to your client refer this
You could setup your own local server on PHP using AMPP. refer this
Probably, the simplest way is to add a cloud endpoint module refer this. Then, write a simple service refer this that sends the messages. Finally, let Android Studio deploy it.
I have searched all over the internet but didn't get what I wanted. I want to send GCM notifications to my android app using parse rest api. I know that there is a clean documentation on Parse.com but i am confused about that what changes are needed in my application to receive those GCM pushes. I am able to send pushes, they are showing in the GCM history on developer page in google but i am unable to receive them on my phone which is irritating because there is no tutorial on what changes to be made in my application. Please if anyone can help.
All you have to do is add the push receiver into the AndroidManifest, and this is documented.
You have to make sure the bundle id matches your app's and also there may be a GCM identifier you need to change
Has anyone succeeded in using pubnub examples for android? I am working a senior project that uses it for interacting with raspberry pi remotely. The demo project works find but replacing the pub/sub key with my own causes unknownhostExecption. I have created GCM account and using the api key as the sender ID. My manifest is registered the appropriate permission as well. I have been stuck with for a while. but still unable to figure out the cause.
What do i need to do?
I will start by linking to an Android PubNub project that was created to interact with a Raspberry Pi remotely. Take a look here https://github.com/GleasonK/PHue
I have created GCM account and using the api key as the sender ID.
Are you trying to use GCM? If all you need is Pub/Sub you simply need your developer Pub and Sub keys. Unknown host might be because you are using the wrong keys. Visit the admin console and log in (https://admin.pubnub.com/). You should then see Publish Key and Subscribe Key. Those are the two you need to use when instantiating a Pubnub object in Android.
If your project actually requires GCM, PubNub does support that as well. From the PN Blog. If this is what you need me to elaborate on let me know and I would be glad to!
I have an android application where push notifications are implemented by GCM.
I need to change this. I need that with the new release (the app is already in the Store and people already use push with GCM) all the mechanism will be handle from Parse.
Can I simply delete everything concerning GCM and implement everything concerning PARSE and then upload the version of the application and be sure that everything will run the same?
Has anybody an idea if there will be conflicts with doing this? I'm thinking about devices that already have a GCM token for example.
You should try it and see. I think when implementing Parse, the registration ID (unique to every app <--> device) will be generated again. I've written a couple of articles on the topic which are not directly useful but can help in other ways.
Just make sure you follow this thoroughly.
I am new to the push notification subjet for android and I have an application with a .net web server as well as a remote database. I want to send a notification to all users which opens in a new intent. I have read about GCM and other third party platforms, but I was confused when they mention device registration ID, as I do not know how to get all the ids of all devices installing the app I am developping. Any straightforward tutorial or code helping me solve the confusion please.
Thank you in advance.
May be this can not provide complete answer to your question asked. But still it can help you.
GCM process works in this way.
at the first launch, your application will get the registration id from Google GCM server and give it to application server. Now the application server has all the registration ids in which your app is running.
Now you can easily dispatch push message for all devices.