Skip to content

3.2 Wallet Transfer Records API ​

http
GET /api/v1/exchange/report/transfer-wallet-transactions

Query transfer wallet transaction records (bet deductions, payouts, refunds, deposits, withdrawals, etc.) by time range with pagination. Data comes from the historical store and may lag by a few seconds; the most recent 6 months are retained. Requests must include the HMAC authentication headers.

TIP

This API is rate-limited to 100 requests / minute; exceeding it returns code:10060. The quota is counted per api_key × endpoint — endpoints do not share a quota, and every request (including those returning an error) counts toward it.

Request Parameters (Query String) ​

FieldRequiredTypeDescription
start_timeTRUEstringStart time (≥), RFC3339 UTC, e.g. 2026-05-19T00:00:00Z
end_timeTRUEstringEnd time (≤), RFC3339 UTC, must be later than start_time; the span cannot exceed 90 days
source_idFALSEstringSource ID (ticket / reference number)
order_idFALSEstringSearch for records containing this exchange order ID
player_idFALSEstringInternal player ID (UUID)
player_nameFALSEstringPlayer name
transaction_typeFALSEstringTransaction type (see enum below)
page / page_sizeFALSEintegerPagination; page starts at 1, default 1; page_size defaults to 10, max 200, values ≤0 or >200 fall back to 10

The agent dimension is locked automatically by the system based on api_key; it cannot and need not be specified via parameters.

Response data ​

data contains items[] (transaction records) and pagination fields (total / page / page_size / total_pages).

json
{
  "code": 0,
  "message": "success",
  "data": {
    "items": [
      {
        "id": "0f8c1b2a-6d4e-4a1f-9c33-2a1d4e6f7a80",
        "player_id": "45d3d8eb-1a95-4e47-9315-bc507ea06d65",
        "player_external_id": "player1",
        "player_name": "player1_name",
        "agent_id": "bea4274e-4333-423c-a8e8-4c203d256d2c",
        "agent_name": "agent_demo",
        "transaction_type": "EXCHANGE_TRANSACTION_TYPE_BET_DEDUCT",
        "kind": "",
        "source_id": "019e0000-0000-0000-0000-000000000000",
        "source_id_type": "",
        "order_ids": ["019e0000-0000-0000-0000-000000000000"],
        "currency": "CNY",
        "amount": "-100",
        "balance_after": "900",
        "created_at": "2026-05-20T10:00:00Z"
      }
    ],
    "total": 1,
    "page": 1,
    "page_size": 10,
    "total_pages": 1
  }
}

items[] fields ​

FieldTypeDescription
idstringUnique ID of this wallet record (UUID)
player_idstringInternal player ID (UUID)
player_external_idstringPlayer ID
player_namestringPlayer name
agent_idstringInternal agent ID (UUID)
agent_namestringAgent name
transaction_typestringTransaction type (enum, see below)
kindstringRecord kind
source_idstringSource ID; for deposits / withdrawals this is the ticket_id sent in the request, for bet-related records the corresponding source reference
source_id_typestringType of the source_id source
order_idsarrayExchange order IDs linked to this record; may contain more than one — see below
currencystringCurrency
amountstringAmount change (may be negative, e.g. bet deduction)
balance_afterstringBalance after this change
created_atstringTransaction time (RFC3339 UTC)

order_ids Behavior ​

order_ids lists the exchange orders linked to this wallet record and may contain more than one entry: payouts are aggregated by "player × event × market", so a single SETTLEMENT_PAYOUT can cover several bets (up to 6 observed in production).

transaction_typeorder_ids count
DEPOSIT, WITHDRAWEmpty array (not bet-related)
BET_DEDUCT, HEDGE_REFUND, MTS_REJECT_REFUND, PLAYER_CANCEL_REFUNDAlways 1
SETTLEMENT_PAYOUT, ROLLBACK_CLAWBACKMay be several

IMPORTANT

The amount of an aggregated record cannot be broken back down to individual bets through this API. For per-bet amounts, use trades[] from the Bet Ticket Query API.

Incremental Reconciliation ​

created_at is the time the platform wrote the ledger entry. It increases monotonically and works well as a cursor for incremental pulls.

IMPORTANT

This API covers only events where money actually moved. A losing bet produces no wallet record at all — the funds were deducted when the bet was placed, and settlement moves nothing further. Payouts and rollback clawbacks are likewise written only when the amount is greater than 0.

Recommended reconciliation split:

  • Cash flow: pull incrementally from this API by created_at.
  • Bet status and P&L: use the Bet Ticket Query API with an order time range or settlement time range.

Enums ​

Transaction type transaction_type (prefix EXCHANGE_TRANSACTION_TYPE_) ​

ValueDescription
BET_DEDUCTBet deduction
SETTLEMENT_PAYOUTSettlement payout
ROLLBACK_CLAWBACKSettlement rollback clawback
PLAYER_CANCEL_REFUNDPlayer cancellation refund
HEDGE_REFUNDHedge refund
BET_CANCEL_REFUNDBet void refund
MTS_REJECT_REFUNDMTS rejection refund
ADMIN_CANCEL_REFUNDBack-office cancellation refund
ADMIN_CANCEL_CLAWBACKBack-office cancellation clawback
DEPOSITDeposit
WITHDRAWWithdrawal
RE_SETTLEMENT_PAYOUTReserved value; no write path exists today, it will not appear
MARKET_SUSPEND_REFUNDReserved value; no write path exists today, it will not appear

TIP

A re-settlement actually produces two records — ROLLBACK_CLAWBACK and SETTLEMENT_PAYOUT. It never produces RE_SETTLEMENT_PAYOUT.

BFX EXCHANGE · BE THE GAME CHANGER