To create a Google API project:
- Open the Google Developers Console. https://console.developers.google.com/project
- Create Project.
- Copy down your project number. You will use it later on as the GCM sender ID.
- In the sidebar on the left, select APIs & auth
- In the displayed list of APIs, turn the Google Cloud Messaging for Android toggle to ON.
To obtain an API key:
- In the sidebar on the left, select APIs & auth > Credentials.
- Under Public API access, click Create new key.
- In the Create a new key dialog, click Server key.
- Click Create.
- Give this Server key in your server code.
Android Code :
Hi...Got the push form gcm server and dis answer easy to understand step by step.
ReplyDelete