Payment API
- Payment API utilizes JSON data and does not provide a payment page, requiring merchants to create and manage their own payment page.
Tips
- All requests are
Post
requests, and the data format isjson
Brief description
Request URL
/v1/paypro/payInApi
Request method
- post
Way Code
wayCode | Description |
---|---|
store | convenience store |
va | Va repayment |
Header
header | required | type | description |
---|---|---|---|
merchantNo | yes | string | no |
Body
parameterName | required | type | description |
---|---|---|---|
sign | Yes | string | Except sign, initialise the remaining fields to form key1=value1key2=value2, use app secrect to do salt for md5 encryption, sign ends up being lowercase |
timestamp | Yes | long | timestamp (1715941383720) |
tradeNo | Yes | string | tradeNo (uniqueness (suggested year, month, day, hour, minute, second + random number) number) |
amount | Yes | string | Amount (Decimal not supported) |
mobile | No | string | User's mobile phone number |
No | string | ||
payer | No | string | Payer Name |
wayCode | Yes | string | collection method code |
notifyUrl | Yes | string | asynchronous callback address |
returnUrl | No | string | Checkout page jump address, remove the escape character ‘\’, refer to the format https://www.abc.com/ If not passed, jump to the default success page |
remark | No | string | Remarks, this field will be brought back as is. |
Example of request parameters
{
"sign": "0be92a962072b1786a01a2cab4891a1d",
"timestamp": "1728609257212",
"tradeNo": "test_00000008",
"amount": "300",
"mobile": "15745896325",
"email": "[email protected]",
"payer": "kevin zhang",
"notifyUrl": "https://google.com",
"returnUrl": "http://abc.com/callback_page",
"remark": "test",
"wayCode": "va"
}
Response results
parameter name | required | type | description |
---|---|---|---|
msg | Yes | string | Request result (when return success only means that the request is successful, can not do the merchant side of the logic judgement) |
code | Yes | string | Request Response Code (when the return 0000 only indicates that the request is successful, can not do the merchant side of the logic judgement), the specific error code, please go to the business error code enumeration view |
timestamp | Yes | string | trading hours |
success | Yes | string | Transaction results |
data | Yes | Object | return object |
data.tradeNo | Yes | string | Merchant Transaction Number |
data.platFormTradeNo | Yes | string | Paypro transaction number, unique |
data.status | Yes | string | The result of the request, merchants can use it as a logical processing, when the result is 0000 that the transaction is successful, 0001 that part of the payment, 0015 that processing, the other are error codes, can be treated as a failure. |
data.desc | Yes | string | misdescription |
data.remark | Yes | string | Return content of the request (brought back the way it was) |
data.paymentInfo | Yes | string | Payment information |
Successful return example
{
"msg": "success",
"code": "0000",
"timestamp": 1728609277476,
"success": true,
"data": {
"tradeNo": "test_00000008",
"payproTradeNo": "68o0uwogz7mnzutt",
"status": "0015",
"desc": "Create",
"remark": "test",
"paymentInfo": "6841800930023213210"
}
}