Closed abdulahad96 closed 3 years ago
Hey,
for recurring subscriptions it is recommended to use the real time developer notifications for android. Here are the docs:
https://developer.android.com/google/play/billing/rtdn-reference
I am not sure if this packages listener is supposed to be triggered with recurring purchases too.
I need a functionality that realize my app that subscription renewed and i can reward user after hit an api. your solution can create problem when i neglected push notification. please help me
With the Real Time Developer Notifications you can directly hit your API (Google Pub/Sub) and give or extend the users reward based on the notification you receive. It should help you to keep track or a users subscription (cancelled, renewed, ...).
I am not sure what you mean by that: "your solution can create problem when i neglected push notification"
is your solution give notify to my app when renewal occurred when app is not open and then later i open app so is it still notify me?
The RT Developer Notifications are supposed to notify your backend where you keep track of a users subscription status (e.g. a renewal). I assume your app communicates to your backend on startup anyways where you can then pass this information: e.g. subscription is active or subscription has been renewed. This is independent of whether the app is open during renewal or not.
Hey there, it looks like there has been no activity on this issue recently. Has the issue been fixed, or does it still require the community's attention? This issue may be closed if no further activity occurs. You may also label this issue as "For Discussion" or "Good first issue" and I will leave it open. Thank you for your contributions.
Looks like it's been answered, if more info please reopen
Version of react-native-iap
^4.4.0
Version of react-native
0.61.3
Platforms you faced the error (IOS or Android or both?)
Android
Expected behavior
when subscription renew listener occurr
Actual behavior
no updatepurchase listener occur
Tested environment (Emulator? Real Device?)
real device
Steps to reproduce the behavior
await RNIap.requestSubscription(productID) this.purchaseUpdateSubscription = purchaseUpdatedListener(purchase => { const res = await api.IAPTransactionvalidate(Purchase); await RNIap.finishTransaction(purchase); }); please help me about this concern