My question is this:
RNPurchase.configure({
apiKey: "xxxxxxxxx",
appUserID: UUID-userIdHere
});
RNPurchase.logIn(userID);
2-) Then we have deleted user in our system
RNPurchase.configure({
apiKey: "xxxxxxxxx",
appUserID: UUID-userIdHere
});
RNPurchase.logIn(userID);
Hi,
So how can we trigger TRANSFER events?
Glad to help. From our docs here,
TRANSFER | A transfer of transactions and entitlements was initiated between one App User ID(s) to another. |
One way to test it with the default transfer purchases restore behavior, would be to:
Log in with App User ID A
Make a purchase
Switch accounts / log in again on the same device as App User ID B
(with the same App/Play Store account still logged in).
Make a call to restore purchases / press the restore button.
This should trigger the TRANSFER
event, transferring transactions from A
to B
.
syncPurchases
is only invoked in the migration step right? Can we call this method in the login or register process of our application? Is it ok to do that?restorePurchases
but this logic should be attached to a button that users should interact with.
syncPurchases
is only invoked in the migration step right?
Right - there are some other edge cases here and there though depending on what needs to be done.
Can we call this method in the login or register process of our application? Is it ok to do that?
You really shouldn’t need to call it in the login or register process, but I am not familiar with your use case. For more info here you might want to submit a support ticket. You also may want to consider this part of our identification docs: https://www.revenuecat.com/docs/user-ids#how-to-only-use-custom-app-user-ids
Otherwise we should call
restorePurchases
but this logic should be attached to a button that users should interact with.But we prefer to do this automatically without pressing buttons to restore.
I see, I just know that in almost all cases calling syncPurchases
is not needed, and sometimes leads developers into other unintended edge cases where an unexpected transfer happens. Having a restore button is always recommended, because it is extremely helpful in the support process for customers who lose access to their purchases.
Enter your E-mail address. We'll send you an e-mail with instructions to reset your password.