我通过spring boot应用程序与Payu进行了集成。
已经通过端点的rest模板对Payu进行了POST调用-‘https://test.payu.in/_payment'以及所有必填字段,如商家密钥、txnid、amount、productinfo、firstname、email、phone、surl、furl、hash,但是payu响应显示请求正文中缺少字段furl。
这里,散列是使用-key|txnid|amount|productinfo|firstname|email|||||||||||salt"-key|txnid|amount|productinfo|firstname|email|||||||||||salt“的MessageDigest SHA-256算法生成的
以下是控制器代码和邮递员请求的详细信息:
邮递员请求:
POST /payment/payu HTTP/1.1
Host: localhost:8080
Authorization: 3yFfqME/WIdeDKJdsdewSeDVFz3RYZMCDgWsM=
Content-Type: application/x-www-form-urlencoded
firstname=Swati&phone=9899999999&productInfo=Donation&amount=800&email=xyz@gmail.com&furl=http://localhost:8080/payment/payment-response-failure&hash=4bcb0d64d85d47ab89ab90372b14b5484451aaecf3d325df9f2c5ff54a9704d5a89bce9f69bcf80bd6854006eea070858b06d7aa9d94956223ae3ea82&key=auJL3I4R&txnId=Dev75e75f95d0b3&surl=http://localhost:8080/payment/payment-response错误描述
SORRY!We were unable to process your payment</h2>
Error Reason
Mandatory parameters which must be sent in the transaction are:
key, txnid, amount, productinfo, firstname, email, phone, surl, furl, hash
The parameters which you have actually sent in the transaction are:
key, txnid, amount, productinfo, surl, hash, firstname, email, phone 如果您的帮助,我们将更加感激!
发布于 2020-09-03 13:30:52
使用UTF-8生成url。它可以工作
https://stackoverflow.com/questions/63576183
复制相似问题