payloadFromFirebaseMessage

open fun payloadFromFirebaseMessage(@NonNull remoteMessage: RemoteMessage): BatchPushPayload

Attempt to extract the Batch Push data contained within the specified Firebase RemoteMessage. This is usually the method you want to use when reading this payload from a FirebaseMessagingService implementation, NOT from an activity intent. If you wrote an existing BatchPushPayload to a Bundle/Intent extras using writeToBundle / writeToIntentExtras, you should rather use payloadFromBundle

Return

A BatchPushPayload instance.

Parameters

remoteMessage

Firebase remote message containing Batch Push data.

Throws

Thrown if the argument doesn't contain valid Batch Push data