Check Consumable-InAppPurchase on Android after app reinstall?
Hi, originally I wanted to implement a Playstore "Subcription" via the QtPurchase modul with Qt5.12.
Unfortunately its not possible.
The proposed hack does not work easily because all the .java files are archived in an exectubale .jar file. This means I must take the originals from
and replace "inapp" with "subs" and then create the .jar file, but how exactly?
So I decided to use "Consumable one-time products" instead. Here I have difficulties with the following usecase.
- User pay the product
- I save the timestamp via QSettings.
Everthing works fine.
- Later, he deletes the app and reinstalls it.
- Now the timestamp should be refreshed from Googles local cashed value via getBuyIntent().
Because the Google Play client now caches In-app Billing information locally on the device, you can use the In-app Billing API to query for this information more frequently.
In the QtInAppPurchase.java file
there is the function createBuyIntentSender() which calls the getBuyIntent(), but the function itself is nowhere called?
My question is now how is it possible to recover e.g. the timestamp from an "Consumable one-time products" after the app is reinstalled? Or is there a way to safely save e.g. the timestamp value somewhere outside the save app enviroment?
@PowerNow I am trying to solve Subscription issues too ... here the thread Auto-Renewable Subscription for iOS/Android.. Gathering whole information in one place right now. About your topic - I would say it's matter of storing it on server side by user_id for example. For it you might use preinstalled DB API of Amason RDS for example if you have no your own server or any other similar services, be careful!!! they are not a cheap solution like they self-adverting . The use-case looks like you getting timestamp on device -> storing it on server -> in case of reinstall requesting timestamp by user_id
Briefly what I got from my own experience of subscription it's develop it through server-side solution and provide uniqueness for user identification. How to do it on device - do not know. If you got solution - could you explain your experience?