是否可以使用 PayPal NVP API 检索退款详细信息,例如父交易 ID?到目前为止,我知道可以使用“GetTransactionDetails”检索“已接收”交易的详细信息,但对于退款,该方法似乎不起作用。
body = {
USER: user_id,
PWD: password,
SIGNATURE: signature,
METHOD: 'GetTransactionDetails',
TRANSACTIONID: refund_id
VERSION: 204
}
response = HTTParty.post('https://api-3t.sandbox.paypal.com/nvp', body: body).
#Parsed response:
{
"ADDRESSOWNER"=>"PayPal", "ADDRESSSTATUS"=>"None",
"TIMESTAMP"=>"2018-03-15T11:04:45Z",
"CORRELATIONID"=>"97e8f9e1e9921", "ACK"=>"Failure",
"VERSION"=>"204", "BUILD"=>"39949200", "L_ERRORCODE0"=>"10004",
"L_SHORTMESSAGE0"=>"Invalid transaction type",
"L_LONGMESSAGE0"=>"You can not get the details for this type of transaction",
"L_SEVERITYCODE0"=>"Error",
"PENDINGREASON"=>"None",
"REASONCODE"=>"None",
"L_TAXABLE0"=>"false"
}