Skip to content

GET Financial Transactions

Endpoint

GET /api/affiliate/v1/transactions

Requires an affiliate API token with transactions:read.

GET /api/affiliate/v1/transactions?limit=100&offset=0&type=0&status=3&from_time=1789344000&to_time=1791936000
Authorization: {JWT_TOKEN}

The server first resolves customers attributed to the token's affiliate and brand. A transaction is included only when its customer_id belongs to that set, or when its trading account login is linked to one of those customers. The login fallback supports older transaction records without a customer id.

Query parameters

Name Type Required Description
limit int Yes Page size from 1 to 500
offset int Yes Number of matching records to skip; minimum 0
type int No 0 deposit, 1 withdrawal
status int No Cashier transaction status code
customer_id int No Restrict the result to a single customer. Must be positive
from_time int64 No Minimum created_time, inclusive. 0 or omitted means no lower bound
to_time int64 No Maximum created_time, inclusive. 0 or omitted means no upper bound

from_time and to_time filter on the created_time field returned in every row, and count reflects the filtered set. An invalid bound is refused with 400; see Time filtering.

Response

{
  "rows": [
    {
      "id": 899,
      "customer_id": 12041,
      "login": 2000041,
      "type": 0,
      "type_name": "deposit",
      "status": 3,
      "status_name": "credited",
      "provider": "stripe",
      "method": "card",
      "amount": 250.0,
      "currency": "USD",
      "account_currency": "USD",
      "converted_amount": 250.0,
      "conversion_rate": 1.0,
      "created_time": 1789344000,
      "processed_time": 1789344012
    }
  ],
  "count": 12
}

The response excludes provider payment identifiers, idempotency keys, raw metadata, internal comments, failure or rejection details, and staff identifiers.

This endpoint cannot answer whether a deposit was the customer's first: that requires reducing the whole history to one transaction per customer, which a page of this list does not allow. Use First deposits for the FTD figure.

Errors

HTTP Error Description
401 INCORRECT_TOKEN JWT signature or format is invalid
401 INVALID_AFFILIATE_API_TOKEN Token record, owner, brand, scope, expiration, or active access check failed
403 INVALID_AFFILIATE_API_HOST The request origin is not allowed for this token
400 INVALID_DATA limit or offset is missing or invalid, customer_id is not a positive integer, or from_time / to_time is not a non-negative integer or forms an inverted range