WalletKit.registerDeviceToken
. This token can be obtained from either FCM or APNS, depending on the platform used.
This method enables wallets to receive push notifications from WalletConnect’s Push Server via Firebase Cloud Messaging. This means you will have to setup your project with Firebase before being able to call registerDeviceToken()
method.
To register a wallet to receive WalletConnect push notifications, call WalletKit.registerDeviceToken
and pass the Firebase Access Token.
PushMessagingService
is a wrapper around the FirebaseMessagingService
. The PushMessagingService
class needs to be implemented for WalletKit to be able to decrypt and notify wallets of a push notification sent from the Dapp in the background. This service also needs to be registered in the AndroidManifest.xml
file similar to the example in the FCM documentation.