List asset prices by interval
/v1/currency/pricesReturns the current price of every crypto asset in one quote currency, plus the price
one interval ago for each requested interval (for one_day, the price 24 hours
earlier). time is the epoch-millisecond timestamp of each point. The service caches
these results, so the live quote can be slightly behind the current time.
The outer key is the asset symbol. Each value is an array whose first entry is always
the live quote, without an interval field. One entry per requested interval
follows, in the order the intervals were requested, each carrying its interval. Use
the pairs to compute price changes over those periods.
price is a decimal string: the price of one unit of the asset in currency. "0"
means no price is available for that asset at that point, which is common for testnet
symbols.
No authentication is required.
Query Parameters
Quote currency symbol, fiat or crypto (for example EUR or USDT). Defaults to USD.
^[A-Z0-9]{2,10}$Historical points to add after the live quote. Repeat the parameter (interval=one_day&interval=one_week) or pass a comma-separated list (interval=one_day,one_week).
Response Body
application/json
application/json
curl --request GET \ --url 'https://gateway.bit2me.com/v1/currency/prices?currency=EUR&interval=one_day'{ "BTC": [ { "price": "67800.19999999999926788638554933", "time": 1788443700027 }, { "interval": "one_day", "price": "66414.8920197387747352951255467", "time": 1788356905602 } ], "ETH": [ { "price": "2088.46999999999964471649629925", "time": 1788443700027 }, { "interval": "one_day", "price": "2070.3587232438828648977352965", "time": 1788356905602 } ]}Get OHLC and average price for one asset GET
Returns open, high, low, close and average USD prices for one asset over a window that ends at `time` and spans `timeframe` backwards. With `timeframe=1D` and no `time`, the window is the last 24 hours. The symbol can be a crypto or a fiat currency. All prices are decimal strings in USD, derived from the stored rates against the dollar. `average` is the inverse of the mean rate over the window, which is a harmonic mean of the price rather than an arithmetic one. A value of `"0"` means the stored rate was zero. `404` means the service has no rates for that asset inside the window. No authentication is required.
List USD exchange rates GET
Returns exchange rates against the US dollar for every supported fiat and crypto symbol. Each rate is how many units of that currency equal one US dollar: `EUR: 0.86` means 1 USD = 0.86 EUR, and `BTC: 0.0000126` means 1 USD = 0.0000126 BTC. To convert an amount from A to B, multiply by `rate[B] / rate[A]`. The response is an array with one element per requested timestamp, in request order, or a single element for the current time when `time` is omitted. Each element has a `fiat` map, a `crypto` map, or both, depending on `type`. No authentication is required.