diff --git a/OneSignalSDK/onesignal/core/src/main/java/com/onesignal/notifications/INotification.kt b/OneSignalSDK/onesignal/core/src/main/java/com/onesignal/notifications/INotification.kt index 3b5d83b45d..973e0d95e1 100644 --- a/OneSignalSDK/onesignal/core/src/main/java/com/onesignal/notifications/INotification.kt +++ b/OneSignalSDK/onesignal/core/src/main/java/com/onesignal/notifications/INotification.kt @@ -132,6 +132,12 @@ interface INotification { */ val groupedNotifications: List? + /** + * The raw payload of the notification that can into the device. This should only be used to + * access any data that is not yet represented in a property. + */ + val rawPayload: String? + /** * Create a mutable copy of this notification. Typically used in [IRemoteNotificationReceivedHandler] * or [INotificationWillShowInForegroundHandler] to modify an incoming notification prior to it diff --git a/OneSignalSDK/onesignal/notifications/src/main/java/com/onesignal/notifications/internal/Notification.kt b/OneSignalSDK/onesignal/notifications/src/main/java/com/onesignal/notifications/internal/Notification.kt index 0fbe8d85a9..1157455b43 100644 --- a/OneSignalSDK/onesignal/notifications/src/main/java/com/onesignal/notifications/internal/Notification.kt +++ b/OneSignalSDK/onesignal/notifications/src/main/java/com/onesignal/notifications/internal/Notification.kt @@ -51,7 +51,7 @@ open class Notification : INotification { override var sentTime: Long = 0 override var ttl = 0 - var rawPayload: String? = null + override var rawPayload: String? = null constructor() {} constructor(payload: JSONObject, time: ITime) : this(null, payload, 0, time) {}