GET
/
market
/
history
Query
curl --request GET \
  --url https://api.app-mobula.com/api/1/market/history
{
  "price_history": [
    []
  ]
}

Query details

You must input a blockchain IF you send a smart-contract, but it’s not mandatory otherwise (blockchain format can be found here) - you can otherwise use the name of the asset if it’s listed in our metadata curated assets collection (+15,000 assets, adding tens everyday). In case of a naming collision, we will always take the asset with the highest market cap. Also note that if you’re querying with a from/to that doesn’t have any entry (because too close), we will revert with an empty array.

Data details

Price data is computed using Octopus, Mobula’s market data engine. You can have a high-level overview of how it’s computing DeFi prices here. Data granularity is designed as follows:

  • 5 minutes for the last 7 days
  • 6 hours for the last 30 days
  • 24 hours for the remaining of history

If you need higher granularity or control, please reach out to us on Telegram - we can deliver up to 1min granularity since 2013 for all assets.

Query Parameters

blockchain
string

Blockchain of the asset - only mandatory if asset is sent as smart-contract.

asset
string
required

The asset you want to target - asset name only works for assets listed on Mobula.

from
integer

JS Timestamp (miliseconds) of the beginning of the timeframe (if not provided, genesis)

to
integer

JS Timestamp (miliseconds) of the end of the timeframe (if not provided, end)

Response

200 - application/json
price_history
array