Refund Transaction
Info
Restores all or part of the funds from an settled transaction to the cardholder's card. If the transaction is not yet settled, please please refer to Void. Unlike Void, after a Refund there is a record of both the initial charge and the refund on the cardholder's statement.
Endpoint
https://ccapi.iotpaycloud.com/v3/cc_refund
Method
POST
Header
Content-Type: application/json;charset=UTF-8
Request
name | required | type | sample | description |
---|---|---|---|---|
mchId | y | String(30) | 10000701 | assigned by IOTPay |
mchRefundNo | y | String(30) | R1234567890abc | assigned by merchant |
loginName | y | String(12) | jack_chen | assigned by merchant,equals to jobNo |
refundAmount | y | Int | 100 | in cents |
payOrderId | y | String(30) | ||
sign | y | String(32) | C380BEC2BFD727A4B6845133519F3AD6 | Sign algorithm |
Response
name | required | type | sample | description |
---|---|---|---|---|
retCode | y | String | SUCCESS or FAIL | |
retMsg | y | String | ||
retData | y | JSON | if retCode=SUCCESS, order detailed info returned |
retData contains order information:
name | required | type | sample | description |
---|---|---|---|---|
payOrderId | y | String | RP20240101215009579871439079 | generated by IOTPay |
mchId | y | String | 10000701 | assigned by IOTPay |
mchOrderNo | y | String | R1234567890abc | represents the mchRefundNo assigned by merchant |
originalOrderId | y | String | PC20240101215009579871439079 | original pay order id for refund |
currency | y | String | CAD | only 'CAD' supported |
amount | y | Int | 100 | in cents |
payType | y | String | refund | fixed to refund for successful refund transaction |
refundable | y | Int | 0 | refund order cannot be refunded further (original order can still be refunded if funds are still available) |
status | y | Int | 0,1,2,9 | 0 = pending order, 1 = unknown, 2 = success, 9 = fail |
paySuccTime | y | String | 2021-04-07 19:44:51 | time stamp for the moment when the payment succeeded |
cardNum | y | String | 432567******2266 | card number of the card used for the transaction |
expiryDate | y | String | 0725 | expiry date of the card used for the transaction |
invoiceNum | y | String | ||
authNum | y | String | ||
transNum | y | String | ||
channel | y | String | PF_CC | PF_CC or UPI_EX |