Java – is there any way to play in app products from the back-end server using Google?

Consuming Google play in app goods can be easily from client applications( http://developer.android.com/google/play/billing/api.html#consume )Done

However, I can't find any information about executing this consumption request from the back-end server Purchase status API( http://developer.android.com/google/play/billing/gp-purchase-status-api.html )It is intended to be used from a back - end server, but it does not provide any way to consume products within an application

Is there any way to use Google to play in app products from the back-end server?

Solution

I'm trying to implement something similar to your method In our case, our target audience is children, so we don't expect consumers to become payers. Parents may buy one for each child Therefore, the normal model (one thing per customer) does not work

Since our server actually processes licenses (for each child), any payment (which we are processing as consumables) must be performed on the application, and then the token is passed to the server for verification, and then the server updates the license. The next time a child asks for their license, they think the payment has been taken action The application must then mark them as consumed, even if activation is not directly controlled On the contrary, it seems that the only option is to manage the tables of all purchasetokens and mark them internally as consumed, so the application must regularly ask the current (Google) user whether any tokens waiting need to be consumed and check them when they do As an extension, we must complicate the payment process by checking whether we should prevent children (or Google users from paying) from continuing in case they may be waiting for payment from another child

It would be easier if Google allowed servers to tag with consumer goods, but I haven't found a solution yet I hope apiv4 has it

The content of this article comes from the network collection of netizens. It is used as a learning reference. The copyright belongs to the original author.
THE END
分享
二维码
< <上一篇
下一篇>>