TarsPay_EN
  1. deposit
TarsPay_EN
Philippines🇵🇭
  • Indonesia🇮🇩
  • India🇮🇳
  • Thailand🇹🇭
  • Philippines🇵🇭
  • Malaysia🇲🇾
  • Vietnam🇻🇳
  • Egypt🇪🇬
  • Bangladesh🇧🇩
  • Kenya🇰🇪
  • Pakistan🇵🇰
  • Brazil🇧🇷
  • Mexico🇲🇽
  • Ban_TEST
  • Access Guide
  • Attachment Code Table
  • Core Business Process Description
  • deposit
    • Create a deposit order
      POST
    • Query deposit order status
      POST
  • withdraw
    • Create withdraw order
      POST
    • Query withdraw order
      POST
  • account
    • Query balance
      POST
  • CallBack
    • Callback notification interface (customized by the merchant)
      POST
  1. deposit

Create a deposit order

POST
/api/pay/unifiedOrder

deposit method#

CodeDescription
BANKBANK
QRAggregate scan code payment, support banks, wallets and other APPs

Limit information#

deposit amount rules
deposit channelMinimum single transactionMaximum single transaction
BANK10050,000
QR10050,000

Request

Header Params
X-API-KEY
string 
required
The public key applied by the merchant backend
Example:
02106af2a085fbfc6d1bb49f485205fcdfcc79a4ddb1913c72a271fedd24c2d7fe
X-API-NONCE
string 
required
System timestamp accurate to milliseconds
Example:
1702279880267
X-API-SIGNATURE
string 
required
signature
Example:
304502207a4a88a5b0def29b9dbbf8563112d090c0e0b793ff6a5c57fe9d4fd1254d8ecf022100ff63c279f5926069fa1d161598e8d3249cb90e9d728e88e514352cdae6feff72
Body Params application/json
amount
string 
Amount (in RMB)
required
body
string  | null 
Product description
optional
currency
string 
Currency
required
Fixed PHP
customerContact
string  | null 
User's mobile phone
optional
When the payment method wayCode is QR, this item is required. The format is a 10-digit mobile phone number starting with 9
customerEmail
string  | null 
User's email
optional
When the payment method wayCode is QR, this item is required
customerName
string  | null 
Username
optional
mchNo
string 
Merchant number
required
Merchant number assigned by us starting with M
mchOrderNo
string 
Merchant order number
required
notifyUrl
string 
Result notification address
required
returnUrl
string  | null 
Cashier return page
optional
subject
string  | null 
Product title
optional
wayCode
string 
Payment method code
required
CASHIER-Cashier Mode Non-CASHIER-Reference Collection Method Code, mostly used for your own cashier
Example
{
    "amount": "string",
    "body": "string",
    "currency": "string",
    "customerContact": "string",
    "customerEmail": "string",
    "customerName": "string",
    "mchNo": "string",
    "mchOrderNo": "string",
    "notifyUrl": "string",
    "returnUrl": "string",
    "subject": "string",
    "wayCode": "string"
}

Request samples

Shell
JavaScript
Java
Swift
Go
PHP
Python
HTTP
C
C#
Objective-C
Ruby
OCaml
Dart
R
Request Request Example
Shell
JavaScript
Java
Swift
curl --location --request POST '/api/pay/unifiedOrder' \
--header 'X-API-KEY: 02106af2a085fbfc6d1bb49f485205fcdfcc79a4ddb1913c72a271fedd24c2d7fe' \
--header 'X-API-NONCE: 1702279880267' \
--header 'X-API-SIGNATURE: 304502207a4a88a5b0def29b9dbbf8563112d090c0e0b793ff6a5c57fe9d4fd1254d8ecf022100ff63c279f5926069fa1d161598e8d3249cb90e9d728e88e514352cdae6feff72' \
--header 'Content-Type: application/json' \
--data-raw '{
    "amount": "string",
    "body": "string",
    "currency": "string",
    "customerContact": "string",
    "customerEmail": "string",
    "customerName": "string",
    "mchNo": "string",
    "mchOrderNo": "string",
    "notifyUrl": "string",
    "returnUrl": "string",
    "subject": "string",
    "wayCode": "string"
}'

Responses

🟢200成功
application/json
Body
code
integer 
Response Code
required
0 - Success, Non - 0 - Failure
data
object 
Response Data
required
amount
string 
Order Amount
required
body
string 
Product Description
required
countryCode
string 
Country Code
required
currency
string 
Currency
required
Fixed as THA
customerContact
string 
User Phone Number
required
mchOrderNo
string 
Merchant Order Number
required
orderState
integer 
Order Status
required
payDataType
string 
Payment Mode
required
payurl - Cashier Desk; Non - payurl - Merchant Self - built Cashier Desk
payData
string 
Payment Data
required
When using the merchant self - built cashier desk, it returns VA code, e - wallet jump link, QR image link. The merchant can determine how to process this field according to the collected code of the order
payOrderId
string 
Payment Platform Order Number
required
payUrl
string 
Cashier Desk Address
required
In cashier desk order mode, return this link to the front - end
payWays
object 
required
subject
string 
Product Title
required
msg
string 
Response Description
required
sign
string 
required
Examples
{
    "code": 0,
    "data": {
        "amount": "220",
        "body": "Test",
        "countryCode": "ph",
        "currency": "PHP",
        "customerContact": "9131167098",
        "mchOrderNo": "FLB3420230300963",
        "orderState": 0,
        "payDataType": "payurl",
        "payOrderId": "P1850124580235935746",
        "payUrl": "https://checkout.tarspay.com/#/order/ph/P1850124580235935746",
        "payWays": {
            "bank": [
                {
                    "countryCode": "ph",
                    "createdAt": 0,
                    "id": 109,
                    "payWay": "BANK",
                    "payWayLogo": "https://tarspay.oss-ap-southeast-1.aliyuncs.com/tarspay_v_1.0/6b238f2a-7336-4b08-98d9-1ccc481b2c79.png",
                    "payWayType": "bank",
                    "skipMode": 2,
                    "state": 1,
                    "updatedAt": 0
                }
            ],
            "qr": [
                {
                    "countryCode": "ph",
                    "createdAt": 0,
                    "id": 110,
                    "payWay": "QR",
                    "payWayLogo": "https://tarspay.oss-ap-southeast-1.aliyuncs.com/tarspay_v_1.0/e982e724-e368-4f4c-83a5-4cdecb6da7eb.png",
                    "payWayType": "qr",
                    "skipMode": 1,
                    "state": 1,
                    "updatedAt": 0
                }
            ]
        },
        "requestUrl": "https://merchant-test.tarspay.com/#/",
        "subject": "buycar"
    },
    "msg": "SUCCESS",
    "sign": "3045022025589697e011007a0ffeb93243aa9bee690b59e77d0e223ec827ae51093f0514022100e147d5f7d2013077167dd1a507cd6577f63e71e8893f618802299f898572bb11"
}
Previous
Core Business Process Description
Next
Query deposit order status
Built with