Enable GCM for the app when downloaded to the Google Play Store

I upload an application to the Google Play Store that implements GCM.

How do I enable GCM for this application while uploading to the Google Play store? There is a section called "Enable Google Cloud Messaging Statistics."

I get this error when trying to pass the GCM sender id:

Invalid GCM API key or C2DM login token (bad key).

Can someone explain what steps should enable GCM for the application when loading into the Android market.

+6
source share
2 answers

(This question is pretty old, but I hope this answer helps others in the future.)

You need to use the API key, it seems that you yourself copy the sender ID. First, after creating the project in the Developer Consol, you need to enable the API :

  • In the left sidebar, select API and auth.
  • In the API list displayed, set Google Cloud Messaging for Android to ON.

Next, get the API key

  • In the left sidebar, select API and auth> Credentials.
  • In the Open API Access section, click Create a new key.
  • In the Create New Key dialog box, click Server.
  • In the configuration dialog that appears, specify the IP address of your server. For testing purposes you can use 0.0.0.0/0 .
  • Click Create.
  • On the updated page, copy the API key and use it in the Google Play Developer Console

More details

+6
source

Make sure your identifier Project ID or Sender ID is valid . This is a unique identifier for the project (the same identifier for the client and server).

In your case, you can use the project id of another project.

+2
source

All Articles