【问题标题】:amazon payfort capture operation error: "Operation not allowed : CAPTURE"amazon payfort 捕获操作错误:“不允许操作:捕获”
【发布时间】:2021-07-07 09:36:45
【问题描述】:

我已经开始使用“Amazon payfort payment service”,但我遇到了一些问题。 我正在尝试根据Api example 获取交易信息,但我总是收到错误“不允许操作:捕获” 这是我的 curl 请求:

curl -H "Content-type: application/json" -XPOST -d '{   "command": "CAPTURE",   "access_code": "Xw************",   "merchant_identifier": "51*****",   "merchant_reference": "ORDR.90342",   "amount": 350100,   "currency": "SAR",   "language": "en",   "fort_id": "169996200001495787",   "signature": "942b11d7e204d433913383ca68fa03eb0c5eca34cec6c44f8e6869d4fcea795c" }' 'https://sbpaymentservices.payfort.com/FortAPI/paymentApi'

这是服务器响应:

{"response_code":"00034","amount":"350100","signature":"650003b1b6c8243a7ef7daec851a69cb0795212a92c6acc30b283d960c521224","merchant_identifier":"51*****","access_code":"X****************","language":"en","fort_id":"169996200001495787","command":"CAPTURE","response_message":"Operation not allowed : CAPTURE","merchant_reference":"ORDR.90342","currency":"SAR","status":"00"}

【问题讨论】:

  • -XPOST 不是一个东西,你可能是指-X POST 那里。
  • -d 已经暗示了POST 请求,所以你真的不需要-X POST 开始。也不包含在他们在您引用的页面上提供的 cURL 示例中。
  • 谢谢!但我认为问题不在于请求结构

标签: php laravel curl amazon-pay payfort


【解决方案1】:

问题是购买请求,而不是捕获操作。 我将命令从PURCHASE 更改为AUTHORIZATION,现在捕获请求已成功运行。谢谢大家。

【讨论】:

    猜你喜欢
    • 2016-02-04
    • 2017-04-14
    • 1970-01-01
    • 1970-01-01
    • 2011-03-17
    • 2014-10-02
    • 1970-01-01
    • 1970-01-01
    • 2021-01-14
    相关资源
    最近更新 更多