Create a payout order
POST /api/v1/payout/orders
Create a payout order. ST Pay pays the specified payee from your balance.
- When the order is created, ST Pay checks that available balance ≥ payout amount + fee. If the balance is insufficient,
insufficient_balanceis returned and no order is created. - Creating an order does not freeze or reserve your balance. The amount is deducted only when ST Pay actually pays out, and the balance is checked again at that time. If you create multiple payout orders at the same time, their combined amount may exceed your balance; any order for which the balance is insufficient at payout time remains pending and may be rejected.
- The fee rate is locked in at the moment the order is created, and later rate changes do not affect the order. The order creation response does not include the fee; after the payout, you can get it from the Callback or an order query.
Request fields
| Field | Required | Format | Description |
|---|---|---|---|
api_identity | Yes | String | The API identity issued by ST Pay |
merchant_order_no | Yes | 1–200 characters; English letters, digits, _, - | Your order number. It must be unique among your payout orders; collection orders and payout orders are counted separately |
amount | Yes | Amount string | The payout amount, which is also the basis for calculating the fee |
channel_type | Yes | fps or bank_transfer | Channel type |
account_no | Yes | Depends on the channel; see Payee account format | Payee account number |
account_name | Yes | 1–200 characters | Payee's name or account name |
bank_name | Required for bank transfer | 1–100 characters | Name of the payee's bank. Must not be sent for FPS |
bank_code | Required for bank transfer | String | Code of the payee's bank. It must be a value from the Bank codes list, with leading zeros preserved. Must not be sent for FPS |
callback_url | Yes | URL, up to 500 characters | The Callback for this order is sent to this URL. It cannot be changed after the order is created. Both http and https are accepted; it must not be a local or private network address. See Callback URL |
timestamp | Yes | yyyy-MM-dd HH:mm:ss | The time the request is sent (UTC+8). Rejected if it differs from the ST Pay server time by more than 5 minutes. See Request and response format |
sign | Yes | 64 lowercase hexadecimal characters | See Signature |
Payee account format
| Channel | Accepted account_no formats |
|---|---|
fps | Any one of the following three, sent in the same field: • Mobile number: 8 digits, for example 91234567• Email: up to 200 characters, containing only English letters, digits, and @ . _ -, with exactly one @ that has characters on both sides and a . after it, for example chan.taiman@example.com• FPS ID: 1 to 50 digits |
bank_transfer | Digits and hyphens -, 1 to 50 characters, for example 012-345678-001 |
If an FPS order includes bank_name or bank_code, invalid_parameter is returned. If a bank transfer order is missing either of them, missing_parameter is returned.
Request examples
FPS
{
"api_identity": "qp_Xk3vT9aLm2QwE7rB1nZc",
"merchant_order_no": "PO20261013-0001",
"amount": "500.00",
"channel_type": "fps",
"account_no": "91234567",
"account_name": "陳大文",
"callback_url": "https://shop.example.com/qpay/callback",
"timestamp": "2026-10-13 10:05:22",
"sign": "693c80aaf437abcd6dbf60f8aed9e4eda09deed052977fa63cb9b1768150044f"
}
Bank transfer
{
"api_identity": "qp_Xk3vT9aLm2QwE7rB1nZc",
"merchant_order_no": "PO20261013-0002",
"amount": "3000.00",
"channel_type": "bank_transfer",
"account_no": "012-345678-001",
"account_name": "CHAN TAI MAN",
"bank_name": "Bank of China (Hong Kong) Limited",
"bank_code": "012",
"callback_url": "https://shop.example.com/qpay/callback",
"timestamp": "2026-10-13 10:06:40",
"sign": "44aadf0a2be821c13c1aef71d8cc7cfc6cf012d3b15f543d2650cdf762002a2b"
}
Response fields
| Field | Description |
|---|---|
order_no | ST Pay order number |
merchant_order_no | The merchant order number you sent |
status | Always pending |
amount | Payout amount |
sign | Response signature, computed with the key used for this request. See Verifying responses |
{
"code": "OK",
"message": "成功",
"data": {
"order_no": "P202610131005224410000",
"merchant_order_no": "PO20261013-0001",
"status": "pending",
"amount": "500.00",
"sign": "e2fe8e5d430ba4bf8a1003b0d7fc8eabcc5d7d974ceda5135783d1aecfa44c8a"
}
}
Possible errors
invalid_signature, timestamp_expired, ip_not_allowed, merchant_disabled, missing_parameter, invalid_parameter, invalid_amount, invalid_callback_url, amount_out_of_range, merchant_order_no_duplicate, insufficient_balance, internal_error. For details, see Error codes.