0

此问题仅在发布版本变体中出现。它不会发生在应用程序的调试变体中

在发布版本变体中,onPaymentError() 始终被调用,即使在成功扣除付款金额之后也是如此。

在调查 onPaymentError() 中的参数时,从 Razorpay 收到以下响应。

onPaymentError() 中的响应:

{
  "code": "BAD_REQUEST_ERROR",
  "description": "Your payment has been declined as the order is invalid. To pay successfully try initiating the payment again from merchant checkout.",
  "source": "business",
  "step": "Payment_initiation",
  "reason": "input_validation_failed",
  "metadata": {
    "order_id": "order_IPoe3Oyg1mTW"
  }
}

我还检查了结帐选项。它们如下:

{
  "name": "AAAA ZZZZ",
  "description": "Bill Payment 404",
  "order_id": "order_IPoe3Oyg1mTW",
  "allow_rotation": true,
  "currency": "INR",
  "amount": 100,
  "prefill": {
    "email": "hhhh@gmail.com",
    "contact": "901xxxxxxx"
  },
  "method": {
    "netbanking": false,
    "card": false,
    "wallet": false,
    "upi": true
  },
  "readonly": {
    "email": 1,
    "contact": 1
  },
  "notes": {
    "unitName": "404",
    "unitOwnerName": "VxxxKsxxx"
  }
}

Razorpay SDK 版本:

def razorpayVersion = '1.6.15'
implementation 'com.razorpay:checkout:' + razorpayVersion

还应用了 Proguard 规则:

-dontwarn com.razorpay.**
-keep class com.razorpay.** {*;}

-keepclasseswithmembers class * {
  public void onPayment*(...);
}

-dontwarn ex.com.axpayment_library.**
-keep class ex.com.axpayment_library.** {*;}

-dontwarn ex.com.axnetwork_library.**
-keep class ex.com.axnetwork_library.** {*;}

-dontwarn co.annex.app.**
-keep class co.annex.app.** {*;}

-optimizations !method/inlining/*
4

0 回答 0