Problems with Google Developer Console - Sender ID for GCM

只愿长相守 提交于 2020-01-03 06:33:19

问题


I'm not a developer, but a graphic that needs to publish a digital kiosk magazine made with twixl platform.

I followed the steps of the twixl documentation to create a Sender ID for notifications on Android (FCM/GCM). I created an app where I associated a Sender ID (API key) and everything worked. I also have the statistics for a few days in which the app was active.

For certificate problems, however, I had to cancel this publication and do another, from the same account (app@pizzanew.it).

In Google Cloud Platform, I deleted the old project and I created a new one. Now, when I go to the Google Developer Console to associate a new id, it tells me that the value of API Key is not valid.

It may be that it is linked to the old app or in some way that I do not know? But the old app is no longer published.

I do not know how to do it, but I must be able to set this id for notifications. I configured only general information of the new app, but it has not yet been published, and I have not uploaded the new APK. May it's because of it?

Appreciate any help.


回答1:


There are two concept to understand:

sender-id : this is the ID of the project in Google Cloud Console (for old projects) or Firebase Console (for new projects)

server-key : (also referred as API-Key) this is the "password" for your server to send messages.

If you want to change your SENDER-ID:

  1. create a new Firebase Project: https://firebase.google.com
  2. read the SenderId & Server-Key in the settings
    (Where can I find the API KEY for Firebase Cloud Messaging?)
  3. update the sender-id in all the configurations you have
    (if you are using the FCM sdk you need to download the new google-services.json file)

PS: you should be able to undelete the old project from Google Cloud Platform if you need to keep the same sender-id. But new projects should be created in Firebase Console, and old projects who need a new server-key should import the old project into the Firebase Console.



来源:https://stackoverflow.com/questions/39392627/problems-with-google-developer-console-sender-id-for-gcm

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!