Push Handled by Application
info

SDK Version

All the below functions are supported from SDK version 9.13.0

Track Notification Received

Call SDK's logNotificationReceived(withPayload: )  function to track notification received impression as shown below.

Swift Objective-C
MoEngageSDKMessaging.sharedInstance.logNotificationReceived(withPayload:notification.request.content.userInfo)

Track Notification Click

Call SDK's logNotificationClicked(withPayload: )  function to track notification clicked event as shown below.

Swift Objective-C
MoEngageSDKMessaging.sharedInstance.logNotificationClicked(withPayload: notification.request.content.userInfo)
 

Note

To use above functions, Appdelegate swizzling should be disabled. To see how to disable swizzling, please see the link.

Validate if the notification belongs to MoEngage

Call SDK's isPushFromMoEngage(withPayload:)  function to validate if the notification belongs to MoEngage as shown below.

Swift Objective-C
 let isPushFromMoEngage = MoEngageSDKMessaging.sharedInstance.isPushFromMoEngage(withPayload: notification.request.content.userInfo))

Previous

Next

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

How can we improve this article?