Closed flyingsky closed 9 years ago
I have to use my own server validator, as described in this issue #68. So don't use the validator url provided in the doc, http://store.fovea.cc:1980/check-purchase or https://store.fovea.cc:1982/check-purchase. Actually it's easy to use nodejs module https://github.com/pcrawfor/iap_verifier to implement the server side check. Note you have to make sure below call:
var transaction = req.param('transaction'); var receipt = transaction.transactionReceipt; client.verifyAutoRenewReceipt(receipt, true, function(valid, msg, data) {}) // or below code for non auto renew receipt // client.verifyReceipt(receipt, true, function(valid, msg, data) {})
because the receipt from this plugin is encoded in base64.
You can find detail code here https://github.com/flyingsky/node-in-app-purchase-check
I always get this issue in verify auto-renewable subscription:
{"code":6778001,"message":"The shared secret you provided does not match the shared secret on file for your account."}
Why?