Question

RevenueCat-Firebase Integration for Cordova based app

  • 12 December 2023
  • 2 replies
  • 34 views

Badge +4

Hello RevenueCat Community,

I'm reaching out for assistance with an issue we're encountering in the integration of RevenueCat and Firebase within our Cordova app, which operates on both iOS and Android platforms.

We have set up accounts on Firebase, Google Analytics, and RevenueCat. The integration process has been initiated in RevenueCat, and we have successfully installed the Firebase Cordova plugin as well as the RevenueCat Firebase extension. Despite this, we're facing a challenge: purchase events tracked by RevenueCat are not appearing in our Firebase analytics.

Has anyone else encountered a similar issue? Any insights or guidance on how to ensure that these purchase events are properly communicated and logged in Firebase would be greatly appreciated. We are looking for any advice or best practices to troubleshoot this problem.

Thank you in advance for your help!

 


2 replies

Userlevel 4
Badge +6

Hi @Boris Brite,

The most typical reason that events would not be appearing in Firebase is due to the Firebase user identity not being set correctly - you should be using the Firebase UID as the app user ID, like in this example: https://www.revenuecat.com/docs/firebase-integration#2-set-firebase-user-identity-in-revenuecat

Does this flow seem to be working in your app?

Badge +4

Hi Kaitlin,

Thank you for your response regarding the integration issue we're facing with RevenueCat and Firebase in our Cordova app. Your suggestion about ensuring the correct setting of the Firebase user identity makes sense.

However, our app is built on Cordova, and we primarily use JavaScript rather than Swift. Could you provide any additional guidance or best practices for setting the Firebase user identity in a JavaScript-based environment, particularly within the context of a Cordova app? Are there specific JavaScript implementations or considerations we should be aware of to ensure smooth communication between RevenueCat and Firebase?

 

Thanks again for your help!

 

Reply