API reference
Every endpoint is a GET request that returns JSON. Prices are in US dollars. The example answers are real ones, cut to the first one or two rows.
Getting started
The base URL is https://api.coinprice.dev, and every path below starts with /v2. Start with the latest Bitcoin price:
curl "https://api.coinprice.dev/v2/simple/price?ids=bitcoin&vs_currencies=usd" \
-H "Authorization: Bearer $API_KEY"Get a key
- Sign up at https://coinprice.dev/signup. The Free plan needs no card.
- Create an API key in the dashboard. Keys that start with coin_test_ answer with made-up data and are never charged, so you can test a client without using calls.
- Send the key with every request, as shown under Authentication.
Authentication
- Send your key in the Authorization header as Bearer YOUR_API_KEY. X-API-Key works too, and so do CoinGecko’s x-cg-pro-api-key and x-cg-demo-api-key headers, so a CoinGecko client only needs the base URL changed.
- A key in the query string is never read and gives 401, so a client that sends x_cg_demo_api_key in the URL fails. Move it to a header.
- Keep the key on your server; do not ship it in browser code. Browser calls are allowed only from coinprice.dev origins.
Conventions
- Answers follow CoinGecko’s shapes on the routes the two share. A CoinGecko client usually needs a new base URL and key header, then a check of the fields it reads. The switch guide at /guides/switch-from-coingecko-api lists the differences.
- Prices and changes are JSON numbers in US dollars. A change we cannot work out yet is null, and market cap and supply are always null, so a client should read a null as "not published", not as 0.
- Times are Unix seconds (last_updated_at), Unix milliseconds in candles and charts, or UTC ISO 8601 ending in Z (last_updated).
- A coin with no new price keeps its last price and its last_updated_at; check the time before you rely on it. Thin coins can be minutes or hours old, which is real and not an outage. sources is the number of exchanges with a fresh price; sources 0 means fewer than 2 fresh exchanges in the last 60 seconds, so the price is the last good one.
- Parameters a route does not read are ignored: they do not change the answer and do not cause an error.
- Unknown coin ids in ids are left out of the answer, not an error. An answer with none is empty and still counts as a call.
- A request counts against the month when it is answered with a 2xx status. Errors and 304 Not Modified answers (a repeat request with If-None-Match) are not counted against the month. The calls-a-minute limit counts every request that passes the key check, including errors and 304s.
- Volume is the sum of the 24h volume the exchanges report. It is null when none reports.
- Hourly and daily candles start on 1 Jan 2023, or when the coin began. Minute candles start on 23 Nov 2026 and are kept 30 days (Free) or 90 days (paid plans).
- Candle and chart answers are cut to the newest rows when the window holds more than the limit: 5,000 candles, 2,000 chart points. Page back with from and to.
- The error format below holds for /v2 and /mcp. Other addresses answer in plain text.
Request and response headers
- X-Request-Id comes back on every answer and is the request_id of an error. Send your own (letters, digits and . _ : -, up to 64 characters) and it is echoed back, which helps when you contact support.
- X-RateLimit-Limit, X-RateLimit-Remaining and X-RateLimit-Reset (Unix seconds) describe the calls-a-minute limit. The window is the calendar minute, so Reset is the start of the next minute. They come on 200, 304 and 429 answers, not on 401.
- ETag comes on every 200. Send it back as If-None-Match and an unchanged answer is a 304 with no body, which is not counted against the month.
- Cache-Control is private, max-age=1. Answers over 1 KB are gzipped.
Errors
Errors return JSON with error (a code from the table), message and request_id, which is also the X-Request-Id header. error is a string, for example {"error":"not_found","message":"Coin 'x' was not found.","request_id":"req_..."}.
Retry only rate_limited and unavailable. On quota_exceeded stop and tell the user.
| Status | error | When |
|---|---|---|
400 | invalid_request | A parameter value is not valid; the message names the parameter. |
401 | unauthorized | No key, a wrong key, a key in the URL, or (on the stream) a key that was revoked or whose plan changed. |
404 | not_found | Unknown coin, unknown route, or no price for that day. |
429 | rate_limited | Over the plan’s calls a minute, or too many open stream connections. Wait the seconds in Retry-After, then retry. |
429 | quota_exceeded | The month’s calls are used up. There is no Retry-After; the count resets at 00:00 UTC on the 1st of the month, or when you upgrade. Do not retry: stop and tell the user. |
500 | internal_error | Something failed on our side. |
503 | unavailable | Accounts or prices are briefly unavailable. Retry after a few seconds. |
Prices
Get latest prices
Latest price for up to 250 coins in one call. One call counts as one request. An id that is not a coin is left out of the answer, and an answer with none is {} and still counts as a call.
GET/v2/simple/price
Parameters
idsquery- Comma-separated coin ids. Up to 250. Give ids or symbols.
symbolsquery- Comma-separated symbols, for example btc,eth. Use it instead of ids.
vs_currenciesquery- usd by default. Up to 20 comma-separated codes from /v2/simple/supported_vs_currencies (fiat, and btc, eth, bnb, sol, xrp, ltc, doge). Any case.
include_24hr_volquery- true adds usd_24h_vol, which is null when no exchange reports volume.
include_24hr_changequery- true adds usd_24h_change, which is null until the coin has a day of history.
include_last_updated_atquery- true adds last_updated_at (Unix seconds).
curl "https://api.coinprice.dev/v2/simple/price?ids=bitcoin,ethereum&vs_currencies=usd&include_24hr_vol=true&include_24hr_change=true&include_last_updated_at=true" \ -H "Authorization: Bearer $API_KEY"const res = await fetch('https://api.coinprice.dev/v2/simple/price?ids=bitcoin,ethereum&vs_currencies=usd&include_24hr_vol=true&include_24hr_change=true&include_last_updated_at=true', { headers: { Authorization: `Bearer ${process.env.API_KEY}` },})console.log(await res.json())import os, requestsres = requests.get( 'https://api.coinprice.dev/v2/simple/price?ids=bitcoin,ethereum&vs_currencies=usd&include_24hr_vol=true&include_24hr_change=true&include_last_updated_at=true', headers={'Authorization': f"Bearer {os.environ['API_KEY']}"},)print(res.json())package mainimport ( "fmt" "io" "net/http" "os")func main() { req, _ := http.NewRequest("GET", "https://api.coinprice.dev/v2/simple/price?ids=bitcoin,ethereum&vs_currencies=usd&include_24hr_vol=true&include_24hr_change=true&include_last_updated_at=true", nil) req.Header.Set("Authorization", "Bearer "+os.Getenv("API_KEY")) res, err := http.DefaultClient.Do(req) if err != nil { panic(err) } defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(string(body))}Response 200
{
"bitcoin": {
"last_updated_at": 1795505227,
"usd": 60367.42462,
"usd_24h_change": -1.6653681008539922,
"usd_24h_vol": 6943458273
},
"ethereum": {
"last_updated_at": 1795505227,
"usd": 1695.115,
"usd_24h_change": -1.5692684683010771,
"usd_24h_vol": 2754355534
}
}Prices
List supported currencies
The 150 currency codes that vs_currency and vs_currencies accept. The example shows the first five.
GET/v2/simple/supported_vs_currencies
curl "https://api.coinprice.dev/v2/simple/supported_vs_currencies" \ -H "Authorization: Bearer $API_KEY"const res = await fetch('https://api.coinprice.dev/v2/simple/supported_vs_currencies', { headers: { Authorization: `Bearer ${process.env.API_KEY}` },})console.log(await res.json())import os, requestsres = requests.get( 'https://api.coinprice.dev/v2/simple/supported_vs_currencies', headers={'Authorization': f"Bearer {os.environ['API_KEY']}"},)print(res.json())package mainimport ( "fmt" "io" "net/http" "os")func main() { req, _ := http.NewRequest("GET", "https://api.coinprice.dev/v2/simple/supported_vs_currencies", nil) req.Header.Set("Authorization", "Bearer "+os.Getenv("API_KEY")) res, err := http.DefaultClient.Do(req) if err != nil { panic(err) } defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(string(body))}Response 200
[
"aed",
"afn",
"all",
"amd",
"aoa"
]Prices
Convert an amount
Converts an amount between two coins, or between a coin and a currency, at the latest price.
GET/v2/convert
Parameters
fromqueryrequired- A coin id or a currency code.
toqueryrequired- A coin id or a currency code.
amountquery- A positive number up to 1e15. Default 1.
curl "https://api.coinprice.dev/v2/convert?from=bitcoin&to=usd&amount=1" \ -H "Authorization: Bearer $API_KEY"const res = await fetch('https://api.coinprice.dev/v2/convert?from=bitcoin&to=usd&amount=1', { headers: { Authorization: `Bearer ${process.env.API_KEY}` },})console.log(await res.json())import os, requestsres = requests.get( 'https://api.coinprice.dev/v2/convert?from=bitcoin&to=usd&amount=1', headers={'Authorization': f"Bearer {os.environ['API_KEY']}"},)print(res.json())package mainimport ( "fmt" "io" "net/http" "os")func main() { req, _ := http.NewRequest("GET", "https://api.coinprice.dev/v2/convert?from=bitcoin&to=usd&amount=1", nil) req.Header.Set("Authorization", "Bearer "+os.Getenv("API_KEY")) res, err := http.DefaultClient.Do(req) if err != nil { panic(err) } defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(string(body))}Response 200
{
"amount": 1,
"converted": 60367.35,
"from": "bitcoin",
"last_updated_at": 1795505242,
"rate": 60367.35,
"to": "usd"
}Coins
List coins with prices
A page of ranked coins: on three or more exchanges, with a 24h volume. Each row has price, 24h and 7d change, 24h high and low and 24h volume; market cap, supply and image are null. Pass ids to read any other coin, or use /v2/coins/list or /v2/search to find ids.
GET/v2/coins/markets
Parameters
vs_currencyquery- usd by default. Any code from /v2/simple/supported_vs_currencies: fiat, and btc, eth, bnb, sol, xrp, ltc and doge. Other currencies are converted with live exchange rates. History in another currency is converted at today’s rate.
idsquery- Comma-separated coin ids. Up to 250. Unknown ids are left out. With ids, coins that are not ranked are returned too.
categoryquery- A category id from /v2/coins/categories/list.
orderquery- volume_desc (default; market_cap_desc is an alias), volume_asc, id_asc or id_desc.
per_pagequery- 1 to 250. Default 100.
pagequery- Page number, from 1.
curl "https://api.coinprice.dev/v2/coins/markets?vs_currency=usd&order=volume_desc&per_page=1" \ -H "Authorization: Bearer $API_KEY"const res = await fetch('https://api.coinprice.dev/v2/coins/markets?vs_currency=usd&order=volume_desc&per_page=1', { headers: { Authorization: `Bearer ${process.env.API_KEY}` },})console.log(await res.json())import os, requestsres = requests.get( 'https://api.coinprice.dev/v2/coins/markets?vs_currency=usd&order=volume_desc&per_page=1', headers={'Authorization': f"Bearer {os.environ['API_KEY']}"},)print(res.json())package mainimport ( "fmt" "io" "net/http" "os")func main() { req, _ := http.NewRequest("GET", "https://api.coinprice.dev/v2/coins/markets?vs_currency=usd&order=volume_desc&per_page=1", nil) req.Header.Set("Authorization", "Bearer "+os.Getenv("API_KEY")) res, err := http.DefaultClient.Do(req) if err != nil { panic(err) } defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(string(body))}Response 200
[
{
"circulating_supply": null,
"current_price": 60367.42462,
"fully_diluted_valuation": null,
"high_24h": 63665.96333,
"id": "bitcoin",
"image": null,
"last_updated": "2026-11-24T07:27:07Z",
"last_updated_at": 1795505227,
"low_24h": 59395.53754,
"market_cap": null,
"market_cap_change_24h": null,
"market_cap_change_percentage_24h": null,
"market_cap_rank": null,
"max_supply": null,
"name": "Bitcoin",
"price_change_24h": -1022.3659899999984,
"price_change_percentage_24h": -1.6653681008539922,
"price_change_percentage_7d_in_currency": -6.398904140522699,
"sources": 7,
"symbol": "btc",
"total_supply": null,
"total_volume": 6943458273
}
]Coins
List every coin id
Every coin we price, as id, symbol and name, in one answer with no paging. The example shows the first two.
GET/v2/coins/list
Parameters
statusquery- active (default) lists traded coins; inactive lists delisted ones.
curl "https://api.coinprice.dev/v2/coins/list" \ -H "Authorization: Bearer $API_KEY"const res = await fetch('https://api.coinprice.dev/v2/coins/list', { headers: { Authorization: `Bearer ${process.env.API_KEY}` },})console.log(await res.json())import os, requestsres = requests.get( 'https://api.coinprice.dev/v2/coins/list', headers={'Authorization': f"Bearer {os.environ['API_KEY']}"},)print(res.json())package mainimport ( "fmt" "io" "net/http" "os")func main() { req, _ := http.NewRequest("GET", "https://api.coinprice.dev/v2/coins/list", nil) req.Header.Set("Authorization", "Bearer "+os.Getenv("API_KEY")) res, err := http.DefaultClient.Do(req) if err != nil { panic(err) } defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(string(body))}Response 200
[
{
"id": "0x",
"name": "0x Protocol",
"symbol": "zrx"
},
{
"id": "1inch",
"name": "1INCH",
"symbol": "1inch"
}
]Coins
List coin categories
The category ids that /v2/coins/markets accepts as category: real-world-assets, tokenized-gold and tokenized-stocks.
GET/v2/coins/categories/list
curl "https://api.coinprice.dev/v2/coins/categories/list" \ -H "Authorization: Bearer $API_KEY"const res = await fetch('https://api.coinprice.dev/v2/coins/categories/list', { headers: { Authorization: `Bearer ${process.env.API_KEY}` },})console.log(await res.json())import os, requestsres = requests.get( 'https://api.coinprice.dev/v2/coins/categories/list', headers={'Authorization': f"Bearer {os.environ['API_KEY']}"},)print(res.json())package mainimport ( "fmt" "io" "net/http" "os")func main() { req, _ := http.NewRequest("GET", "https://api.coinprice.dev/v2/coins/categories/list", nil) req.Header.Set("Authorization", "Bearer "+os.Getenv("API_KEY")) res, err := http.DefaultClient.Do(req) if err != nil { panic(err) } defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(string(body))}Response 200
[
{
"category_id": "real-world-assets",
"name": "Real World Assets (RWA)"
}
]Coins
Get a coin
One coin with its market data. market_cap and fully_diluted_valuation come back as {"usd": null}, with one key for each currency you ask for in vs_currencies, and the supplies are null: market cap and supply are never published. Fields that are always null stay in the answer so CoinGecko clients can read them. sources is the number of exchanges with a fresh price; see Conventions.
GET/v2/coins/{id}
Parameters
idpathrequired- Coin id, for example bitcoin. Find ids with /v2/coins/list or /v2/search.
vs_currenciesquery- Comma-separated currencies for market_data. usd by default.
curl "https://api.coinprice.dev/v2/coins/bitcoin" \ -H "Authorization: Bearer $API_KEY"const res = await fetch('https://api.coinprice.dev/v2/coins/bitcoin', { headers: { Authorization: `Bearer ${process.env.API_KEY}` },})console.log(await res.json())import os, requestsres = requests.get( 'https://api.coinprice.dev/v2/coins/bitcoin', headers={'Authorization': f"Bearer {os.environ['API_KEY']}"},)print(res.json())package mainimport ( "fmt" "io" "net/http" "os")func main() { req, _ := http.NewRequest("GET", "https://api.coinprice.dev/v2/coins/bitcoin", nil) req.Header.Set("Authorization", "Bearer "+os.Getenv("API_KEY")) res, err := http.DefaultClient.Do(req) if err != nil { panic(err) } defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(string(body))}Response 200
{
"first_seen_at": 1795433433,
"id": "bitcoin",
"last_updated": "2026-11-24T07:27:12Z",
"last_updated_at": 1795505232,
"market_data": {
"circulating_supply": null,
"current_price": {
"usd": 60367.35
},
"fully_diluted_valuation": {
"usd": null
},
"high_24h": {
"usd": 63665.96333
},
"last_updated": "2026-11-24T07:27:12Z",
"low_24h": {
"usd": 59395.53754
},
"market_cap": {
"usd": null
},
"max_supply": null,
"price_change_percentage_24h": -1.665489652009744,
"price_change_percentage_7d": -6.399019840568165,
"total_supply": null,
"total_volume": {
"usd": 6943458273
}
},
"name": "Bitcoin",
"ranked": true,
"sources": 7,
"symbol": "btc",
"volume_sources": 7
}History
Get the price on a day
The US dollar closing price of one day. 404 for a day with no price. It has no currency parameter.
GET/v2/coins/{id}/history
Parameters
idpathrequired- Coin id, for example bitcoin. Find ids with /v2/coins/list or /v2/search.
datequeryrequired- The day, as dd-mm-yyyy.
curl "https://api.coinprice.dev/v2/coins/bitcoin/history?date=22-11-2026" \ -H "Authorization: Bearer $API_KEY"const res = await fetch('https://api.coinprice.dev/v2/coins/bitcoin/history?date=22-11-2026', { headers: { Authorization: `Bearer ${process.env.API_KEY}` },})console.log(await res.json())import os, requestsres = requests.get( 'https://api.coinprice.dev/v2/coins/bitcoin/history?date=22-11-2026', headers={'Authorization': f"Bearer {os.environ['API_KEY']}"},)print(res.json())package mainimport ( "fmt" "io" "net/http" "os")func main() { req, _ := http.NewRequest("GET", "https://api.coinprice.dev/v2/coins/bitcoin/history?date=22-11-2026", nil) req.Header.Set("Authorization", "Bearer "+os.Getenv("API_KEY")) res, err := http.DefaultClient.Do(req) if err != nil { panic(err) } defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(string(body))}Response 200
{
"id": "bitcoin",
"last_updated_at": 1795392000,
"market_data": {
"current_price": {
"usd": 61166.13363
}
},
"name": "Bitcoin",
"symbol": "btc"
}History
Get candles
Candles as [time in ms, open, high, low, close], oldest first. Hourly and daily candles start on 1 Jan 2023, or when the coin began (/v2/coverage shows hourly_from and daily_from). Minute candles start on 23 Nov 2026 and are kept 30 days on Free and 90 days on paid plans. Answers hold at most 5,000 rows.
GET/v2/coins/{id}/ohlc
Parameters
idpathrequired- Coin id, for example bitcoin. Find ids with /v2/coins/list or /v2/search.
vs_currencyquery- usd by default. Any code from /v2/simple/supported_vs_currencies: fiat, and btc, eth, bnb, sol, xrp, ltc and doge. Other currencies are converted with live exchange rates. History in another currency is converted at today’s rate.
intervalquery- 1m, 5m, 15m, 1h, 4h or 1d (aliases hourly and daily). With no window the default is 1h. With days or from the step is picked from the window: 15m up to 2 days when minute data covers it, else 1h; 4h up to 30 days; 1d over 30.
fromquery- Start of the window: Unix seconds (milliseconds above 1e11 also work), an ISO 8601 time or YYYY-MM-DD.
toquery- End of the window, in the same formats. Default now.
daysquery- A window ending now: a whole number from 1 to 36500, or max. Ignored when from is given.
limitquery- Rows to return, 1 to 5,000. Default 500. A longer window returns the newest rows, so page back with from and to.
curl "https://api.coinprice.dev/v2/coins/bitcoin/ohlc?vs_currency=usd&interval=1h&limit=2" \ -H "Authorization: Bearer $API_KEY"const res = await fetch('https://api.coinprice.dev/v2/coins/bitcoin/ohlc?vs_currency=usd&interval=1h&limit=2', { headers: { Authorization: `Bearer ${process.env.API_KEY}` },})console.log(await res.json())import os, requestsres = requests.get( 'https://api.coinprice.dev/v2/coins/bitcoin/ohlc?vs_currency=usd&interval=1h&limit=2', headers={'Authorization': f"Bearer {os.environ['API_KEY']}"},)print(res.json())package mainimport ( "fmt" "io" "net/http" "os")func main() { req, _ := http.NewRequest("GET", "https://api.coinprice.dev/v2/coins/bitcoin/ohlc?vs_currency=usd&interval=1h&limit=2", nil) req.Header.Set("Authorization", "Bearer "+os.Getenv("API_KEY")) res, err := http.DefaultClient.Do(req) if err != nil { panic(err) } defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(string(body))}Response 200
[
[
1795496400000,
60305.95,
60692.65,
60250.06503,
60545.76894
],
[
1795500000000,
60554.75,
60569.56128,
60285.8201,
60399.70418
]
]History
Get closing prices
Price points as [time in ms, price], oldest first. market_caps and total_volumes are empty lists. The step is picked as for candles. Answers hold at most 2,000 points.
GET/v2/coins/{id}/market_chart
Parameters
idpathrequired- Coin id, for example bitcoin. Find ids with /v2/coins/list or /v2/search.
vs_currencyquery- usd by default. Any code from /v2/simple/supported_vs_currencies: fiat, and btc, eth, bnb, sol, xrp, ltc and doge. Other currencies are converted with live exchange rates. History in another currency is converted at today’s rate.
intervalquery- Same values and default as for candles.
fromquery- Start of the window: Unix seconds (milliseconds above 1e11 also work), an ISO 8601 time or YYYY-MM-DD.
toquery- End of the window, in the same formats. Default now.
daysquery- A window ending now: a whole number from 1 to 36500, or max. Ignored when from is given.
limitquery- Points to return, 1 to 2,000. A longer window returns the newest points, so page back with from and to.
curl "https://api.coinprice.dev/v2/coins/bitcoin/market_chart?vs_currency=usd&days=7&limit=2" \ -H "Authorization: Bearer $API_KEY"const res = await fetch('https://api.coinprice.dev/v2/coins/bitcoin/market_chart?vs_currency=usd&days=7&limit=2', { headers: { Authorization: `Bearer ${process.env.API_KEY}` },})console.log(await res.json())import os, requestsres = requests.get( 'https://api.coinprice.dev/v2/coins/bitcoin/market_chart?vs_currency=usd&days=7&limit=2', headers={'Authorization': f"Bearer {os.environ['API_KEY']}"},)print(res.json())package mainimport ( "fmt" "io" "net/http" "os")func main() { req, _ := http.NewRequest("GET", "https://api.coinprice.dev/v2/coins/bitcoin/market_chart?vs_currency=usd&days=7&limit=2", nil) req.Header.Set("Authorization", "Bearer "+os.Getenv("API_KEY")) res, err := http.DefaultClient.Do(req) if err != nil { panic(err) } defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(string(body))}Response 200
{
"market_caps": [],
"prices": [
[
1794902400000,
64926.04005
],
[
1794916800000,
64047.12
]
],
"total_volumes": []
}History
Get closing prices in a range
The same answer as market_chart for a window you name.
GET/v2/coins/{id}/market_chart/range
Parameters
idpathrequired- Coin id, for example bitcoin. Find ids with /v2/coins/list or /v2/search.
vs_currencyquery- usd by default. Any code from /v2/simple/supported_vs_currencies: fiat, and btc, eth, bnb, sol, xrp, ltc and doge. Other currencies are converted with live exchange rates. History in another currency is converted at today’s rate.
fromqueryrequired- Start of the window: Unix seconds, an ISO 8601 time or YYYY-MM-DD.
toqueryrequired- End of the window, in the same formats.
intervalquery- Same values and default as for candles.
limitquery- Points to return, 1 to 2,000. A longer window returns the newest points, so page back with from and to.
curl "https://api.coinprice.dev/v2/coins/bitcoin/market_chart/range?vs_currency=usd&from=2026-11-23&to=2026-11-24&limit=2" \ -H "Authorization: Bearer $API_KEY"const res = await fetch('https://api.coinprice.dev/v2/coins/bitcoin/market_chart/range?vs_currency=usd&from=2026-11-23&to=2026-11-24&limit=2', { headers: { Authorization: `Bearer ${process.env.API_KEY}` },})console.log(await res.json())import os, requestsres = requests.get( 'https://api.coinprice.dev/v2/coins/bitcoin/market_chart/range?vs_currency=usd&from=2026-11-23&to=2026-11-24&limit=2', headers={'Authorization': f"Bearer {os.environ['API_KEY']}"},)print(res.json())package mainimport ( "fmt" "io" "net/http" "os")func main() { req, _ := http.NewRequest("GET", "https://api.coinprice.dev/v2/coins/bitcoin/market_chart/range?vs_currency=usd&from=2026-11-23&to=2026-11-24&limit=2", nil) req.Header.Set("Authorization", "Bearer "+os.Getenv("API_KEY")) res, err := http.DefaultClient.Do(req) if err != nil { panic(err) } defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(string(body))}Response 200
{
"market_caps": [],
"prices": [
[
1795392000000,
61249.52924
],
[
1795395600000,
60767.63
]
],
"total_volumes": []
}Search
Search for a coin
Up to 25 coins whose id, name or symbol matches. Use it to find a coin id.
GET/v2/search
Parameters
queryqueryrequired- Text to look for.
curl "https://api.coinprice.dev/v2/search?query=doge" \ -H "Authorization: Bearer $API_KEY"const res = await fetch('https://api.coinprice.dev/v2/search?query=doge', { headers: { Authorization: `Bearer ${process.env.API_KEY}` },})console.log(await res.json())import os, requestsres = requests.get( 'https://api.coinprice.dev/v2/search?query=doge', headers={'Authorization': f"Bearer {os.environ['API_KEY']}"},)print(res.json())package mainimport ( "fmt" "io" "net/http" "os")func main() { req, _ := http.NewRequest("GET", "https://api.coinprice.dev/v2/search?query=doge", nil) req.Header.Set("Authorization", "Bearer "+os.Getenv("API_KEY")) res, err := http.DefaultClient.Do(req) if err != nil { panic(err) } defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(string(body))}Response 200
{
"coins": [
{
"api_symbol": "dogecoin",
"id": "dogecoin",
"large": null,
"market_cap_rank": null,
"name": "Dogecoin",
"symbol": "DOGE",
"thumb": null
}
]
}Search
List coin coverage
For every coin: whether it is traded and ranked, when we first saw it, and the first day of its hourly and daily history. minute_days is the minute window your plan allows, not what is held.
GET/v2/coverage
Parameters
per_pagequery- 1 to 250. Default 250.
pagequery- Page number, from 1.
curl "https://api.coinprice.dev/v2/coverage?per_page=1" \ -H "Authorization: Bearer $API_KEY"const res = await fetch('https://api.coinprice.dev/v2/coverage?per_page=1', { headers: { Authorization: `Bearer ${process.env.API_KEY}` },})console.log(await res.json())import os, requestsres = requests.get( 'https://api.coinprice.dev/v2/coverage?per_page=1', headers={'Authorization': f"Bearer {os.environ['API_KEY']}"},)print(res.json())package mainimport ( "fmt" "io" "net/http" "os")func main() { req, _ := http.NewRequest("GET", "https://api.coinprice.dev/v2/coverage?per_page=1", nil) req.Header.Set("Authorization", "Bearer "+os.Getenv("API_KEY")) res, err := http.DefaultClient.Do(req) if err != nil { panic(err) } defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(string(body))}Response 200
[
{
"active": true,
"daily_from": "2023-01-01",
"first_seen_at": 1795433433,
"hourly_from": "2023-01-01",
"id": "0x",
"minute_days": 90,
"ranked": true,
"symbol": "zrx"
}
]Futures
List futures
Perpetual futures with mark price, funding rate and open interest. index_id is the id of the coin the future is on, and index and basis come from its spot price. Fields we do not have (spread, 24h change) are null.
GET/v2/derivatives
Parameters
coinquery- A coin id, for example pepe. Only the futures of that coin; a 1000x contract such as kPEPE maps to pepe.
per_pagequery- 1 to 250. Default 100.
pagequery- Page number, from 1.
curl "https://api.coinprice.dev/v2/derivatives?coin=bitcoin&per_page=1" \ -H "Authorization: Bearer $API_KEY"const res = await fetch('https://api.coinprice.dev/v2/derivatives?coin=bitcoin&per_page=1', { headers: { Authorization: `Bearer ${process.env.API_KEY}` },})console.log(await res.json())import os, requestsres = requests.get( 'https://api.coinprice.dev/v2/derivatives?coin=bitcoin&per_page=1', headers={'Authorization': f"Bearer {os.environ['API_KEY']}"},)print(res.json())package mainimport ( "fmt" "io" "net/http" "os")func main() { req, _ := http.NewRequest("GET", "https://api.coinprice.dev/v2/derivatives?coin=bitcoin&per_page=1", nil) req.Header.Set("Authorization", "Bearer "+os.Getenv("API_KEY")) res, err := http.DefaultClient.Do(req) if err != nil { panic(err) } defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(string(body))}Response 200
[
{
"basis": 0.06951170306986065,
"contract_type": "perpetual",
"expired_at": null,
"funding_rate": 0.0005886,
"funding_rate_1h": 0.000005886,
"index": 60349.55,
"index_id": "bitcoin",
"last_traded_at": 1795505242,
"last_updated_at": 1795505242,
"mark_price": 60413,
"open_interest": 2258923348.0468197,
"price": "60391.5",
"price_percentage_change_24h": null,
"spread": null,
"symbol": "BTC",
"volume_24h": 4803691083.754914
}
]Futures
Get a future
One future by symbol.
GET/v2/derivatives/{symbol}
Parameters
symbolpathrequired- Futures symbol, for example BTC. The case does not matter.
curl "https://api.coinprice.dev/v2/derivatives/BTC" \ -H "Authorization: Bearer $API_KEY"const res = await fetch('https://api.coinprice.dev/v2/derivatives/BTC', { headers: { Authorization: `Bearer ${process.env.API_KEY}` },})console.log(await res.json())import os, requestsres = requests.get( 'https://api.coinprice.dev/v2/derivatives/BTC', headers={'Authorization': f"Bearer {os.environ['API_KEY']}"},)print(res.json())package mainimport ( "fmt" "io" "net/http" "os")func main() { req, _ := http.NewRequest("GET", "https://api.coinprice.dev/v2/derivatives/BTC", nil) req.Header.Set("Authorization", "Bearer "+os.Getenv("API_KEY")) res, err := http.DefaultClient.Do(req) if err != nil { panic(err) } defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(string(body))}Response 200
{
"basis": 0.06123809407151822,
"contract_type": "perpetual",
"expired_at": null,
"funding_rate": 0.0005886,
"funding_rate_1h": 0.000005886,
"index": 60354.54003,
"index_id": "bitcoin",
"last_traded_at": 1795505243,
"last_updated_at": 1795505243,
"mark_price": 60413,
"open_interest": 2258923348.0468197,
"price": "60391.5",
"price_percentage_change_24h": null,
"spread": null,
"symbol": "BTC",
"volume_24h": 4803691083.754914
}Futures
Get future candles
Hourly candles as [time in ms, open, high, low, close]. Any other interval is a 400.
GET/v2/derivatives/{symbol}/ohlc
Parameters
symbolpathrequired- Futures symbol, for example BTC. The case does not matter.
intervalquery- 1h only.
fromquery- Start of the window: Unix seconds (milliseconds above 1e11 also work), an ISO 8601 time or YYYY-MM-DD.
toquery- End of the window, in the same formats. Default now.
daysquery- A window ending now: a whole number from 1 to 36500, or max. Ignored when from is given.
limitquery- Rows to return, 1 to 5,000. Default 500.
curl "https://api.coinprice.dev/v2/derivatives/BTC/ohlc?limit=2" \ -H "Authorization: Bearer $API_KEY"const res = await fetch('https://api.coinprice.dev/v2/derivatives/BTC/ohlc?limit=2', { headers: { Authorization: `Bearer ${process.env.API_KEY}` },})console.log(await res.json())import os, requestsres = requests.get( 'https://api.coinprice.dev/v2/derivatives/BTC/ohlc?limit=2', headers={'Authorization': f"Bearer {os.environ['API_KEY']}"},)print(res.json())package mainimport ( "fmt" "io" "net/http" "os")func main() { req, _ := http.NewRequest("GET", "https://api.coinprice.dev/v2/derivatives/BTC/ohlc?limit=2", nil) req.Header.Set("Authorization", "Bearer "+os.Getenv("API_KEY")) res, err := http.DefaultClient.Do(req) if err != nil { panic(err) } defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(string(body))}Response 200
[
[
1795496400000,
60354,
60745,
60287,
60599
],
[
1795500000000,
60600,
60619,
60324,
60447
]
]Futures
Get funding rates
Hourly funding as [time in ms, rate_1h, open_interest].
GET/v2/derivatives/{symbol}/funding
Parameters
symbolpathrequired- Futures symbol, for example BTC. The case does not matter.
fromquery- Start of the window: Unix seconds (milliseconds above 1e11 also work), an ISO 8601 time or YYYY-MM-DD.
toquery- End of the window, in the same formats. Default now.
daysquery- A window ending now: a whole number from 1 to 36500, or max. Ignored when from is given.
limitquery- Rows to return, 1 to 5,000. Default 1,000.
curl "https://api.coinprice.dev/v2/derivatives/BTC/funding?limit=2" \ -H "Authorization: Bearer $API_KEY"const res = await fetch('https://api.coinprice.dev/v2/derivatives/BTC/funding?limit=2', { headers: { Authorization: `Bearer ${process.env.API_KEY}` },})console.log(await res.json())import os, requestsres = requests.get( 'https://api.coinprice.dev/v2/derivatives/BTC/funding?limit=2', headers={'Authorization': f"Bearer {os.environ['API_KEY']}"},)print(res.json())package mainimport ( "fmt" "io" "net/http" "os")func main() { req, _ := http.NewRequest("GET", "https://api.coinprice.dev/v2/derivatives/BTC/funding?limit=2", nil) req.Header.Set("Authorization", "Bearer "+os.Getenv("API_KEY")) res, err := http.DefaultClient.Do(req) if err != nil { panic(err) } defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(string(body))}Response 200
[
[
1795500000000,
0.0000057527,
37445.65172
],
[
1795503600000,
0.000005886,
37404.65708
]
]Predictions
List prediction markets
Crypto prediction markets with their probability.
GET/v2/predictions
Parameters
coinquery- A coin id. Only markets about that coin.
per_pagequery- 1 to 250. Default 100.
pagequery- Page number, from 1.
curl "https://api.coinprice.dev/v2/predictions?per_page=1" \ -H "Authorization: Bearer $API_KEY"const res = await fetch('https://api.coinprice.dev/v2/predictions?per_page=1', { headers: { Authorization: `Bearer ${process.env.API_KEY}` },})console.log(await res.json())import os, requestsres = requests.get( 'https://api.coinprice.dev/v2/predictions?per_page=1', headers={'Authorization': f"Bearer {os.environ['API_KEY']}"},)print(res.json())package mainimport ( "fmt" "io" "net/http" "os")func main() { req, _ := http.NewRequest("GET", "https://api.coinprice.dev/v2/predictions?per_page=1", nil) req.Header.Set("Authorization", "Bearer "+os.Getenv("API_KEY")) res, err := http.DefaultClient.Do(req) if err != nil { panic(err) } defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(string(body))}Response 200
[
{
"ask": null,
"bid": 0.22,
"coin": "bitcoin",
"id": "pm_fd22c127f832b059",
"kind": "above",
"last_updated_at": 1795504560,
"lower": 58400,
"open_interest": null,
"probability": 0.61,
"question": "Bitcoin above 58,400 on November 24, 3AM ET?",
"resolves_at": "2026-11-24T08:00:00Z",
"status": "trading",
"style": "at_time",
"symbol": "BTC",
"upper": null,
"venue_group": "b",
"volume": 0
}
]Predictions
Get a prediction market
One prediction market. The id in the example is a market that resolves, so list /v2/predictions for a current one.
GET/v2/predictions/{id}
Parameters
idpathrequired- A market id from /v2/predictions.
curl "https://api.coinprice.dev/v2/predictions/pm_fd22c127f832b059" \ -H "Authorization: Bearer $API_KEY"const res = await fetch('https://api.coinprice.dev/v2/predictions/pm_fd22c127f832b059', { headers: { Authorization: `Bearer ${process.env.API_KEY}` },})console.log(await res.json())import os, requestsres = requests.get( 'https://api.coinprice.dev/v2/predictions/pm_fd22c127f832b059', headers={'Authorization': f"Bearer {os.environ['API_KEY']}"},)print(res.json())package mainimport ( "fmt" "io" "net/http" "os")func main() { req, _ := http.NewRequest("GET", "https://api.coinprice.dev/v2/predictions/pm_fd22c127f832b059", nil) req.Header.Set("Authorization", "Bearer "+os.Getenv("API_KEY")) res, err := http.DefaultClient.Do(req) if err != nil { panic(err) } defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(string(body))}Response 200
{
"ask": null,
"bid": 0.22,
"coin": "bitcoin",
"id": "pm_fd22c127f832b059",
"kind": "above",
"last_updated_at": 1795504560,
"lower": 58400,
"open_interest": null,
"probability": 0.61,
"question": "Bitcoin above 58,400 on November 24, 3AM ET?",
"resolves_at": "2026-11-24T08:00:00Z",
"status": "trading",
"style": "at_time",
"symbol": "BTC",
"upper": null,
"venue_group": "b",
"volume": 0
}Predictions
Get prediction history
Probability over time as [time in ms, probability].
GET/v2/predictions/{id}/history
Parameters
idpathrequired- A market id from /v2/predictions.
fromquery- Start of the window: Unix seconds (milliseconds above 1e11 also work), an ISO 8601 time or YYYY-MM-DD.
toquery- End of the window, in the same formats. Default now.
daysquery- A window ending now: a whole number from 1 to 36500, or max. Ignored when from is given.
limitquery- Rows to return, 1 to 5,000. Default 1,000.
curl "https://api.coinprice.dev/v2/predictions/pm_fd22c127f832b059/history?limit=2" \ -H "Authorization: Bearer $API_KEY"const res = await fetch('https://api.coinprice.dev/v2/predictions/pm_fd22c127f832b059/history?limit=2', { headers: { Authorization: `Bearer ${process.env.API_KEY}` },})console.log(await res.json())import os, requestsres = requests.get( 'https://api.coinprice.dev/v2/predictions/pm_fd22c127f832b059/history?limit=2', headers={'Authorization': f"Bearer {os.environ['API_KEY']}"},)print(res.json())package mainimport ( "fmt" "io" "net/http" "os")func main() { req, _ := http.NewRequest("GET", "https://api.coinprice.dev/v2/predictions/pm_fd22c127f832b059/history?limit=2", nil) req.Header.Set("Authorization", "Bearer "+os.Getenv("API_KEY")) res, err := http.DefaultClient.Do(req) if err != nil { panic(err) } defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(string(body))}Response 200
[
[
1795500960000,
0.61
]
]Real-world assets
List real-world assets
Tokenized real-world assets: gold and US stocks. The price of an asset is the market price of its tokens, averaged by each token’s 24h volume.
GET/v2/rwas/list
Parameters
asset_typequery- stock, commodity or etf.
curl "https://api.coinprice.dev/v2/rwas/list" \ -H "Authorization: Bearer $API_KEY"const res = await fetch('https://api.coinprice.dev/v2/rwas/list', { headers: { Authorization: `Bearer ${process.env.API_KEY}` },})console.log(await res.json())import os, requestsres = requests.get( 'https://api.coinprice.dev/v2/rwas/list', headers={'Authorization': f"Bearer {os.environ['API_KEY']}"},)print(res.json())package mainimport ( "fmt" "io" "net/http" "os")func main() { req, _ := http.NewRequest("GET", "https://api.coinprice.dev/v2/rwas/list", nil) req.Header.Set("Authorization", "Bearer "+os.Getenv("API_KEY")) res, err := http.DefaultClient.Do(req) if err != nil { panic(err) } defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(string(body))}Response 200
[
{
"asset_type": "stock",
"id": "alphabet",
"name": "Alphabet",
"symbol": "GOOGL"
}
]Real-world assets
List real-world assets with prices
A page of assets with price, 24h and 7d change, 24h high and low and 24h volume under tokenized_market_data. Market cap and the 1h, 14d, 30d, 200d and 1y changes are null.
GET/v2/rwas/markets
Parameters
asset_typequery- stock, commodity or etf.
issuerquery- An issuer id from /v2/rwas/issuers/list.
idsquery- Comma-separated asset ids, up to 250. Wins over names and symbols.
namesquery- Comma-separated names, up to 250.
symbolsquery- Comma-separated symbols, up to 250.
include_non_tokenizedquery- true includes assets that have no price from a token.
orderquery- volume_desc (default; market_cap_desc is an alias), volume_asc, id_asc or id_desc.
per_pagequery- 1 to 250. Default 100.
pagequery- Page number, from 1.
curl "https://api.coinprice.dev/v2/rwas/markets?per_page=1" \ -H "Authorization: Bearer $API_KEY"const res = await fetch('https://api.coinprice.dev/v2/rwas/markets?per_page=1', { headers: { Authorization: `Bearer ${process.env.API_KEY}` },})console.log(await res.json())import os, requestsres = requests.get( 'https://api.coinprice.dev/v2/rwas/markets?per_page=1', headers={'Authorization': f"Bearer {os.environ['API_KEY']}"},)print(res.json())package mainimport ( "fmt" "io" "net/http" "os")func main() { req, _ := http.NewRequest("GET", "https://api.coinprice.dev/v2/rwas/markets?per_page=1", nil) req.Header.Set("Authorization", "Bearer "+os.Getenv("API_KEY")) res, err := http.DefaultClient.Do(req) if err != nil { panic(err) } defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(string(body))}Response 200
[
{
"asset_type": "commodity",
"id": "gold",
"image": null,
"name": "Gold",
"symbol": "xau",
"tokenized_market_data": {
"current_price": 3605.0897807875817,
"high_24h": 3665.4159793810727,
"last_updated": "2026-11-24T07:27:24Z",
"low_24h": 3600.3996670275883,
"market_cap": null,
"market_cap_change_24h": null,
"market_cap_change_percentage_24h": null,
"price_change_24h": -4.8752188945663875,
"price_change_percentage_14d_in_currency": null,
"price_change_percentage_1h_in_currency": null,
"price_change_percentage_1y_in_currency": null,
"price_change_percentage_200d_in_currency": null,
"price_change_percentage_24h": -0.13504892415842074,
"price_change_percentage_24h_in_currency": -0.13504892415842074,
"price_change_percentage_30d_in_currency": null,
"price_change_percentage_7d_in_currency": -6.500928198564204,
"total_volume": 90659370.96000001
}
}
]Real-world assets
List issuers
The companies that issue the tokens.
GET/v2/rwas/issuers/list
curl "https://api.coinprice.dev/v2/rwas/issuers/list" \ -H "Authorization: Bearer $API_KEY"const res = await fetch('https://api.coinprice.dev/v2/rwas/issuers/list', { headers: { Authorization: `Bearer ${process.env.API_KEY}` },})console.log(await res.json())import os, requestsres = requests.get( 'https://api.coinprice.dev/v2/rwas/issuers/list', headers={'Authorization': f"Bearer {os.environ['API_KEY']}"},)print(res.json())package mainimport ( "fmt" "io" "net/http" "os")func main() { req, _ := http.NewRequest("GET", "https://api.coinprice.dev/v2/rwas/issuers/list", nil) req.Header.Set("Authorization", "Bearer "+os.Getenv("API_KEY")) res, err := http.DefaultClient.Do(req) if err != nil { panic(err) } defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(string(body))}Response 200
[
{
"id": "paxos-ecosystem",
"name": "Paxos Global"
}
]Real-world assets
Get an issuer
One issuer with its tokens and their 24h volume.
GET/v2/rwas/issuers/{id}
Parameters
idpathrequired- An issuer id from /v2/rwas/issuers/list.
curl "https://api.coinprice.dev/v2/rwas/issuers/paxos-ecosystem" \ -H "Authorization: Bearer $API_KEY"const res = await fetch('https://api.coinprice.dev/v2/rwas/issuers/paxos-ecosystem', { headers: { Authorization: `Bearer ${process.env.API_KEY}` },})console.log(await res.json())import os, requestsres = requests.get( 'https://api.coinprice.dev/v2/rwas/issuers/paxos-ecosystem', headers={'Authorization': f"Bearer {os.environ['API_KEY']}"},)print(res.json())package mainimport ( "fmt" "io" "net/http" "os")func main() { req, _ := http.NewRequest("GET", "https://api.coinprice.dev/v2/rwas/issuers/paxos-ecosystem", nil) req.Header.Set("Authorization", "Bearer "+os.Getenv("API_KEY")) res, err := http.DefaultClient.Do(req) if err != nil { panic(err) } defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(string(body))}Response 200
{
"id": "paxos-ecosystem",
"image": null,
"market_cap": null,
"market_cap_change_24h": null,
"name": "Paxos Global",
"tokens": [
{
"id": "pax-gold",
"name": "PAX Gold",
"platforms": {},
"symbol": "paxg"
}
],
"updated_at": "2026-11-24T07:27:26Z",
"volume_24h": 27905982.1
}Real-world assets
Get a real-world asset
One asset. Add tokens=true to list its tokens (each has its own page under /v2/coins/{id}) and tokenized_market_data=true for its price.
GET/v2/rwas/{id}
Parameters
idpathrequired- An asset id from /v2/rwas/list, for example gold or nvidia.
tokensquery- true lists the tokens and their issuers.
tokenized_market_dataquery- true adds the price and changes.
perps_market_dataquery- true adds perpetual volume and open interest per token (with tokens=true); the asset-level total is null.
curl "https://api.coinprice.dev/v2/rwas/gold?tokens=true&tokenized_market_data=true" \ -H "Authorization: Bearer $API_KEY"const res = await fetch('https://api.coinprice.dev/v2/rwas/gold?tokens=true&tokenized_market_data=true', { headers: { Authorization: `Bearer ${process.env.API_KEY}` },})console.log(await res.json())import os, requestsres = requests.get( 'https://api.coinprice.dev/v2/rwas/gold?tokens=true&tokenized_market_data=true', headers={'Authorization': f"Bearer {os.environ['API_KEY']}"},)print(res.json())package mainimport ( "fmt" "io" "net/http" "os")func main() { req, _ := http.NewRequest("GET", "https://api.coinprice.dev/v2/rwas/gold?tokens=true&tokenized_market_data=true", nil) req.Header.Set("Authorization", "Bearer "+os.Getenv("API_KEY")) res, err := http.DefaultClient.Do(req) if err != nil { panic(err) } defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(string(body))}Response 200
{
"asset_type": "commodity",
"id": "gold",
"image": null,
"last_updated": "2026-11-24T07:27:28Z",
"name": "Gold",
"symbol": "xau",
"tokenized_market_data": {
"current_price": 3605.7098730461166,
"high_24h": 3665.4159793810727,
"last_updated": "2026-11-24T07:27:28Z",
"low_24h": 3600.3996670275883,
"market_cap": null,
"market_cap_change_24h": null,
"market_cap_change_percentage_24h": null,
"price_change_24h": -4.255126636031946,
"price_change_percentage_14d_in_currency": null,
"price_change_percentage_1h_in_currency": null,
"price_change_percentage_1y_in_currency": null,
"price_change_percentage_200d_in_currency": null,
"price_change_percentage_24h": -0.11787168674506354,
"price_change_percentage_24h_in_currency": -0.11787168674506354,
"price_change_percentage_30d_in_currency": null,
"price_change_percentage_7d_in_currency": -6.484845922080185,
"total_volume": 90659370.96000001
},
"tokens": [
{
"id": "tether-gold",
"issuer_details": {
"id": "tether-ecosystem",
"name": "Tether"
},
"name": "Tether Gold",
"platforms": {},
"symbol": "xaut"
}
],
"web_slug": "gold"
}Real-world assets
Get real-world asset prices
Price points as [time in ms, price] under tokenized_prices, oldest first, always in US dollars. The two other lists are empty.
GET/v2/rwas/{id}/market_chart
Parameters
idpathrequired- An asset id from /v2/rwas/list.
fromquery- Start of the window: Unix seconds (milliseconds above 1e11 also work), an ISO 8601 time or YYYY-MM-DD.
toquery- End of the window, in the same formats. Default now.
daysquery- A window ending now: a whole number from 1 to 36500, or max. Ignored when from is given.
limitquery- Points to return, 1 to 2,000. A longer window returns the newest points, so page back with from and to.
curl "https://api.coinprice.dev/v2/rwas/gold/market_chart?days=7&limit=2" \ -H "Authorization: Bearer $API_KEY"const res = await fetch('https://api.coinprice.dev/v2/rwas/gold/market_chart?days=7&limit=2', { headers: { Authorization: `Bearer ${process.env.API_KEY}` },})console.log(await res.json())import os, requestsres = requests.get( 'https://api.coinprice.dev/v2/rwas/gold/market_chart?days=7&limit=2', headers={'Authorization': f"Bearer {os.environ['API_KEY']}"},)print(res.json())package mainimport ( "fmt" "io" "net/http" "os")func main() { req, _ := http.NewRequest("GET", "https://api.coinprice.dev/v2/rwas/gold/market_chart?days=7&limit=2", nil) req.Header.Set("Authorization", "Bearer "+os.Getenv("API_KEY")) res, err := http.DefaultClient.Do(req) if err != nil { panic(err) } defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(string(body))}Response 200
{
"tokenized_market_caps": [],
"tokenized_prices": [
[
1794902400000,
3853.0271397564434
],
[
1794916800000,
3860.0738630845603
]
],
"tokenized_total_volumes": []
}