Skip to main content
POST
/
thb
/
collect
/
apply
THB Collection Application
curl --request POST \
  --url https://uat-interface.haipay.asia/thb/collect/apply \
  --header 'Content-Type: application/json' \
  --data '
{
  "appId": 123,
  "orderId": "<string>",
  "name": "<string>",
  "phone": "<string>",
  "email": "jsmith@example.com",
  "amount": "<string>",
  "payType": "<string>",
  "inBankCode": "<string>",
  "callBackUrl": "<string>",
  "callBackFailUrl": "<string>",
  "subject": "<string>",
  "partnerUserId": "<string>",
  "sign": "<string>",
  "notifyUrl": "<string>",
  "body": "<string>"
}
'
{
  "status": "<string>",
  "error": "<string>",
  "msg": "<string>",
  "data": {
    "orderId": "<string>",
    "orderNo": "<string>",
    "payUrl": "<string>",
    "bankNo": "<string>",
    "bankCode": "<string>",
    "qrCode": "<string>",
    "sign": "<string>"
  }
}

Secret Key & Private Key (Generate Signature)

Body

application/json
appId
integer
required

Business ID (obtained from backend, must pass the corresponding business ID according to the currency in the URL)

orderId
string
required

Merchant order number

Maximum string length: 48
name
string
required

Payee name (format: English letters with spaces allowed, 1–30 characters, "firstName middleName lastName" (middleName is optional, special characters allowed: !-))

Required string length: 1 - 30
Pattern: ^[A-Za-z\s!-]+$
phone
string
required

Real mobile number (Format: starting with 0, 10 digits total)

email
string<email>
required

Real email

amount
string
required

Transaction amount (unit: ฿, precise to two decimal places; punctuation such as “,” is prohibited)

Pattern: ^\d+\.\d{2}$
payType
string
required

Transaction type

inBankCode
string
required
callBackUrl
string<uri>
required

Redirect URL after successful payment

callBackFailUrl
string<uri>
required

Redirect URL after failed payment

subject
string
required

Payment note (transaction title, product name, payment reason)

partnerUserId
string
required

User unique identifier (e.g., userId). Used for risk control. Must be valid, otherwise transaction may be affected. Format: numbers, letters, or common symbols -~!@#$%&*()_.

Pattern: ^[A-Za-z0-9\-~!@#$%&*()_]+$
sign
string
required

Signature

notifyUrl
string<uri>

Callback URL

body
string

Detailed note

Response

200 - application/json
status
string

1: Normal, 0: Exception

error
string

Error code

msg
string

Error description

data
object

业务数据

Last modified on April 10, 2026