Skip to main content
GET
按 Token 地址查询币种价格
以链上合约地址而非 CoinGecko id 为键的价格查询。id 是资产所在链,contract_addresses 是逗号分隔的代币地址列表,vs_currencies 是计价货币。返回以小写合约地址为键的映射,其字段名由计价货币拼接而成——包含 usd,并在设置了对应的 include_market_capinclude_24hr_volinclude_24hr_changeinclude_last_updated_at 标志时额外返回 usd_market_capusd_24h_volusd_24h_changelast_updated_at。当你只有地址而没有 id 时使用它。如需该代币的完整档案,请使用 get_coingecko_token_data;如果你已经有 CoinGecko id,请使用 get_coingecko_simple_price

授权

Authorization
string
header
必填

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

路径参数

id
string
必填

平台 ID(例如 ethereumbinance-smart-chainpolygon-pos)。

查询参数

contract_addresses
string
必填

以逗号分隔的合约地址。

vs_currencies
string
必填

以逗号分隔的目标货币。

include_market_cap
boolean
include_24hr_vol
boolean
include_24hr_change
boolean
include_last_updated_at
boolean
precision
string

使用 full018 之间的值指定货币价格值的小数位数。

响应

200 - application/json

以合约地址为键的映射。

{key}
object