tokens parameter.
Parameters
string
required
Comma-separated
chain:token_address pairs, up to 100, such as ethereum:0xa0b86991c6218b36c1d19d4a2e9eb0ce3606eb48,base:0x0000000000000000000000000000000000000000.chainis a supported chain value. The same aliases work, such asmainnetforethereum, and values are case-insensitive.token_addressis0xfollowed by 40 hex characters, in any case. Use the zero address,0x0000000000000000000000000000000000000000, for the chain’s native token, such as ETH on Base.- Pairs that name the same token, such as
mainnet:0xA0b8…andethereum:0xa0b8…, are returned once. - Any chain value outside supported chains returns
400 BAD_REQUEST.
Response
object[]
One entry per distinct token, in the order you requested them. A token Goldsky knows nothing about is still listed, with its metadata and price set to
null, so you can match each entry to your request by chain and token_address.pagination object. Every token you asked for comes back in one response.
How the data behaves
- Prices are current. You can’t ask for a token’s price at a past time. To get the USD value of a past transfer, use Transfers, which prices each transfer at the time it happened.
- Prices move between requests. Prices update on their own schedule, so two requests seconds apart can return different prices for the same token. Responses carry
Cache-Control: public, max-age=2. - Metadata can fill in later. A token Goldsky hasn’t seen yet comes back with
nullfields, which can fill in on a later request.
Errors
This endpoint returns the same errors as the other feeds, exceptINVALID_CURSOR, CONFLICTING_FILTERS, and NATIVE_BALANCE_UNAVAILABLE, which don’t apply. A malformed tokens value returns 400 BAD_REQUEST, and error.message says what is wrong:
Billing
One request is billed as one request, however many tokens it looks up, so a request for 100 tokens costs the same as a request for one. See Feeds pricing.Example
Look up USDC on Ethereum, ETH on Base, USDC on Base, and an address that isn’t a token:price_usd with no last_priced_at, because they’re priced at 1.0, and the last address comes back with null fields: