标签: in-app-purchase-receipt

沙箱环境返回 21003 状态代码以进行收据验证

当我使用沙箱测试应用内购买时,对沙箱 URL https://sandbox.itunes.apple.com/verifyReceipt的发布请求返回

 data: { environment: 'Sandbox', status: 21003 }
Run Code Online (Sandbox Code Playgroud)

21003状态码表示收据无法验证。https://developer.apple.com/documentation/appstorereceipts/status?language=objc

这是预期的吗?我假设我的测试收据将被视为对沙盒环境有效并返回状态 0。

testing in-app-purchase ios app-store-connect in-app-purchase-receipt

5
推荐指数
2
解决办法
9037
查看次数

应用程序购买收据数据中的 Flutter (IOS)

我使用 [应用内购买][1] 库在我使用 Flutter 开发的应用程序中进行应用内购买。进行购买时,为了在服务器端验证 Android 的应用内购买,我将发送如下数据,这些数据需要由服务器发送。

  _verifyPurchase(PurchaseDetails purchase) async {
    productID = purchase.productID;
    
    //for android it works nice
    if(Platform.isAndroid){
      orderId = purchase.billingClientPurchase.orderId;
      purchaseToken = purchase.billingClientPurchase.purchaseToken;
      purchaseVerify(orderId, purchaseToken, productID);

    //but it does not work for iOS and the data required for purchase verification does not go to the server
    }else if(Platform.isIOS){
      transactionId = purchase.skPaymentTransaction.originalTransaction;
      verifData = purchase.verificationData.serverVerificationData;
      purchaseVerify(transactionId, verifData, productID);
    }
  }

  purchaseVerify(String orderId, String purchaseToken, String productID) async {
    var data = {
      'orderId' : orderId,
      'purchaseToken' : purchaseToken, …
Run Code Online (Sandbox Code Playgroud)

ios flutter in-app-purchase-receipt

5
推荐指数
0
解决办法
1419
查看次数

不推荐使用 App Store 验证收据

App Store 验证收据何时被弃用?

\n

这什么时候会停止工作?我\xe2\x80\x99找不到任何关于此的信息吗?

\n

https://developer.apple.com/documentation/appstorereceipts/verifyreceipt

\n

buy.itunes.apple.com/verifyReceipt

\n

app-store in-app-purchase ios receipt-validation in-app-purchase-receipt

5
推荐指数
1
解决办法
4327
查看次数

Appstore服务器通知设置[接收App Store服务器通知版本2]

我正在尝试使用应用商店通知设置我的服务器。\n以便当用户退款应用内购买时我可以收到通知。\n https://developer.apple.com/documentation/appstoreservernotifications/receiving_app_store_server_notifications <- 指南我现在正在寻找。

\n
The version 2 response body, responseBodyV2, contains a signedPayload that\xe2\x80\x99s cryptographically signed by the App Store in JSON Web Signature (JWS) format. The JWS format increases security and enables you to decode and validate the signature on your server. The notification data contains transaction and subscription renewal information that the App Store signs in JWS. The App Store Server API and the StoreKit In-App Purchase API use the same JWS-signed format for transaction and subscription …
Run Code Online (Sandbox Code Playgroud)

in-app-purchase ios in-app-purchase-receipt

4
推荐指数
1
解决办法
2922
查看次数