PaymentPage API
Tips
- All requests are
Post
requests, and the data format isjson
Brief Description
- Collection payment method
Request URL
/v1/payproPK/payin
Request Method
- POST
Header
Parameter Name | Required | Type | Description |
---|---|---|---|
merchantNo | Yes | string | None |
Body
Parameter Name | Required | Type | Description |
---|---|---|---|
tradeNo | Yes | string | Transaction number (should be unique; recommended format: YYYYMMDDHHMMSS + random number) |
amount | Yes | string | Amount (no decimals allowed, minimum amount is 100 PKR) |
name | Yes | string | Payer's name |
customerCert | Yes | string | Payer's identification number (CNIC - 13 digits - format XXXXXYYYYYYZ) with strong validation |
Yes | string | Payer's email (should use gmail.com domain, e.g., [email protected]) | |
mobile | Yes | string | Payer's mobile number (10-digit number starting with 3) with strong validation |
remark | Yes | string | Remarks; this field will be returned as is |
timestamp | Yes | string | Timestamp (e.g., 1715941383720) |
custId | No | string | Customer ID (required when the collection amount exceeds 50,000). It is recommended to use a complex string to represent the user ID, e.g., m2hkCRuTCK5HKpEkA0ok. Note: For large amounts, the same customer ID with the same amount can only appear once within one hour. |
paymentType | No | string | Payment type. Optional values: easypaisa, jazzcash. |
sign | Yes | string | Except for sign , the remaining fields should be sorted by the first letter to form key1=value1key2=value2 , and then use the app secret as salt to perform MD5 encryption. The final sign should be in lowercase. |
notifyUrl | Yes | string | Asynchronous callback URL |
returnUrl | No | string | Cash register page redirect URL; remove escape characters “\”, reference format: https://www.abc.com/. If not provided, the system will redirect to the default success page. |
Example of Request Parameters
{
"returnUrl": "https://example.com/return",
"amount": "10000",
"tradeNo": "order45692193212we3111",
"notifyUrl": "https://example.com/notify",
"name": "John Doe",
"customerCert": "1730123456789",
"email": "[email protected]",
"mobile": "3115112345",
"remark": "Payment for order #456",
"custId": "m2hkCRuTCK5HKpEkA0ok",
"timestamp": "1730431256223",
"sign": "5b161d2dc6f09a061953bf9e062fcbf1"
}
Response Result
Parameter Name | Required | Type | Description |
---|---|---|---|
msg | Yes | string | Request result (when returning "success", it only indicates that this request was successful; it should not be used for merchant-side logic judgment) |
code | Yes | string | Request response code (when returning "0000", it only indicates that this request was successful; it should not be used for merchant-side logic judgment). For specific error codes, please refer to the business error code enumeration. |
timestamp | Yes | string | Transaction time |
success | Yes | string | Transaction result |
data | Yes | Object | Returned object |
data.platFormTradeNo | Yes | string | paypro transaction number, unique |
data.status | Yes | string | Request result; merchants can use it for logical processing. When the result is "0000", it indicates that the transaction is successful; "0015" indicates processing; all others are error codes and can be treated as failures. |
data.desc | Yes | string | Error description |
data.remark | Yes | string | Content returned from the request (returned as is) |
data.paymentLink | Yes | string | Payment link, i.e., the cash register |
Example of Successful Return
{
"msg": "success",
"code": "0000",
"data": {
"platFormTradeNo": "2kvziksxbvxg062d",
"remark": "Payment for order #456",
"paymentLink": "https://casher.pk.paypro.tech/A7-HinFioAA",
"status": "0015",
"desc": "CREATED"
},
"success": true,
"timestamp": 1731653732177
}