Skip to main content

API การทำรายการจ่ายออก (Pay-Out)

smilepayz teamsประมาณ 2 นาที

API Pay-out ภูมิภาค USDT (USDT). ดู Payment methods

Request

Pay-Out API เปิดให้ร้านค้าสามารถเริ่มต้นธุรกรรมการจ่ายเงินออกไปยังผู้รับหลายประเภท เช่น พนักงาน ลูกค้า ผู้ขาย และพาร์ตเนอร์ API นี้รองรับวิธีการชำระเงินด้วยคริปโทเคอร์เรนซีหลายรูปแบบ เพื่อให้การโอนสินทรัพย์ดิจิทัลมีความปลอดภัยและมีประสิทธิภาพ

Request Path:

sandbox: https://sandbox-gateway.smilepayz.com/v2.0/disbursement/pay-out
production: https://gateway.smilepayz.com/v2.0/disbursement/pay-out

Header Parameters

FieldRequiredTypeDescription
Content-TypeMStringapplication/json request body.
X-TIMESTAMPMStringDatetime with zone offset, format yyyy-MM-ddTHH:mm:ss±HH:mm
X-SIGNATUREMStringSignature of JSON body (see product Signature doc).
X-PARTNER-IDMStringYour merchantID

Body Parameters

FieldRequiredTypeDescription
orderNoMString(32)Merchant-unique id
purposeMString(64)Memo to payer
merchantMObjectWraps merchantId and optional sub-merchant fields.
    merchantIdMStringSmilepayz merchantId for this call.
    merchantNameOStringMerchant display name.
    subMerchantIdOStringSub-merchant ID.
    subMerchantNameOStringName for subMerchantId.
moneyMObjectCurrency plus amount for this transaction.
    currencyMStringFixed to USDT.
    amountMNumberAmount
paymentMethodMString(6)See Payment methods doc.
cashAccountMString(32)Beneficiary bank account number.
networkMString(32)เครือข่ายบล็อกเชนที่ใช้ในการประมวลผลธุรกรรม รูปแบบ: รหัสเครือข่ายที่กำหนดไว้ล่วงหน้า ตัวอย่าง: BEP20, TRC20 ใช้ระบุเครือข่ายที่ธุรกรรมจะถูกส่งผ่าน
callbackUrlOString(256)HTTPS async status URL, max 256 chars.

Example Body – Disbursement Request:

Content-type: application/json
X-TIMESTAMP: 2020-12-17T10:55:00+07:00
X-SIGNATURE: 7MHd9v5/m9JeqmDZVwWBZUZ5J5...7120QnFEny7Qm7uQR1G0TWCh10fsU6nVxiRoeoQ==
X-PARTNER-ID: 20001

Response

HTTP Response

FieldRequiredTypeDescription
Content-TypeMStringapplication/json response or callback body.
X-TIMESTAMPMStringDatetime with zone offset, format yyyy-MM-ddTHH:mm:ss±HH:mm

Body Parameters

FieldRequiredTypeDescription
codeMString00 success, other values error.
messageMStringUTF-8 human-readable result line.
orderNoMStringMerchant-unique id
tradeNoOStringSmilepayz tradeNo for this order.
merchantMObjectWraps merchantId and optional sub-merchant fields.
    merchantIdMStringSmilepayz merchantId for this call.
    merchantNameOStringMerchant display name.
    subMerchantIdOStringSub-merchant ID.
    subMerchantNameOStringName for subMerchantId.
moneyMObjectCurrency plus amount for this transaction.
    currencyMStringFixed to USDT.
    amountMNumberAmount
disbursementTimeMStringเวลาที่ทำธุรกรรมจ่ายออกเสร็จสิ้น รูปแบบ: yyyy-MM-ddTHH:mm:ss ตัวอย่าง: 2020-12-17T10:55:00+07:00 ใช้สำหรับติดตามเวลาและการตรวจสอบย้อนหลัง (audit)
channelMObjectChannel payload (paymentUrl, qrString, …).
statusOStringOrder or payment status enum value.
Content-type: application/json
X-TIMESTAMP: 2020-12-17T10:55:00+07:00

Notification

HTTP Request

FieldRequiredTypeDescription
Content-TypeMStringapplication/json request body.
X-TIMESTAMPMStringDatetime with zone offset, format yyyy-MM-ddTHH:mm:ss±HH:mm
X-SIGNATUREMStringCallback body signature (see Callback signature guide).

Body Parameters

FieldRequiredTypeDescription
orderNoMStringMerchant-unique id
tradeNoMStringSmilepayz tradeNo for this order.
merchantIdMStringSmilepayz merchantId for this call.
merchantNameMStringOptional Merchant display name.
subMerchantIdOStringSub-merchant ID.
subMerchantNameOStringName for subMerchantId.
paymentMethodMStringSee Payment methods doc.
transactionTimeMStringTransaction completion timestamp Format: yyyy-MM-ddTHH:mm:ss Example: 2024-12-17T10:55:00 Used for transaction timing and audit
statusMStringOrder or payment status enum value.
moneyMObjectCurrency plus amount for this transaction.
    currencyMStringFixed to USDT.
    amountMNumberAmount

Return

การตอบกลับที่สำคัญ

Notification Response: โปรดตอบกลับด้วยสตริง SUCCESS เพียงอย่างเดียว เพื่อยืนยันว่าระบบของคุณได้รับการแจ้งเตือนแล้ว

{
  "orderNo": "2000102900000000000001",
  "tradeNo": "20001032432400001",
  "merchantId": "20001",
  "merchantName": "Smilepayz Demo Store",
  "subMerchantId": "",
  "subMerchantName": "",
  "paymentMethod": "USDT",
  "transactionTime": "2024-12-17T10:55:00+07:00",
  "money": {
    "currency": "USDT",
    "amount": 100
  },
  "status": "SUCCESS"
}