For AI agents: the documentation index is at /llms.txt, and this page is available as Markdown at /api/market-data/get-price-indicators.md.

Get a technical indicator series

GET
/v1/defi/market/prices/indicators

Returns one or more technical indicator lines computed from the asset's close prices.

The requested window is widened internally by the indicator's warm-up depth and trimmed back before responding, so the first returned point is already converged rather than carrying seed bias. The window is measured back from the most recent available point, so a feed lagging behind the current time still returns a full window.

lines is keyed by line name. Single-line indicators (sma, ema, rsi, atr) return one entry named after the indicator. macd returns macd, signal and histogram; bollinger returns upper, middle, lower and percent_b.

atr reads OHLC candles rather than closes, so it is only available for assets whose price source stores individual ticks; anything else returns 400. It is Wilder-smoothed and defaults to a period of 14.

The momentum measures cover fixed spans rather than a caller-supplied period, which is rejected for them. surging_1h, surging_4h and surging_24h are the percent price change over that span, so the resolution must be coarse enough for the span to fit in 400 buckets — the same bound a supplied period carries. trending_ratio is average reported 24h volume over the last 6 hours divided by its 30-day average, so it needs a CoinGecko-mapped asset and a resolution of at least 1h.

VWAP is not offered: it needs per-bucket traded volume, which no price series carries.

Query Parameters

asset_id?string

Backend asset ID. Mutually exclusive with symbol: exactly one of the two is required, and naming both is a 400.

Formatuuid
symbol?stringDeprecated

Asset symbol (e.g. SOL, BTC)

indicator*string
Value in"sma""ema""rsi""macd""bollinger""atr""surging_1h""surging_4h""surging_24h""trending_ratio"
window?string

Time window for the series (e.g. 1d, 7d, 1M)

Default"1h"
resolution?string

Candle size the period counts in (e.g. 1m, 1h, 1d)

Default"1m"
period?integer

Lookback in candles. Required for sma, ema and rsi; defaults to 20 for bollinger and 14 for atr, and is not used by macd. Rejected for the momentum measures, which cover a fixed span.

Range1 <= value <= 400
fast_period?integer

MACD fast EMA length. Defaults to 12.

Range1 <= value <= 400
slow_period?integer

MACD slow EMA length. Defaults to 26; must exceed fast_period.

Range1 <= value <= 400
signal_period?integer

MACD signal EMA length. Defaults to 9.

Range1 <= value <= 400
std_dev?number

Bollinger band width in standard deviations. Defaults to 2.

Range0 <= value
asset_class?string

Response Body

Indicator lines

application/json
  1. response
asset_id?string

Backend asset ID. Absent on the CeFi routes.

Formatuuid
symbol?string
window?string
resolution?string
indicator?string
lines?

Indicator lines keyed by line name

Example Request
curl -X GET 'https://api.truemarkets.co/v1/defi/market/prices/indicators?indicator=sma'
Example Response
{  "asset_id": "b4695157-0d1d-4da0-8f9e-5c53149389e4",  "symbol": "string",  "window": "string",  "resolution": "string",  "indicator": "string",  "lines": {    "property1": [      {        "t": "2019-08-24T14:15:22Z",        "value": "string"      }    ],    "property2": [      {        "t": "2019-08-24T14:15:22Z",        "value": "string"      }    ]  }}