Get Batch Token Price#
Retrieve the latest price for multiple tokens
Request URL#
POST https://web3.okx.com/api/v5/dex/market/price-info
Request Parameters#
Parameter | Type | Required | Description |
---|---|---|---|
chainIndex | String | Yes | Unique identifier for the chain. e.g., 1 : Ethereum. See more here. |
tokenContractAddress | String | Yes | Token contract address ,for EVM please pass all-lowercase addresses (e.g., 0x382bb369d343125bfb2117af9c149795c6c65c50),Supports batch queries:Up to 100 addresses can be entered, separated by commas. |
Response Parameters#
Parameter | Type | Description |
---|---|---|
chainIndex | String | Unique identifier for the chain (e.g., 1: Ethereum; see more here). |
tokenContractAddress | String | Token contract address (e.g., 0x382bb369d343125bfb2117af9c149795c6c65c50) |
time | String | Timestamp of the price, Unix timestamp format in milliseconds |
price | String | Latest token price |
marketCap | String | Token marketcap |
priceChange5M | String | 5 min price change,the unit is percentage change |
priceChange1H | String | 1 hour price change,the unit is percentage change. |
priceChange4H | String | 4 hour price change,the unit is percentage change. |
priceChange24H | String | 24 hour price change,the unit is percentage change. |
volume5M | String | 5 min volume |
volume1H | String | 1 hour volume |
volume4H | String | 4 hour volume |
volume24H | String | 24 hour volume |
Request Example#
shell
curl --location --request POST 'https://web3.okx.com/api/v5/dex/market/price' \
--header 'Content-Type: application/json' \
--header 'OK-ACCESS-KEY: 37c541a1-****-****-****-10fe7a038418' \
--header 'OK-ACCESS-SIGN: leaV********3uw=' \
--header 'OK-ACCESS-PASSPHRASE: 1****6' \
--header 'OK-ACCESS-TIMESTAMP: 2023-10-18T12:21:41.274Z' \
--data-raw '[
{
"chainIndex": "501",
"tokenContractAddress": "5mbK36SZ7J19An8jFochhQS4of8g6BwUjbeCSxBSoWdp"
},
{
"chainIndex": "501",
"tokenContractAddress": "eL5fUxj2J4CiQsmW85k5FG9DvuQjjUoBHoQBi2Kpump"
}
]'
Response Example#
200
{
"code":"0",
"msg":"",
"data": [
{
"chainIndex": "501",
"marketCap": "22749694.785707055263097277",
"price": "0.040934120366635217",
"priceChange1H": "-1.26",
"priceChange24H": "-12.59",
"priceChange4H": "-5",
"priceChange5M": "0.58",
"time": "1748588438146",
"tokenContractAddress": "5mbK36SZ7J19An8jFochhQS4of8g6BwUjbeCSxBSoWdp",
"volume1H": "34825.829681412190135",
"volume24H": "713558.48215291344088751",
"volume4H": "192320.139296931370267",
"volume5M": "4125.7651622751"
},
{
"chainIndex": "501",
"marketCap": "31413747.811490509965212529",
"price": "0.031414439357086906",
"priceChange1H": "-0.7",
"priceChange24H": "-9.4",
"priceChange4H": "-0.39",
"priceChange5M": "0",
"time": "1748588438146",
"tokenContractAddress": "eL5fUxj2J4CiQsmW85k5FG9DvuQjjUoBHoQBi2Kpump",
"volume1H": "7185.41755878059002",
"volume24H": "597292.310082342501658471",
"volume4H": "51322.9983621450200266",
"volume5M": "0"
}
]
}