Skip to main content
Question

Android issue: Problem with sync

  • 23 January 2024
  • 1 reply
  • 31 views

Forum|alt.badge.img

Hello RC team,

We're encountering a problem on Android. When calling getCustomerInfo(), the result shows that the user doesn't have any active subscriptions. However, when attempting to subscribe, the response indicates that we are already subscribed, resulting in rejection.
Also, one user is subscribed multiple times on the same product in Dashboard even if we created unique id in configuration
Feels like, Dashboard and getCustomerInfo are not in sync.

This is the setup.
If you need some additional information, please, let me know.

 

const aplleApiKey =REVENUE_CAT_APPLE_API_KEY;

const androidApiKey = REVENUE_CAT_ANDROID_API_KEY;

const uniqueId = UNIQUE_ID

 

useEffect(() => {

   const setup = async () =>  {

 

     if (Platform.OS === "ios") {

        Purchases.configure({

          apiKey: aplleApiKey,

         appUserID: uniqueId,

       });

    } else if (Platform.OS === "android") {

     Purchases.configure({

       apiKey: androidApiKey,

       appUserID: uniqueId,

    });

}

};

setup().catch(console.log);

}, []);

 

 

function for checking user’s subscrition which is called always after configuring Purchases.
 

const checkIfUserIsSubscribed = async () => {

try {

const customerInfo = await Purchases.getCustomerInfo();

console.log("INFO", customerInfo);

 

……..rest of the code

 

} catch (error) {

console.log(error);

}

};


 

1 reply

Michael Fogel
Forum|alt.badge.img+6
  • Dedicated Contributor
  • 382 replies
  • January 25, 2024

Hey @mitar-35d34e ,

 

Can you please create a support ticket for this issue? Once you create the support ticket, we will be able to look deeper into your setup and check specifically what is happening with the user. 

 

Ticket form: https://app.revenuecat.com/settings/support

 

We look forward to helping out as much as possible! 


Reply


Cookie policy

We use cookies to enhance and personalize your experience. If you accept you agree to our full cookie policy. Learn more about our cookies.

 
Cookie settings