Skip to content

Refund Inquiry

Request URL

HTTP
https://{{gateway_domain}}/pg/v2/refund/query

Request Parameters

HTTP Method

POST

HTTP Header

FieldData TypeLength LimitRequiredDescription
Content-TypeStringN/AYESThis field value only supports application/json.
AcceptStringN/AYESThis field value only supports application/json.
AuthorizationStringYESAuthorization: {type} {credentials}, refer to the Signature specification

HTTP Body

FieldData TypeLength LimitRequiredDescription
merchantRefundNoString50NOMerchant refund order number. Choose one with refundNo, both cannot be null
refundNoString32NORefund transaction number. Choose one with merchantRefundNo

Parameter notes

merchantRefundNo and refundNo cannot both be empty. Provide at least one to query the refund info.

Response Data

HTTP Header

FieldData TypeRequiredDescription
Content-TypeStringYESThis field value only supports application/json.
AuthorizationStringYESAuthorization: {type} {credentials}, refer to the Signature specification

HTTP Body

FieldData TypeRequiredDescription
codeStringYESResponse status code
errorMessageStringNOError message
dataJSON ObjectNOResponse data

Description of data field

FieldData TypeRequiredDescription
refundNoStringYESRefund platform transaction number
disputeNoStringNODispute number if it is a dispute refund
paymentNoStringYESPayment platform transaction number
merchantRefundNoStringYESMerchant refund order number
bankRefundNoStringNOBank refund number
rrnStringNOChannel retrieval reference number
statusStringYESRefund status
refundSourceStringYESRefund source
refundAmountStringYESRefund amount
currencyStringYESRefund currency
createdTimeStringYESRefund creation time

Examples

Request example 1: Query by merchant refund order number

HTTP
curl https://{{gateway_domain}}/pg/v2/refund/query \
  -X POST \
  -H "Accept: application/json" \
  -H "Content-Type: application/json" \
  -H 'Authorization: V2_SHA256 appId=1111b620f93b48c5904210ff47bb1111,sign=9e494e8a91bcdd08f18ad5b2cfdbfd5654f5c00c89f8216eebd7c1637b6ce01b,timestamp=1714128828114,nonce=C7CA27DC6D55DA935DFC8450C721CC99' \
  -d '{
  "merchantRefundNo": "REFUND-001"
}'

Request example 2: Query by platform refund transaction number

HTTP
curl https://{{gateway_domain}}/pg/v2/refund/query \
  -X POST \
  -H "Accept: application/json" \
  -H "Content-Type: application/json" \
  -H 'Authorization: V2_SHA256 appId=1111b620f93b48c5904210ff47bb1111,sign=9e494e8a91bcdd08f18ad5b2cfdbfd5654f5c00c89f8216eebd7c1637b6ce01b,timestamp=1714128828114,nonce=C7CA27DC6D55DA935DFC8450C721CC99' \
  -d '{
  "refundNo": "20240423220624300800001097000004"
}'

Response

HTTP
HTTP/1.1 200 OK
Content-Type: application/json
Server: nginx/1.18.0
Date: Mon, 06 Mar 2024 12:00:00 GMT
Authorization: V2_SHA256 appId=1111b620f93b48c5904210ff47bb1111,sign=ac6ae72f8c46f5c2092c3dab9bb0e08b6cdb6d5e7ff8ad190499a8955d57f297,timestamp=1714128245401,nonce=28FA11BF8FD1309767551B4FD8A57BD5

{
    "code": "OK",
    "errorMessage": null,
    "data": {
        "refundNo": "20240423220624300800001097000005",
        "disputeNo": null,
        "paymentNo": "20240423220624300800001097000004",
        "merchantRefundNo": "REFUND-001",
        "bankRefundNo": "BK20240423001",
        "rrn": "123456789012",
        "status": "REFUNDING",
        "refundSource": "DEFAULT",
        "refundAmount": "50.00",
        "currency": "INR",
        "createdTime": "2024-04-23T22:10:45+08:00"
    }
}

Refund Status

StatusDescription
REFUNDINGRefunding
SUCCEEDRefund succeeded
FAILEDRefund failed
CANCELLEDRefund cancelled
REVERSEDRefund reversed/adjusted

Refund Source

SourceDescription
DEFAULTDefault refund
DISPUTEDispute refund
MERCHANTMerchant refund
PLATFORMPlatform refund