Skip to content

Create Payout Order

HTTP Request

TIP

POST baseUrl + /api/payOut

Request Headers

HeaderNameRequiredValue
Content-TypeYapplication/json
MerchantIdYMerchantId
SignYSign

RequestBody

ParameterRequiredTypeExampleDescription
accountNameYstring(32)BrandmeBeneficiary Name
accountNoYstring(32)646180000000000007Beneficiary Account
accountTypeYintpls refer toPayout Account TypeBeneficiary Account Type
currencyYstring(32)COPCurrency code
amountYdecimal(20,2)10000Amount 10000-5000000
bankIdYintpls refer topayout-bank-list-queryBank id )
mchOrderNoYstring(32)P123456Merchant order number
notifyUrlYstring(250)http://abc.com/webhooks (callback) address
nonceStrYstring(32)16283812xxxxRandom string
idTypeYstring(32)pls refer toPayout Payee ID TypePayout Payee ID Type
idCardYstring(32)Beneficiary ID number
phoneNstring(32)+52xxxxxxxBeneficiary phonenumber
emailNstring(32)xyz@gamil.comBeneficiary email
remarkYstring(32)remarkOrder remarks

TIP

Note that callback/webhook addresses only support https or http protocol addresses. If the address is an ip address, be sure to use a public domain name.

TIP

关于idType字段,请以收款银行账户开设时使用的实际证件类型为准,不一致会导致代付失败。

举例:如果用户开户使用的是NIT证件,发起代付是透传的证件类型为CC, 此时会导致代付失败。

ResponseBody

Parameter类型Description
merchantIdintMerchantId
mchOrderNostring(32)Merchant order number
orderNostring(32)Platform order number
amountdecimal(20,2)Amount
feedecimal(20,2)fee
orderStatusstring订单状态,pls refer toPayout Order Status Enum
json
{
  "msg": "SUCCESS",
  "code": 200,
  "data": {
    "merchantId": "100001",
    "mchOrderNo": "M1656907083234",
    "orderNo": "PAYOUT8232147367892025344",
    "amount": 100,
    "fee": 0,
    "orderStatus": "PROCESSING"
  }
}

Query Payout Order

HTTP Request

TIP

POST baseUrl + /api/payOutQuery

Request Headers

HeaderNameRequiredValue
Content-TypeYapplication/json
MerchantIdYMerchantId
SignYSign

RequestBody

ParameterRequiredTypeExampleDescription
mchOrderNoNstring(32)P123456Merchant order number
orderNoNstring(32)PAYIN12345Platform order number
nonceStrYstring(32)1628381288000Random string

TIP

We recommend using orderNo (platform order number) first. At least one of the platform order number and merchant order number needs to be passed.

ResponseBody

json
{
  "msg": "SUCCESS",
  "code": 200,
  "data": {
    "merchantId": "100001",
    "mchOrderNo": "M1656756338536",
    "orderNo": "PAYOUT8231515112790892544",
    "amount": 100.0,
    "fee": null,
    "orderStatus": "PAYING",
    "completionTime": null,
    "resultDesc": "SUCCESS"
  }
}
ParameterTypeDescription
merchantIdintMerchantId
mchOrderNostring(32)Merchant order number
orderNostring(32)Platform order number
channelOrderNostring(32)Channel order number
amountdecimal(20,2)Amount
feedecimal(20,2)fee
orderStatusstring(32)Order Statuspls refer toPayout Order Status Enum
completionTimedateCompletion time yyyy-MM-dd HH:mm:ss
resultDescstring(64)Order Status,pls refer toOrder Status Description

Async Webhook Notification

HTTP Request

TIP

POST : notifyUrlnotifyUrlis provided by the merchant

Request Headers

HeaderNameRequiredValue
Content-TypeYapplication/json
MerchantIdYMerchantId
SignYSign

Webhook RequestBody

json
{
  "orderStatus": "SUCCESS",
  "amount": 100.0,
  "fee": 0,
  "mchOrderNo": "2a6421c4-3758-4d1a-b47e-f7d0e7133f9e",
  "merchantId": "100001",
  "orderNo": "PAYOUT8388679728902370944",
  "completionTime": "2022-08-08 08:08:08",
  "resultDesc": "SUCCESS"
}
ParameterTypeDescription
merchantIdintMerchantId
mchOrderNostring(32)Merchant order number
orderNostring(32)Platform order number
channelOrderNostring(32)Channel order number
amountdecimal(20,2)Amount
feedecimal(20,4)fee
orderStatusstring(32)pls refer toPayout Order Status
resultDescstring(64)pls refer toOrder Status Description
completionTimedateComplete time

TIP

fee and completionTime only have a value if the order is successfully paid.

TIP

Please respond with SUCCESS if the process is successful. For other responses, we will consider the callback to have failed. After the callback fails, it will be retried in 1, 2, 4, 8, 16, 32, 64, 128, 256, 512 minutes, and the callback will be retried 10 times in total.

Released under the MIT License.