Standalone and journey-based in-app messages arrive on your device through different methods:
- Standalone in-app messages are returned directly in response to the
/postEventAPI call and are triggered locally on the device. - Journey-based in-app messages are sent as silent push notifications. The Pushwoosh SDK must receive this silent push to show the in-app message.
If journey-based in-app messages are not appearing on your iOS device, use these troubleshooting steps.
Enable background modes
In Xcode, go to your target's Signing & Capabilities tab, add Background Modes, and select Remote notifications.
Implement the silent push handler
Cross-platform frameworks, such as React Native, do not always link silent push notifications automatically. You must add the native handler inside your AppDelegate file:
func application(_ application: UIApplication, didReceiveRemoteNotification userInfo: [AnyHashable: Any], fetchCompletionHandler completionHandler: @escaping (UIBackgroundFetchResult) -> Void) {
Pushwoosh.configure.handlePushReceived(userInfo)
completionHandler(.noData)
}
Verify settings and SDK version
- Check that you are running iOS SDK version 7.0.14 or newer.
- Verify that
Pushwoosh_RICH_MEDIA_STYLEis set toMODAL_RICH_MEDIAin yourInfo.plistfile.
Apple Push Notification service (APNs) delivers silent push notifications on a best-effort basis. These notifications do not arrive if the user has force-closed the app or if the device is in Low Power Mode.
Comments
0 comments
Please sign in to leave a comment.