Skip to main content

Recent Trades

Recent public trades for a symbol.

Endpoint

GET /v1/market/trades

Weight: 5.

Authentication: Public (optional signing).

Query parameters

NameTypeMandatoryDescription
symbolstringYesTrading pair, uppercase, e.g. BTCUSDT.
limitintegerNoNumber of trades to return. Range 11000. Default 500.

Trades are returned in descending time order (most recent first).

Response

[
{
"id": 4823917221,
"price": "67432.15",
"qty": "0.0421",
"quoteQty": "2840.91",
"time": 1745923199821,
"isBuyerMaker": false
},
{
"id": 4823917220,
"price": "67432.10",
"qty": "0.1100",
"quoteQty": "7417.53",
"time": 1745923199734,
"isBuyerMaker": true
},
{
"id": 4823917219,
"price": "67432.20",
"qty": "0.0050",
"quoteQty": "337.16",
"time": 1745923199610,
"isBuyerMaker": false
}
]

Response fields

FieldTypeDescription
idintegerGlobally unique, monotonically increasing trade id.
pricestring (decimal)Trade price.
qtystring (decimal)Trade quantity in base asset.
quoteQtystring (decimal)Trade quantity in quote asset (price * qty).
timeintegerTrade time, Unix milliseconds.
isBuyerMakerbooleantrue if the buyer was the resting order (i.e. the trade was a sell aggression).

Errors

HTTPCodeMeaning
400INVALID_PARAMETERMissing symbol, or limit out of range.
400UNKNOWN_SYMBOLSymbol does not exist.
429RATE_LIMITEDPer-key request weight exceeded.

Example

curl -s "https://api.pipai.io/v1/market/trades?symbol=BTCUSDT&limit=100"