Missing api_key/current key with Google Services 3.0.0

后端 未结 17 941
小鲜肉
小鲜肉 2020-12-02 07:20

Since I upgraded the project with the latest version of google services and libraries (9.0.0), I have this strange issue :

Grade console :

:         


        
17条回答
  •  挽巷
    挽巷 (楼主)
    2020-12-02 08:11

    regenerate google-services.json at https://developers.google.com/cloud-messaging/android/client#get-config,one important thing is that you must enable Cloud Messaging in "Choose services" step ,open the new google-services.json file you will see words like

        "api_key": [
         {
           "current_key": "xxxxxxxxxxx"
         }"
    

    without this words or without value of current_key is not the right file

提交回复
热议问题