Disclaimer: This website requires Please enable JavaScript in your browser settings for the best experience.

Dev GuideAPI Reference
Dev GuideAPI ReferenceUser GuideGitHubDev CommunityOptimizely AcademySubmit a ticketLog In
Dev Guide

Create an Apple Push Notification service key

How to create an Apple Push Notification service (APNs) key to use push notifications for the Optimizely Configured Commerce Mobile App.

To use push notifications for iOS with the Optimizely Configured Commerce Mobile App, you must create an Apple Push Notification service (APNs) key after configuring the Firebase project and its settings.

Prerequisites

  • An active Apple Developer account
  • Access to your Firebase project
  • Your iOS app added to Firebase

Generate an APNs key in Apple Developer

  1. Go to Apple Developer and sign in.
  2. Select Certificates, IDs & Profiles.
  3. Choose Keys.
  4. Click the Add (+) button to create a key.
  5. Give your key a recognizable name, such as APNs Key.
  6. Check the box for Apple Push Notifications servce (APNs).
  7. Click Continue, then Register.
  8. Copy the Key ID on the confirmation screen. You need this later.
  9. Click Download to get the .p8 file. Store this file safely; you can only download it once.

Upload the APNs key to Firebase

  1. Open the Firebase Console and select your project.
  2. Click the Settings icon next to Project Overview > Project Settings.
  3. Go to the Cloud Messaging tab.
  4. Click Upload under APNs Authentication Keyin the iOS Configuration section.
  5. Upload the .p8 file you downloaded.
  6. Enter your Key ID.
  7. Enter your Team ID (found in your Apple Developer account under Membership Details).
  8. Click Upload to confirm.
  9. Click Publish to apply changes.

Troubleshoot

  • Ensure you selected Sandbox and Production when you created the APN key.
  • Copy the Team ID manually from your Apple Developer account if Firebase does not auto-detect it.