ST Pay Merchant APIST Pay Merchant API
Guide
API
Error codes
Back office
AI-assisted integration
  • 繁體中文
  • 简体中文
  • English
Guide
API
Error codes
Back office
AI-assisted integration
  • 繁體中文
  • 简体中文
  • English
  • Getting started

    • Overview
    • Request and response format
    • Authentication and IP whitelist
    • Signature
    • Merchant back office
    • AI-assisted integration
  • API

    • Create a collection order
    • Create a payout order
    • Order query
    • Callback notifications
  • Reference

    • Order status and amounts
    • Duplicate requests and confirming results
    • Error codes
    • Bank codes
    • Go-live checklist

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_balance is 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

FieldRequiredFormatDescription
api_identityYesStringThe API identity issued by ST Pay
merchant_order_noYes1–200 characters; English letters, digits, _, -Your order number. It must be unique among your payout orders; collection orders and payout orders are counted separately
amountYesAmount stringThe payout amount, which is also the basis for calculating the fee
channel_typeYesfps or bank_transferChannel type
account_noYesDepends on the channel; see Payee account formatPayee account number
account_nameYes1–200 charactersPayee's name or account name
bank_nameRequired for bank transfer1–100 charactersName of the payee's bank. Must not be sent for FPS
bank_codeRequired for bank transferStringCode 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_urlYesURL, up to 500 charactersThe 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
timestampYesyyyy-MM-dd HH:mm:ssThe 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
signYes64 lowercase hexadecimal charactersSee Signature

Payee account format

ChannelAccepted account_no formats
fpsAny 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_transferDigits 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

FieldDescription
order_noST Pay order number
merchant_order_noThe merchant order number you sent
statusAlways pending
amountPayout amount
signResponse 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.

Prev
Create a collection order
Next
Order query