Refund Transaction - API E-Wallet (Direct Debit) SNAP
About Refund Transaction - API E-Wallet (Direct Debit) SNAP
This API uses to request the refund process from a transaction on the E-Wallet payment method with Direct Debit Host to Host Feature based on the SNAP standard.
Refund Transaction - API E-Wallet (Direct Debit) SNAP
Please request the access token firsthand before performing the authentication through the Request Access Token API - SNAP section.
Service Code | 58 |
|---|---|
API Endpoint | |
HTTP Method | POST |
Description | Request refund transaction for authentication |
Content-type | application/json |
Request Header Parameter for Refund Transaction - API E-Wallet (Direct Debit) SNAP
Parameter | Type | Length | Required | Description | Example |
|---|---|---|---|---|---|
Content-Type | String | 127 | Mandatory | Application/Json | |
Authorization | String | Variable | Mandatory | Bearer “accessToken” | |
X-TIMESTAMP | String | 25 | Mandatory | Using ISO 8601 as timestamp format. Transaction date time, in format YYYYMMDDTHH:mm:ss+07:00. Time must be in GMT+7 (Jakarta time). 2022-03-21T10:11:40+07:00. | |
X-SIGNATURE | String | Variable | Mandatory | Signature will be generated by Merchant. | |
X-PARTNER-ID | String | 20 | Mandatory | X-PARTNER-ID = CLIENT_ID | |
X-EXTERNAL-ID | String | 40 | Mandatory | Unique Reference Number (41807553358950093184) | |
CHANNEL-ID | String | 5 | Mandatory | Unique Channel Merchant Credential ID Number. Client ID + "01" = Channel ID "IONPAYTEST" + "01" = "IONPAYTEST01" | IONPAYTEST01 |
Request Body Parameter for Refund Transaction - API E-Wallet (Direct Debit) SNAP
Parameter | Type | Length | Required | Description |
|---|---|---|---|---|
merchantId | String | 10 | Mandatory | Merchant identifier that is unique per each Merchant |
subMerchantId | String | 32 | Optional | Sub Merchant ID |
originalReferenceNo | String | 40 | Mandatory | Original transaction identifier on service provider system |
originalPartnerReferenceNo | String | 40 | Mandatory | Original transaction identifier on consumer system |
partnerRefundNo | String | 40 | Mandatory | Reference number from Merchant for the refund |
refundAmount | Array of JSON Object | Variable | Mandatory | Amount of refund "refundAmount": { "value": "10000.00", "currency": "IDR" } |
value | String | 12 | Mandatory | Value |
currency | String | 3 | Mandatory | Currency |
externalStoreId | String | 32 | Optional | Unique identifier of Shop ID in Client system |
reason | String | 256 | Optional | Refund reason |
additionalInfo | JSON Object | Variable | Optional | Additional information "additionalInfo": { "refundType": "1" } |
refundType | String | 2 | Mandatory | Refund Type: 1: Full Refund 2: Partial Refund |
Response Parameter for Refund Transaction - API E-Wallet (Direct Debit) SNAP
Parameter | Type | Length | Required | Description |
|---|---|---|---|---|
responseCode | String | 7 | Mandatory | Refer to General Response Code and Message - API SNAP list |
responseMessage | String | 150 | Mandatory | Refer to General Response Code and Message - API SNAP list |
originalReferenceNo | String | 40 | Mandatory | Original transaction identifier on service provider system |
originalPartnerReferenceNo | String | 40 | Mandatory | Original transaction identifier on service provider system. Must be filled upon successful transaction. |
refundNo | String | 40 | Mandatory | Refund number identifier on service provider system reference Number |
partnerRefundNo | String | 40 | Mandatory | Reference number from Merchant for the refund |
refundAmount | Array of JSON Object | Variable | Mandatory | Amount of refund "refundAmount": { "value": "10000.00", "currency": "IDR" } |
value | String | 12 | Mandatory | Value |
currency | String | 3 | Mandatory | Currency |
refundTime | String | 25 | Mandatory | Refund time ISO-8601, in format YYYYMMDDTHH:mm:ss+07:00. Time must be in GMT+7 (Jakarta time). |
additionalInfo | JSON Object | Variable | Mandatory | Additional Information "additionalInfo": { "refundType": "1" } |
refundType | String | 2 | Mandatory | Refund Type: 1: Full Refund 2: Partial Refund |
Sample Parameter for Refund Transaction - API E-Wallet (Direct Debit) SNAP
Request Parameter
curl -X POST \
'https://dev.nicepay.co.id/nicepay/api/v1.0/debit/refund' \
-H 'Content-Type: application/json' \
-H 'Authorization: Bearer eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJzdWIiOiJJT05QQVlURVNUIiwiaXNzIjoiTklDRVBBWSIsIm5hbWUiOiJCUklOIiwiZXhwIjoiMjAyNC0wMi0xMVQwODowOTozNVoifQ==.aIybLX36dYwfFvW7dcoenXkOe2EAwIYq84ZtPuIf3K8=' \
-H 'X-TIMESTAMP: 2024-12-31T10:11:40+07:00' \
-H 'X-SIGNATURE: ufBw7R8RhW79IOiV/Hlv607M60qzAYBv8uZmbSrYb6/Thlo/FhQVP4xRyelUehoSS9o+QS6vWTKb/ygtucC+tQ==' \
-H 'X-PARTNER-ID: TNICEEW051' \
-H 'X-EXTERNAL-ID: tXid202402111402271707638101' \
-H 'CHANNEL-ID: TNICEEW05101' \
-d '{"merchantId":"00007100010926","subMerchantId":"310928924949487","originalPartnerReferenceNo":"2020102900000000000001","originalReferenceNo":"TNICEEW05105202210141451109841","partnerRefundNo":"239850918204981205970","refundAmount":{"value":"10000.00","currency":"IDR"},"externalStoreId":"124928924949487","reason":"Customer complain","additionalInfo":{"refundType":"1"}}'Response Parameter
{
"responseCode": "2005800",
"responseMessage": "Successful",
"originalPartnerReferenceNo": "2020102900000000000001",
"originalReferenceNo": "TNICEEW05105202210141451109841",
"refundNo": "REF993883",
"partnerRefundNo": "239850918204981205970",
"refundAmount": {
"value": "10000.00",
"currency": "IDR"
},
"refundTime": "2020-12-21T17:21:41+07:00",
"additionalInfo": {
"refundType": "1"
}
}