Links

Using Carousel/Slider and Thumbnail Push

Beta SDK is currently in the production phase and will be released soon. We are working diligently to finalize it and make it available for you to use.
  1. 1.
    Create a new Notification Content Extension to your application. In order to do that, follow these steps:
  • On Xcode click File -> New -> Target and choose Notification Content Extension.
  • New class named NotificationViewController will be created. It should be extended from NetmeraNotificationContentExtension class.
Your NotificationContent class should look like the following:
import UserNotifications
import UserNotificationsUI
import NetmeraNotificationContentExtension
class NotificationViewController: NotificationContentExtension {
override func viewDidLoad() {
super.viewDidLoad()
}
override func didReceive(_ notification: UNNotification) {
super.didReceive(notification)
}
}
  • If you want to add slide to Carousel property, UserInteractionEnabled must be added.
  • After that enable App Groups from the Capabilities for both of your application and NotificationContent extension.
  • Add "bundle_identifier.group_name" to your app groups.
  • Ensure you added the app groups to your app, you should provide in Netmera.start() in your app group name in app delegate method where you set Netmera.start() method as the following:
import UserNotifications
import UserNotificationsUI
import NetmeraNotificationContentExtension
class NotificationViewController: NotificationContentExtension {
override func viewDidLoad() {
super.viewDidLoad()
}
override func didReceive(_ notification: UNNotification) {
super.didReceive(notification)
}
}
  1. 2.
    In your pod file, you should add NetmeraNotificationContentExtension and install to your extension target like this.
pod "NetmeraNotificationContentExtension"
Default label in MainInterface should be deleted.
If you want to allow your application to receive http media contents:
  • Click Info.plist under NotificationService Extension
  • Add App Transport Security Settings
  • Under App Transport Security Settings add Allow Arbitrary Loads and set it YES.