Question

Can I determine whether a subscription is valid only based on Firestore data registered with Firebase Extension?

  • 28 April 2023
  • 1 reply
  • 143 views

Badge +4

Hello,

I'm trying to monitor the validity of subscriptions based on data in Firestore using Firebase Extension. The monitoring process is intended to be integrated into a Flutter app.

The documentation lists the following methods for verifying entitlement access: https://www.revenuecat.com/docs/firebase-integration#using-the-extension

  • Use the RevenueCat SDK
  • Use custom claims in Firebase Authentication
  • Retrieve the expires_date from the REVENUECAT_CUSTOMERS_COLLECTION document and compare it to the current date and time.

However, for the following reasons, I would like to avoid using the above methods:

  • With only the RevenueCat SDK, it is not possible to verify whether a user with the same user ID has entitlements on another device.
  • If using custom claims in Firebase Authentication, the data cannot be obtained through a stream (real-time monitoring is not possible).
  • While expires_date needs to be compared to the current date and time, on mobile apps, the current time can be changed by modifying the device time.

Is it possible to determine whether a subscription is valid only based on Firestore data without using the methods listed above?

If not possible, how can I resolve the above issues?

Thank you for your response.


1 reply

Badge

Firestore data registered with Firebase Extension can provide valuable information about a user's subscription status, it is not sufficient for determining whether a subscription is valid or not. Additional integration with a payment processor or gateway is typically required for this purpose.
 

Reply