Firebase Notification Integration - iOS Setup
Steps to create a firebase project and link it to the app created from webtonative.com
Last updated
Steps to create a firebase project and link it to the app created from webtonative.com
Last updated
Creating Project In Firebase
Go to Firebase site and sign in with your Google account if you have not already https://firebase.google.com/
Click on "Add project" and give it a name then continue
Click on Continue
Click on Default Account For Firebase or you can also create a new account. Then click on create project.
You will see the “Continue” button once the project is created. Click on it and you'll be redirected to the firebase project dashboard
Add IOS App To Firebase Project
Click on "iOS+" icon to add the ios app to your created firebase project.
Fill in the Apple bundle Id and Click on "Register app" button
Download the GoogleService-Info.plist, it will be used later.
Then you can simply click on the Next button. You don’t need to worry about the code shown we've done that handling for you in the app. Then you can click on continue to the console.
Now your dashboard will have the recently created ios app.
Click on the settings for ios. Then we will configure a few things.
You can manage all your apps for this project from here.
Scroll down to the “Your apps” section and you'll be able to see all your apps added to this project.
Since FCM uses APN to send notifications to Apple devices. We will need to upload the auth key (.p8) file generated from developer console to firebase. Go to this link:
https://developer.apple.com/account/resources/authkeys/list
Click on plus icon and give key name and select the APNS option then click on continue.
Now you will see Register button and simply click on it
Now you’ll need to download this key by clicking on the Download button. Make sure you save the file and have a backup somewhere since you won’t be able to download again.
Now we can go back to firebase project settings. You can add your team id also.
After adding team id now we can upload our .p8 file to the cloud messaging section. Click on the Cloud Messaging tab and scroll down to apple app configuration.
Click on Upload.
Now you can upload your .p8 file either by dragging file to that section or Clicking on Browse button
Now to get the Key Id you’ll need to go back to the keys section. https://developer.apple.com/account/resources/authkeys/list
After Clicking on the key you generated for this firebase project you can see a screen something like this. You can see the Key Id simply copy it.
Now you can paste your key id. Then click on upload button
Now you will need to upload the GoogleService-info.plist file that we had downloaded earlier while creating the ios app. You can download again from the project's settings.Click on save and submit for app build.