I have an android app that have subscriptions. I want to do some ui change when subscription expires.
if( subscription expires )
//do something
Q1) how do i handle the above in code? I'm using TrivialDrive Sample app classes for In-app. And where should i handle this check in code?
Q2) reserved key words are not working for subscription testing. Do I have to use actual credit card for testing subscriptions? My app is unpublished, product activated and apk signed.
If a user or your app has a subscription that ends, you will not get a notification. Rather, the subscription purchase will no longer be returned in the list of owned products from the getPurchases request to Google. As stated in the documentation under the "User Billing" section:
With In-app Billing Version 3, the failed or expired subscription is no longer returned when you call getPurchases.
If you are using the IabHelper from the TrivialDrive example, this means that the mPurchaseMap in the Inventory object returned in your IabHelper.QueryInventoryFinishedListener will not contain a product for the expired subscription.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With