onMessageReceived

open override fun onMessageReceived(message: RemoteMessage)

This method is invoked from FCM SDK when a "notification" message is received while the app is in the foreground, and when a "data" message is received regardless of the app's status

Klaviyo message payload is always formatted as a "data" message to retain full control over display logic, so all Klaviyo push messages come through this method.

Parameters

message

Remote message that has been received