Solved

await Purchases.syncPurchases(); does not work for other device

  • 20 October 2022
  • 1 reply
  • 113 views

Badge +3

Device A

- Logged in Google play account (Aplaystoreaccount@gmail.com)
- Logged in APP ID (Aappid@gmail.com)

Device B

- Logged in Google play account (Bplaystoreaccount@gmail.com)
- Logged in APP ID (Aappid@gmail.com)

 

 I saw this "await Purchases.syncPurchases();" on the docs and I used it after the subscription renewed, but this method just worked with Device A, I call this method with Device A this it gets the purchase info on google play and then renewing the subscription on Revenuecat.
When i call this method "await Purchases.syncPurchases();" with Device B nothing happened, because the entitlement is not active.

Why Device A worked perfect but Device B not worked this method "await Purchases.syncPurchases();"?

icon

Best answer by cody 21 October 2022, 02:37

View original

1 reply

Userlevel 6
Badge +8

Hey @Elif Yücel,

Restoring/syncing purchases takes the purchases from the underlying store account (the Google Play account) and syncs it to the app user ID. It would be expected that Bplaystoreaccount couldn’t restore purchases from Aplaystoreaccount.

 

In that case, you wouldn’t need to restore, just identifying Device B with the same app user ID as Device A would unlock those entitlements on Device B.

Reply