iOS Push Configuration

APNS Certificate :

First, you will have to create an APNS certificate and upload to the dashboard to be able to send push notifications in iOS. Follow the steps below to do that :

Adding Push Entitlement to your Project :

Once the APNS Certificate is uploaded, enable Push Entitlement in the Xcode project. For that select your app target, then go to Capabilities. Here enable the Push Notifications capability for your app as shown below :




Uninstall Tracking :

We make use of silent pushes to track uninstalls. For tracking uninstalls of all the users, enable Remote Notification background mode in-app capabilities for the same as shown below :




Push Registration :

After this you will have to register for push notification by using registerForPush method of the plugin as shown below :

//This is only for iOS
import { MoECapacitorCore } from 'capacitor-moengage-core'

AppDelegate Remote notification methods will not be called

The plugin gets all the remote notification-related callbacks, therefore you won't receive any of them in your AppDelegate. Therefore, you will have to add observers for the notifications provided by the plugin instead.

Rich Push and Templates Support:

Please refer to the Native iOS SDK docs for supporting Rich Push(images/videos/audio in the notification) and Templates in the app:

Was this article helpful?
0 out of 0 found this helpful