Refund Order
This API is used to refund the order from merchant's platform to DANA. For the easiest integration, use DANA's Libraries to implement Custom Checkout or Hosted Checkout.
application/jsonasymmetricSignature methodIn the sandbox, you can find this value in the External Division ID section at https://dashboard.dana.id/sandbox/submerchants
1. Value: Amount, including the cents
2. Currency: Currency code based on ISO
In the sandbox, you can find this value in the External Shop ID section at https://dashboard.dana.id/sandbox/submerchants
Available payment methods in Sandbox include all e-wallets and QRIS (NETWORK_PAY).
1. Value: Amount, including the cents
2. Currency: Currency code based on ISO
true / falseCheck yours here: https://dashboard.dana.id/sandbox/submerchants
If you're an aggregator: subMerchantId is mandatory subMerchantId is equal to externalDivisionId, obtained from the Create Division API or DANA Sandbox Dashboard.
If you use QRIS or have outlets/stores under you: externalStoreId is mandatory
externalStoreId can be obtained from the Create Shop API or DANA Sandbox Dashboard.
POST .../payment-gateway/v1.0/debit/refund.htm HTTP/1.2
Content-type: application/json
X-TIMESTAMP: 2020-12-23T07:44:11+07:00
X-SIGNATURE: to fill..
X-PARTNER-ID: 82150823919040624621823174737537
X-EXTERNAL-ID: 41807553358950093184162180797837
CHANNEL-ID: 95221
{
"merchantId": "00007100010926",
"originalPartnerReferenceNo": "2020102900000000000001",
"partnerRefundNo": "239850918204981205970",
"refundAmount": {
"value": "10000.00",
"currency": "IDR"
}
}
application/json1. Value: Amount, including the cents
2. Currency: Currency code based on ISO
Content-type: application/json
X-TIMESTAMP: 2020-12-23T07:44:16+07:00
{
"responseCode":"2005800",
"responseMessage":"Successful",
"originalPartnerReferenceNo":"2020102900000000000001",
"originalReferenceNo":"2020102977770000000009",
"originalExternalId":"30443786930722726463280097920912",
"refundNo":"REF993883",
"partnerRefundNo":"239850918204981205970",
"refundAmount":{
"value":"10000.00",
"currency":"IDR"
},
"refundTime":"2020-12-21T17:21:41+07:00",
"additionalInfo":{}
}
| Response | Cause | Solution |
|---|---|---|
2005800Successful | Success to be processed | Mark Refund Order process as Success |
2025800Request In Progress | Transaction is on process | Mark Refund Order process as Pending. Retry request periodically by sending same request payload |
4005800Bad Request | General request failed error | Mark Refund Order process as Failed. Retry request with proper parameter |
4005801Invalid Field Format | Invalid format for certain field | Mark Refund Order process as Failed. Retry request with proper parameter |
4005802Invalid Mandatory Field | Missing or invalid format on mandatory field | Mark Refund Order process as Failed. Retry request with proper parameter |
4015800Unauthorized. [reason] | General unauthorized error | Mark Refund Order process as Failed. Retry request with proper parameter |
4035802Exceeds Transaction Amount Limit | Exceeds transaction amount limit | Mark Refund Order process as Failed. Try to adjust the amount of money that want to be refunded |
4035805Do Not Honor | Account or user status is abnormal | Mark Refund Order process as Failed. Retry request with proper parameter or can contact to DANA to check the user/account status |
4035814Insufficient Funds | Insufficient funds of merchant’s account to refund the order | Mark Refund Order process as Failed. Retry request periodically |
4035815Transaction Not Permitted.[reason] | Transaction not permitted | Mark Refund Order process as Failed. Retry request periodically or can consult to DANA |
4045800Invalid Transaction Status | Invalid transaction status | Mark Refund Order process as Failed. Retry request periodically or can consult to DANA |
4045808Invalid Merchant | Merchant does not exist or status abnormal | Mark Refund Order process as Failed. Retry request with proper parameter |
4045812Invalid Bill/Virtual Account [Reason] | The bill is blocked/suspended/not found. Virtual account is suspend/not found | Mark Refund Order process as Failed. Retry request with proper parameter |
4045813Invalid Amount | The amount doesn't match with what supposed to | Mark Refund Order process as Failed. Retry request with proper parameter |
4045818Inconsistent Request | Inconsistent request parameter found for the same partner reference number/transaction identifier | Mark Refund Order process as Pending. Need to investigate the root cause and retry request with proper parameter |
4295800Too Many Requests | Maximum transaction limit exceeded | Mark Refund Order process as Pending. Retry request periodically by sending same request payload |
5005800General Error | General error non retry-able | Mark Refund Order process as Failed. Retry request periodically |
5005801Internal Server Error | Unknown internal server failure, please retry the process again | Mark Refund Order process as Pending. Retry request periodically by sending same request payload |
Total timeout | Total timeout, the client side does not get any responses from the server side (Can be due to network issue, server slowing down, and so on) | Do a retry maximum 3 attempts by sending same request payload, if still fails mark Refund Order process as Pending |
Unexpected response (Empty field/field does not exist/undefined response code) | The server does not produce expected responses (Can be due to hardware failure, bugs, and so on) |
|