跳轉到主要內容
GET
/
v2
/
token
/
{chain}
/
pool
/
{poolAddress}
/
candles
池子 - K 線
curl --request GET \
  --url https://api.chainstream.io/v2/token/{chain}/pool/{poolAddress}/candles \
  --header 'Authorization: Bearer <token>'
[
  {
    "close": "51.2",
    "high": "51.8",
    "low": "50.1",
    "open": "50.5",
    "timestamp": 1709251200000,
    "volume": "1000000"
  }
]

授權

Authorization
string
header
必填

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

路徑參數

chain
enum<string>
必填

支援網路列表中的鏈名稱 Supported blockchain chains

可用選項:
sol,
eth,
bsc
poolAddress
string
必填

池子地址

查詢參數

resolution
enum<string>
必填

K 線資料的時間粒度 Candle resolution

可用選項:
1s,
15s,
30s,
1m,
3m,
5m,
15m,
30m,
1h,
2h,
4h,
6h,
8h,
12h,
1d,
3d,
1w,
1M
priceType
enum<string>
預設值:usd

價格類型:usd(預設)或原生代幣價格 Price type for candle data

可用選項:
usd,
native
from
integer<int64>

開始時間戳(Unix 秒級時間戳)

to
integer<int64>

結束時間戳(Unix 秒級時間戳)

limit
integer<int64>

回傳的 K 線數量

回應

200 - application/json

取得池子 K 線

close
string
必填

Close price

範例:

"51.2"

high
string
必填

High price

範例:

"51.8"

low
string
必填

Low price

範例:

"50.1"

open
string
必填

Open price

範例:

"50.5"

timestamp
integer<int64>
必填

Timestamp

範例:

1709251200000

volume
string
必填

Volume

範例:

"1000000"