我的交易似乎完成了客户端,但订单不会出现在Sandbox的管理中(wallet-web.sandbox.google.com/manage) - >交易页面。然而,测试买家帐户会收到确认电子邮件。
我根据文档发送所有内容,返回200 OK并打印订单ID。任何建议将不胜感激!
require_once('JWT.php'); // including luciferous jwt library
require_once('seller_info.php'); // include seller info
$sellerSecret = SellerInfo::$secretKey;
// From: http://stackoverflow.com/a/11225015/270712
$response = isset($HTTP_RAW_POST_DATA) ?
$HTTP_RAW_POST_DATA : file_get_contents("php://input");
$response = substr_replace($response, "", 0, 4);
$response = JWT::decode($response, $sellerSecret);
print_r($response->response->orderId);
header("HTTP/1.0 200 OK");