GET /simple/token_price/{id}

Auth X-Hub-Key from API_HUB_KEYExecute GET /run/coingecko/simple/token_price/{id}Cache cached 1s, never served stale past that windowCost free · weight 0 · standard rate classSource billing free

Spot price, market cap and 24h metrics for ERC-20/SPL token contracts on one asset platform.

Parameters

nameintypedescription
idpathstrrequiredAsset platform id (from /asset_platforms), e.g. ethereum, solana, base.
default: ethereum
example: ethereum
contract_addressesquerystrrequiredComma-separated token contract addresses.
example: 0xa0b86991c6218b36c1d19d4a2e9eb0ce3606eb48
vs_currenciesquerystrrequiredComma-separated quote currencies.
default: usd
example: usd
include_market_capquerybooloptionalInclude market cap per token.
default: False
example: True
include_24hr_volquerybooloptionalInclude 24h volume per token.
default: False
example: True
include_24hr_changequerybooloptionalInclude 24h percentage change per token.
default: False
example: True
include_last_updated_atquerybooloptionalInclude unix timestamp of the last price update.
default: False
example: False

Response

type: object
pagination: none
sample: {
  "0xa0b86991c6218b36c1d19d4a2e9eb0ce3606eb48": "object"
}

Safe request

Reads the credential from API_HUB_KEY; it never appears in the URL.

curl -sH "X-Hub-Key: $API_HUB_KEY" "https://openapihub.dev/run/coingecko/simple/token_price/ethereum?contract_addresses=0xa0b86991c6218b36c1d19d4a2e9eb0ce3606eb48&vs_currencies=usd&include_market_cap=True&include_24hr_vol=True&include_24hr_change=True&include_last_updated_at=False"