# 2.4 Web Payment Callback Notification api

# Request URL
  • /xxx
# request method
  • POST
# request params
parameter name Is it mandatory type of data description
eventName mandatory string eventName (h5.payment.success, h5.payment.failed)
mchOrderId mandatory string Merchant mchOrderId
transactionId mandatory string PayCools Unique transaction number
amount mandatory int Amount
transactionStatus mandatory string Transaction Status: PENDING, COMPLETE, FAILED
createTime mandatory string Create Time
returnTime mandatory string Return Time
channelCode mandatory string Used for payment callback - Channel Code
remark optional string Remark
failedCode optional int Failed Code
failedMessage optional string Failed Message
sign mandatory string Sign

# sign procss refer to sign procss

# callback example
// payment success callback
{
    "eventName": "h5.payment.success",
    "amount": 5000,
    "channelCode": "GCASH_URL",
    "mchOrderId": "CCVA1653350151938813",
    "createTime": "2022-05-31 09:38:06",
    "remark": "gcash payment",
    "sign": "xxxxxxxxxxxxx",
    "returnTime": "2022-05-31 09:38:06",
    "transactionId": "C1032653961085706055",
    "transactionStatus": "COMPLETE"
}

// payment failed callback
{
    "eventName": "h5.payment.failed",
    "amount": 5000,
    "channelCode": "GCASH_URL",
    "mchOrderId": "CCVA1653350151938813",
    "createTime": "2022-05-31 09:38:06",
    "remark": "gcash payment",
    "sign": "xxxxxxxxxxxxx",
    "returnTime": "2022-05-31 09:38:06",
    "transactionId": "C1032653961085706055",
    "transactionStatus": "FAILED"
}
# response example
{
    "code":1,
    "msg":"success",
    "data":{
	}
}