Skip to main content
GET
/
2
/
token
/
ohlcv-history
Get token OHLCV history
curl --request GET \
  --url https://demo-api.mobula.io/api/2/token/ohlcv-history
{
  "data": [
    {
      "v": 123,
      "o": 123,
      "h": 123,
      "l": 123,
      "c": 123,
      "t": 123
    }
  ]
}

FAQ

Mobula’s period is not the same format as TradingView’s ResolutionString. Treat them as different contracts and map values in your datafeed before calling Mobula.Often maps cleanly (Mobula normalizes case):
  • Seconds: TV 1S, 5S, … → Mobula 1s, 5s, …
  • Minute numerals: 1, 5, 15, 301m, 5m, 15m, 30m
  • Hour-style minute counts: 601h; 2404h; 3606h; 72012h
  • Days / weeks: 1D1d, 1W1w
Important mismatch — TV 1M (one month):
TradingView uses 1M for one month. Mobula lowercases the string, so 1M becomes 1m, which means one minute, not one month. Never forward TV’s monthly resolution unchanged.
Not a direct match:
  • Tick bars (1T, 5T, …) — Mobula serves time-based OHLCV candles, not tick aggregation.
  • Unrecognized strings — fall back to a default period (commonly 1h for unknown non-empty values, or the endpoint’s own default such as 5m when period is omitted).
Supported candle periods for this endpoint (canonical):
1s, 5s, 15s, 30s, 1m, 5m, 15m, 30m, 1h, 4h, 6h, 12h, 1d, 1w.
Aliases such as 5min or 601h are accepted by the API layer. Do not use 1month / TV-style monthly here: they normalize to 1M, which this OHLCV history service does not support.
Recommendation: Add an explicit tradingViewResolutionToMobulaPeriod(resolution) (or equivalent) in your integration instead of passing TV resolutions straight through.

Query Parameters

address
string
required

Token contract address

chainId
string

Blockchain chain ID (e.g., "evm:56", "solana:solana")

from

Start date (timestamp or ISO string)

to

End date (timestamp or ISO string)

period
string

Candle period (e.g., "5m", "1h", "1d")

amount
number | null

Maximum number of candles (max 2000)

usd

Return USD prices (default: true)

Response

200 - application/json

Token OHLCV history response

data
object[]
required