Binance
API actions for the Binance integration.
Binance
Access public market data from Binance.
Get average price
Fetch the current average price for a symbol.
Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
symbol | string | Yes | Trading pair symbol. |
Response
{
"avg_price": {
"mins": 5,
"price": "42152.75"
}
}Get exchange info
Retrieve exchange trading rules and symbol metadata.
Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
symbol | string | No | Trading pair symbol. |
Response
{
"exchange_info": {
"serverTime": 1706097600000,
"symbols": [
{
"baseAsset": "BTC",
"quoteAsset": "USDT",
"status": "TRADING",
"symbol": "BTCUSDT"
}
],
"timezone": "UTC"
}
}Get order book
Retrieve the current order book depth for a symbol.
Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
symbol | string | Yes | Trading pair symbol. |
limit | number | No | Depth limit. |
Response
{
"order_book": {
"asks": [
[
"42150.50",
"0.75"
]
],
"bids": [
[
"42150.00",
"0.50"
]
],
"lastUpdateId": 9876543210
}
}List recent trades
List the most recent trades for a symbol.
Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
symbol | string | Yes | Trading pair symbol. |
limit | number | No | Maximum number of trades. |
Response
{
"trades": [
{
"id": 12345678,
"isBuyerMaker": true,
"price": "42150.50",
"qty": "0.05",
"time": 1706097600000
}
]
}Get server time
Fetch the current Binance server time to sync client clocks.
Response
{
"server_time": {
"serverTime": 1706097600000
}
}Get 24h ticker
Retrieve 24-hour ticker statistics for a symbol.
Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
symbol | string | Yes | Trading pair symbol. |
Response
{
"ticker": {
"lastPrice": "42150.50",
"priceChange": "850.50",
"priceChangePercent": "2.05",
"symbol": "BTCUSDT"
}
}