可以直接与Android Market服务器验证应用内支付的交易信息吗?
如果我有交易信息 json 字符串:
{ "nonce" : 1836535032137741465,
"orders" :
{ "notificationId" : "android.test.purchased",
"orderId" : "transactionId.android.test.purchased",
"packageName" : "com.example.dungeons",
"productId" : "android.test.purchased",
"developerPayload" : "bGoa+V7g/yqDXvKRqq+JTFn4uQZbPiQJo4pf9RzJ",
"purchaseTime" : 1290114783411,
"purchaseState" : 0
}
}
我可以将其上传到 Android Market 服务器来验证它是否有效。 就像苹果的方式一样。 http://developer.apple.com/ Library/ios/#documentation/NetworkingInternet/Conceptual/StoreKitGuide/VerifyingStoreReceipts/VerifyingStoreReceipts.html
更新: 我正在更新此内容以获取有关此主题的一些信息。
If I have the transaction information json string:
{ "nonce" : 1836535032137741465,
"orders" :
{ "notificationId" : "android.test.purchased",
"orderId" : "transactionId.android.test.purchased",
"packageName" : "com.example.dungeons",
"productId" : "android.test.purchased",
"developerPayload" : "bGoa+V7g/yqDXvKRqq+JTFn4uQZbPiQJo4pf9RzJ",
"purchaseTime" : 1290114783411,
"purchaseState" : 0
}
}
can i just upload it to Android Market server to verify if it is valid.
Just like the Apple way.
http://developer.apple.com/library/ios/#documentation/NetworkingInternet/Conceptual/StoreKitGuide/VerifyingStoreReceipts/VerifyingStoreReceipts.html
Update:
I am updating this to get some info about this topic.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)
在android中我们无法直接与Android Market服务器验证应用内计费的交易信息。
而且我认为不需要验证交易,因为它非常安全。(不像 Android 中的越狱):)。
In android we can't verify the transaction information of in-app billing with the Android Market server directly.
And I thinks there is not need to verify the transaction because it's very secure.(Nothing like jailbreak in android) :).
抱歉,您无法与 Android market 进行通信。请检查此链接,该链接还有其他问题
此
更新:
现在您可以使用新版本的 Android Play 验证订阅。检查这个。
这需要 OAuth,因为您正在请求访问 Google 信息的权限。不过,该过程有详细记录,您可以自己遵循。
Sorry you cannot communicate with android market.Check this link that has other issues as well
this
Update :
Now you can verify subscription with new versions of Android Play.Check this.
This needs OAuth since you are requesting permission to access information from Google. However the process is well documented and you can follow it yourself.