Skip to main content

Aggregated Trades

Endpoint: /bapi/defi/v1/public/alpha-trade/agg-trades

Full URL Example

https://www.binance.com/bapi/defi/v1/public/alpha-trade/agg-trades?symbol=ALPHA_118USDC

Description

Retrieves compressed, aggregated historical trades for a specific symbol. Useful for recent trade history.

Parameters

NameTypeMandatoryDescription
symbolSTRINGYESe.g., "ALPHA_118USDC" – use token ID from Token List
fromIdLONGNOstarting trade ID to fetch from
startTimeLONGNOstart timestamp (milliseconds)
endTimeLONGNOend timestamp (milliseconds)
limitINTNOnumber of results to return (default 500, max 1000)

Response Structure

Array of objects, each representing an aggregated trade:

  • a: Integer (aggregate trade ID)
  • p: String (price)
  • q: String (quantity)
  • f: Integer (first trade ID)
  • l: Integer (last trade ID)
  • T: Integer (timestamp)
  • m: Boolean (true if buyer is market maker) ← deprecated field, can ignore