Android Purchase subscription and introductory price

淺唱寂寞╮ 提交于 2019-12-03 02:50:48

I just found this recently at this link https://developer.android.com/google/play/billing/billing_reference.html#billing-codes

Listed in the Billing Details API Reference section, there are extra fields in the response that only appear if there is an introductory price set. introductoryPrice for example gives a string like "$9.99". You can just check if that field is set, and if it is then there is an introductory rate available, you can also get things like the introductory price period and number of cycles it applies to.

Finally i used The getPurchaseHistory() method from In-app billing. This method returns the most recent purchase made by the user for each SKU, even if that purchase is expired, canceled, or consumed.

So if the SKU isn't on this return, the intropricing is available.

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!