Claim commission

Live
POST/api/v1/affiliate/claim

Moves the member's entire accumulated commission into the wallet immediately (atomic) — no request body.

The claimed amount shows up in the transaction history as an AFFILIATE entry.

Headers

FieldTypeRequiredDescription
AuthorizationstringYesUsed — send Bearer <member access_token>
X-Api-KeystringYesAgent API key (ak_…) from the bo screen
X-TimestampstringYesSigning time in unix milliseconds (±300s skew allowed)
X-NoncestringYesUnique per-request value (UUIDv4) for replay protection
X-SignaturestringYeshex(HMAC-SHA256(secret, canonical)) — see the Authentication page
X-Player-IPstring—The player's real IP (IPv4/IPv6) — recommended (used in login history)
X-Player-UAstring—The player's User-Agent (optional — recorded in login history)
X-Request-Idstring—Your correlation id — echoed back as request_uuid (recommended)
x-langstring—th (default) or en — the language of message

Response

Fields in data

FieldTypeRequiredDescription
amountstring—Commission credited to the wallet this time (THB, string)
balancestring—Wallet balance after the credit (THB, string)
Response example
{
  "success": true,
  "code": 0,
  "message": "สำเร็จ",
  "data": {
    "amount": "245.75",
    "balance": "421.25"
  },
  "request_uuid": "f1d8b3c6-7e42-4a09-95bd-2c8e6f0a3d71"
}

Possible error codes

codeNameHTTPMessage
6101AFFILIATE_NOTHING_TO_CLAIM400No affiliate commission to claimThere is no unclaimed commission
6102AFFILIATE_BELOW_MIN_CLAIM400Affiliate balance is below the minimum claim amountThe accumulated amount is below the agent's minimum claim threshold
6103AFFILIATE_NOT_ENABLED400Refer-a-friend program is not enabledThe agent has the refer-a-friend program disabled, or the member is under a SEAMLESS-wallet agent (both cases show enabled = false on the summary page)
9002SERVICE_UNAVAILABLE503Service unavailableThe payment system is temporarily unavailable — the balance is untouched, retry later
1001UNAUTHORIZED401Unauthorized
1007TOKEN_INVALID401Token invalid