Sand AISand AI MAGI-2MAGI-2 è ora su SandBase: video in 1080p con audio nativoProvalo ora

CoinGecko Coin Price by Token Addresses

Documentazione API
https://api.sandbase.ai/v1/api/coingecko/simple-token-price

Get one or more token prices using their token contract addresses

Prezzo
$0.008USD / chiamata
Metodo
POST
Risposta
JSON
Parametri
3 obbligatori · 5 opzionali

Playground

Input
Asset platform's ID. *refers to [`/asset_platforms`](/reference/asset-platforms-list)
Token contract addresses, comma-separated if querying more than 1 token
Target currency of coins, comma-separated if querying more than 1 currency. *refers to [`/simple/supported_vs_currencies`](/reference/simple-supported-currencies)
Include 24-hour change percentage. Default: false
Include 24-hour trading volume. Default: false
Include last updated price time as a UNIX timestamp. Default: false
Include market capitalization. Default: false
Decimal places for currency price value
OutputPronto

Il tuo output apparirà qui

Completa gli input, poi fai clic su Esegui.

README API

CoinGecko Coin Price by Token Addresses API

Get one or more token prices using their token contract addresses

The response is the official CoinGecko API response, unchanged.

Request

curl -X POST "https://api.sandbase.ai/v1/api/coingecko/simple-token-price" \
  -H "Authorization: Bearer $SANDBASE_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"id": "ethereum", "contract_addresses": "0xa0b86991c6218b36c1d19d4a2e9eb0ce3606eb48", "vs_currencies": "usd"}'

Parameters

NameTypeRequiredDescription
idstringYesAsset platform's ID. *refers to /asset_platforms
contract_addressesstringYesToken contract addresses, comma-separated if querying more than 1 token
include_24hr_changebooleanNoInclude 24-hour change percentage. Default: false
include_24hr_volbooleanNoInclude 24-hour trading volume. Default: false
include_last_updated_atbooleanNoInclude last updated price time as a UNIX timestamp. Default: false
include_market_capbooleanNoInclude market capitalization. Default: false
precisionstringNoDecimal places for currency price value
vs_currenciesstringYesTarget currency of coins, comma-separated if querying more than 1 currency. *refers to [/simple/supported_vs_currencies](/reference/simple-supported-currencie

Pricing

Flat price per call. Failed calls are not charged.

Esplora altro

API correlate

Tutte le API
APIPrezzoRisposta
CoinGecko$0.008 per chiamataJSON
CoinGecko$0.008 per chiamataJSON
CoinGecko$0.008 per chiamataJSON
CoinGecko$0.008 per chiamataJSON
CoinGecko$0.008 per chiamataJSON
CoinGecko$0.008 per chiamataJSON

Domande

FAQ

Come uso l'API CoinGecko Coin Price by Token Addresses?

Invia una richiesta POST a https://api.sandbase.ai/v1/api/coingecko/simple-token-price con la tua chiave API di SandBase nell'header Authorization (Bearer) e i parametri nel body JSON. Puoi anche provarla nel Playground di questa pagina senza scrivere codice.

Quanto costa l'API CoinGecko Coin Price by Token Addresses?

$0.008 per chiamata, addebitato dal tuo saldo SandBase. Paghi solo le chiamate che effettui; non c'è alcun abbonamento.

Quali parametri accetta l'API CoinGecko Coin Price by Token Addresses?

Richiesti: id (string), contract_addresses (string) e vs_currencies (string). Facoltativi: include_24hr_change (boolean), include_24hr_vol (boolean), include_last_updated_at (boolean), include_market_cap (boolean) e precision (uno tra full, 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18). La tabella dei parametri e il Playground di questa pagina elencano tutti i campi.

Cosa restituisce l'API CoinGecko Coin Price by Token Addresses?

Una risposta JSON restituita nella stessa richiesta HTTP (sincrona).

Mi serve un account sviluppatore o una chiave API CoinGecko?

No. CoinGecko Coin Price by Token Addresses funziona tramite SandBase, quindi una sola chiave API SandBase copre questo endpoint e tutte le altre API e modelli del catalogo. Non è necessario richiedere separatamente l'accesso alle API CoinGecko.