Skip to content

Refund Notification

1. API Parameters

For details, please refer: API

>Request Parameters
ParameterTypeIf RequiredMax. LengthDescriptionExample
codeStringM32returned code,’APPLY_SUCCESS’means success
msgStringM256returned message,'Success.'
appIdStringO64merchant app id
merchantNoStringM15merchant Id
keyVersionStringM8Signature Algorithm Version, Current value: 1.0
notifyTimeStringM32Request time, compliant with rfc3339 specification, format: yyyy-MM-dd'T'HH:mm:ss.SSSXXX 2022-12-14T06:35:45.722Z or 2022-12-14T06:35:45.722+08:00
notifyTypeStringM16notify type: REFUND
+dataObjectO
「outRefundNoStringM64merchant refund order id
「refundTradeNoStringM64PayerMax refund order id.
「outTradeNoStringM64original merchant order id.
「refundAmountNumberM(20,4)The amount of the refund, the unit of the amount is yuan, and it will be returned according to the decimal point supported by the currency of each country.
「refundCurrencyStringM3refund currency
「statusStringM32Refund status:REFUND_SUCCESS, REFUND_FAILED[Refund Status](/en/doc-center/appendix/collection/refund-status)

Response Parameters

ParameterTypeIf RequiredMax. LengthDescriptionExample
codeStringM32response 'SUCCESS'
msgStringO256response 'Success'

2. Sample Code

PayerMax refund result notification

json
{
    "code": "APPLY_SUCCESS",
    "msg": "",
    "keyVersion": "1",
    "appId": "3b242b56a8b64274bcc37dac281120e3",
"merchantNo": "020213827212251",
    "notifyTime": "2022-01-17T09:33:54.540+00:00",
    "notifyType": "REFUND",
    "data": {
        "outRefundNo": "R1642411016202",
        "refundTradeNo": "20220117091657TI790000055087",
        "outTradeNo": "P1642410680681",
        "refundAmount": 10000,
        "refundCurrency": "IDR",
        "status": "REFUND_SUCCESS"
    }
}

Merchant response

json
{
    "code": "SUCCESS",
    "msg": "Success"
}

Released under the MIT License.