DeFi API
查询代币列表

查询代币列表#

描述:如果 tokenAddress 和 chainId 信息准确无误,则该 API 将提供指定代币的信息。如果参数不存在,则会列出所有代币的信息。

请求地址#

GET https://www.okx.com/api/v5/defi/explore/token/list

请求参数#

参数名称相关描述参数类型必传数据类型
tokenAddress币种合约地址请求参数String
chainId币种公链 ID请求参数String

响应参数#

参数名称相关描述数据类型
symbol平台 IDString
tokenInfos币种信息Array[Struct]
>tokenId币种 IDString
>tokenSymbol币种标识String
>network币种网络名称String
>logoUrl币种 logo 网址String
>tokenAddress币种智能合约地址String

请求示例#

shell
curl --location 'https://www.okx.com/api/v5/defi/explore/token/list' \
--header 'OK-ACCESS-KEY: 24b****53' \
--header 'OK-ACCESS-PASSPHRASE: p****d' \

响应示例#

200
{
    "code": 0,
    "msg": "",
    "data": [
{
    "symbol": "oSQTH",
    "tokenInfos": [
{
    "tokenId": "7042",
    "tokenSymbol": "oSQTH",
    "network": "ETH",
    "logoUrl": "https://static.coinall.ltd/cdn/wallet/logo/icon_unknow.png",
    "tokenAddress": "0xf1b99e3e573a1a9c5e6b2ce818b617f0e664e86b"
}
    ]
},
{
    "symbol": "DFI",
    "tokenInfos": [
{
    "tokenId": "3533",
    "tokenSymbol": "DFI",
    "network": "ETH",
    "logoUrl": "https://static.coinall.ltd/cdn/wallet/logo/icon_custom_default_D.png",
    "tokenAddress": "0x8fc8f8269ebca376d046ce292dc7eac40c8d358a"
},
{
    "tokenId": "8645",
    "tokenSymbol": "DFI",
    "network": "BSC",
    "logoUrl": "https://static.coinall.ltd/cdn/wallet/logo/icon_custom_default_D.png",
    "tokenAddress": "0x361c60b7c2828fcab80988d00d1d542c83387b50"
}
    ]
}
    ]
}