Menu Close

How to obtain iOS certificate?

1. Login to your Apple Developer Account.
2. In the menu on the right, click on Certificates, IDs & Profiles.
3.Click on the + icon to add new certificate.
4. In the What type of certificate do you need? section, select Apple Push Notification service SSL (Sandbox & Production) and click on Continue.
5. In the next screen select the app that you want to create the certificate for and click on continue.
6. You will be given the instructions to create the CSR file on the next screen. Follow the instructions to create and download this file.
7. Click on continue and upload the CSR file that you downloaded.
8. You will then be allowed to download the certificate.
9. Double click on this certificate. This is will import the certificate to your keychain.
10. After importing, you will see the certificate as Apple push service. This option is expandable but don’t expand it. Just right click on it and click on export it. You will be asked to provide a password.
11. This generates a p12 file. Convert it to pem using the following command in your mac terminal:
openssl pkcs12 -export -in oldcert.p12 -out newcert.pem -nodes
12. This is the pem file that you will upload in APNS Tester.

How to obtain iOS app BundleID?

Click on your project name in the Project Navigator. You will find your bundle id in the general tab. See image below for reference.

How to find your iphone device token?

1. Make sure you have setup APNS correctly. Refer Apple Developer Guide for more info.
2. Open the Devices and Simulator window in xcode (Window -> Devices and Simulator).
3. Connect your device to your mac and select the device in the Devices and Simulator window. At the bottom of the window, you will see the console. This is where your device token will show up in step 5.
4. Run your application.
5. You will find the device token show up in the console as Registered for push notifications:[your device token].

How to obtain FCM token/server key?

1. Click the settings icon/cog wheel next to your project name at the top of the Firebase Console.
2. Click Project settings.
3. Click on the Cloud Messaging tab.
4. The key is right under Server Key.

How to find FCM device token?

1. Make sure you have correctly setup FCM. Refer the Firebase Guide for more information.
2. Your device token will be returned in the onNewToken method of your FirebaseMessagingService class. Refer this stackoverflow answer for details.

Is it safe to upload certificate?

Absolutely! Your certificate is deleted from the server as soon as the test is completed. Moreover, we use SSL to upload your certificate. So it is completely secure.