CommonApiVersion 1.0.0

Apply for Refund

PUThttps://pay.globepay.co/api/v1.0/gateway/partners/{partner_code}/orders/{order_id}/refunds/{refund_id}

One payment order can create more than one refund orders. Total amount of all refund orders must be less than or equal to the actual paid amount and the currency of refund order is the same as the payment order.

FieldDescription
Accept

application/json

Content-Type

application/json

Path Variable

FieldTypeDescription
partner_codeString

Required, Partner code

order_idString

Required, Partner payment order id

refund_idString

Required, Partner refund order id

JSON keys

FieldTypeDescription
feeint

Required, Refund amount. Use base unit of the currency. Total amount of all refund orders must be less than actual paid amount.

Query Params

FieldTypeDescription
timeLong

Required, UTC timestamp in milliseconds

nonce_strString

Required, Random string

signString

Required, Sign

Success 200

FieldTypeDescription
return_codeString

Execution result

result_codeString
  • WAITING: Order is being submitted to WeChat
  • CREATE_FAILED: Fail to submit to WeChat
  • SUCCESS: Submission succeeded
  • FAILED: Refund failed
  • FINISHED: Refund success(funds has already been returned to user's account)
  • CHANGE: Refund can not return to user's account. Manual operation is required
refund_idString

GlobePay Refund id

partner_refund_idString

Partner refund id

amountint

Refund amount

currencyString

Refund currency

Error Code

NameDescription
ORDER_NOT_EXIST

Payment order does not exist

ORDER_MISMATCH

Payment order is not belong to this partner

ORDER_NOT_PAID

Payment order is not paid

SYSTEMERROR

Exception inside system

INVALID_SHORT_ID

Partner code is invalid or there is no partner associated with this code

SIGN_TIMEOUT

Sign expired, the difference between time and the server time is more than 5 minutes

INVALID_SIGN

Invalid sign

PARAM_INVALID

Parameters are invalid. See return_msg for more details.

NOT_PERMITTED

Gateway payment permission has not been enabled for this partner

INVALID_CHANNEL

Channel name is not available, check the Capitalize

ERROR

NameDescription
return_code

Error Code

return_msg

Error Description

PCI DSS Compliant

Security & Compliance

  • PCI DSSPayment Card Industry Data Security Standard compliant
  • TLS 1.2+API accepts TLS 1.2 / 1.3 encrypted connections only
  • SHA-256Every API request must carry a SHA-256 signature

On this page