Answer the question
In order to leave comments, you need to log in
Is a double call to the purchase method and the absence of a callback the norm for a test application?
In an application that has not yet passed moderation, our server method is called twice after one purchase through the game. The id of both transactions is always different, but there are always 2 of them. In this case, the first purchase is counted at the moment the purchase window is opened in classmates, the second - after pressing the green purchase button in this menu that opens.
Log example:
mi.rhapsodygames.com 217.20.145.197 - - [08/Apr/2015:16:33:29 +0300] "GET /api/new.php/v2/payment/ok?transaction_id=205456767232&sig=3d93c33547035095f9c3e17c66u32&mounta3601=30691368u32069165f9c3e17c665 =1&method=callbacks.payment&transaction_time=2015-04-08+16%3A33%3A29&product_code=19&application_key=OURAPP CODE&call_id=1428500009110 HTTP/1.0" 200 125 "-" "Jakarta Commons-HttpClient/3.1"
mi.rhapsodygames.com 217.20.145.198 - - [08/Apr/2015:16:33:30 +0300] "GET /api/new.php/v2/payment/ok?transaction_id=205456773632&sig=59c797eeeac5a698b2e3ea7f616ea2df&uid=56 callbacks.payment&transaction_time=2015-04-08+16%3A33%3A30&product_code=19&application_key=OURAPP CODE&call_id=1428500010091 HTTP/1.0" 200 125 "-" "Jakarta Commons-HttpClient/3.1"
This happens every time with any purchase.
2. Callback is not called on the client (reloading the client instead of a callback does not work either).
An example of calling classmates for Unity via api from c#:
JSshowPayment( "Product name", "Description", itemId, 1, null, null, "ok", "true" );
The documentation says that the following callback should be called: function API_callback(method, result, data), but there is no call specifically on the payment card, in other cases the callback works (for example, for postMediatopic).
Answer the question
In order to leave comments, you need to log in
I recently released a unity game for classmates.
Faced the problem of the missing callback. At the same time, classmates said that he should not come only when you click on the cross, and if you clicked on ok, then there should be a callback. But he wasn't. Therefore, I made the payment processing on the game server.
There was also a problem with the instant purchase. That is, the confirmation dialog was not shown to the user and the oki was immediately removed. This problem was solved by tp.
It makes sense to send the application for moderation and only then refine it by communicating directly with those support in the JIRA system.
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question