1

Does anybody know where to get the API Key mentioned in this documentation when using Firebase Cloud Messaging (FCM)?

enter image description here

Google Cloud Messaging (GCM) has been replaced by FCM, and I'm not sure where to find the required API key.

I managed to send push notification directly from Firebase project to my app, but when I try to send test notification from my Connected App inside Salesforce I get an error message, probably due to incorrect API Key.

1

1 Answer 1

1

Navigate to https://console.firebase.google.com

You can find the Server Key and associated Sender ID in:

(gear-next-to-project-name) > Project Settings > Cloud Messaging

3
  • Thank you very much, this got me out of status quo finally. I copied the Server Key and tried to send the test notification again, and this time I got a new error message that I haven't seen before: Recipient field contains registration ID that is not valid for the connected application's key for server applications (API key) (GCM error code: MismatchSenderId). Any chance you might know what's the issue?
    – smukov
    Sep 15, 2016 at 16:03
  • When the registration call is made by our SDK it will return your SystemToken (search LogCat). That is the token that you need to use. Programmatically you can get it with the getSystemToken() convenience method and it will also be output from the getSdkState() method.
    – Bill Mote
    Sep 15, 2016 at 20:44
  • 1
    Thanks. I had to set the androidPushNotificationClientId in my bootconfig.json to Sender ID from Firebase. Now everything works perfectly.
    – smukov
    Sep 16, 2016 at 6:00

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .