GET /api/metrics/:symbol Metric History
How an asset’s scores and metrics have changed, day by day — the history behind Latest Metrics. Ask for a date range with from and to, and use fields to return only the metrics you need; the full record is large.
Currency pairs work too (EURUSD): when no asset series exists for a pair, the endpoint answers from exchange-rate data. For currency-only work, FX Metric History is the dedicated endpoint.
Request
curl https://api.bytetree.io/api/metrics/AAPL
# With date range
curl "https://api.bytetree.io/api/metrics/BTCUSD?from=2026-01-01&to=2026-01-31"
# Select specific fields
curl "https://api.bytetree.io/api/metrics/AAPL?fields=closeUsd,byteTrendLocal200w,sharpe52w,drawdown52w"
Path Parameters
| Name | Type | Required | Description |
|---|---|---|---|
symbol | string | Yes | Ticker symbol (e.g. AAPL, BTCUSD). Case-insensitive. |
Query Parameters
| Name | Type | Required | Description |
|---|---|---|---|
from | string | No | Start date in YYYY-MM-DD format. Inclusive. |
to | string | No | End date in YYYY-MM-DD format. Inclusive. |
fields | string | No | Comma-separated list of metric keys to include (e.g. closeUsd,byteTrendLocal200w). Returns all fields if omitted. |
Response
| Field | Type | Description |
|---|---|---|
symbol | string | The normalised (uppercase) symbol |
count | number | Number of data points returned |
data | array | Array of daily metric objects |
Each data point contains date, close, and all computed metric fields at the top level (flattened — no nested metrics key).
All numeric fields default to adjusted close (split- and dividend-adjusted). Every time-series metric (MAs, scores, drawdowns, returns, risk) and the Valuation fields below (
closeUsd,capr,marketCapUsd) are computed on adjusted close. Three explicit raw counterparts (closeRawUsd,caprRaw,marketCapRawUsd) are available for forensic / market-printed-price views. See Data Model for the exact adjustment contract and the Changelog for cutover history.
Available Metric Fields
Use these keys with the fields query parameter. See Latest Metrics for full descriptions.
ByteTrend Scores (0–5):
byteTrendLocal200w, byteTrendLocal30d, byteTrendCapr200w, byteTrendCapr30d
Score Rules (booleans composing each score):
byteTrendLocal200wRules, byteTrendLocal30dRules, byteTrendCapr200wRules, byteTrendCapr30dRules
Daily Score Changes (−5 to +5):
changeLocal200w, changeLocal30d, changeCapr200w, changeCapr30d
Moving Averages:
localMaLong200w, localMaShort30w, localMaLong200d, localMaShort30d, caprMaLong200w, caprMaShort30w, caprMaLong200d, caprMaShort30d, localMaLong200wSlope, localMaShort30wSlope, localMaLong200dSlope, localMaShort30dSlope, caprMaLong200wSlope, caprMaShort30wSlope, caprMaLong200dSlope, caprMaShort30dSlope
Rolling Highs / Lows:
localMax20d, localMin20d, caprMax20d, caprMin20d, localMax30d, localMin30d, caprMax30d, caprMin30d, localMax20w, localMin20w, caprMax20w, caprMin20w, localMax200w, caprMax200w
Deviations:
devFromLocalMaLong200w, devFromCaprMaLong200w, devFromLocalHigh30d, devFromLocalLow30d, devFromCaprHigh30d, devFromCaprLow30d, devFromLocalHigh30w, devFromLocalHigh200w, devFromLocalLow30w, devFromCaprHigh30w, devFromCaprHigh200w, devFromCaprLow30w
Trend Regime:
trendRegimeLocal200w, trendRegimeLocal30d, trendRegimeCapr200w, trendRegimeCapr30d, confirmedRegimeCapr200w, pendingRegimeCapr200w, pendingRegimeCount200w, trendAge200w, consecLocal200w5, consecLocal200w0, consecLocal30d5, consecLocal30d0, consecCapr200w5, consecCapr200w0, consecCapr30d5, consecCapr30d0
Trend Quality:
divergenceLocal, divergenceCapr, scoreVelocity5d200w, volumeConfirmation30d, cumulHighs12w
Risk Metrics:
volatility30w, sharpe52w, beta52w, returnVolRatio
Drawdown:
drawdown52w, drawdownATH, allTimeHighAdjUsd, maxDrawdown30w, maxDrawdown52w
Performance Returns:
returnUsd1W, returnUsd1M, returnUsd3M, returnUsd6M, returnUsd12M, returnFwdUsd1D, returnFwdUsd3D, returnFwdUsd1W, returnFwdUsd1M, returnFwdUsd3M, returnFwdUsd6M, returnFwdUsd12M
Relative Strength:
relStrengthRaw1M, relStrengthRaw3M, relStrengthRaw12M, relStrengthCapped1M, relStrengthCapped3M, relStrengthCapped12M
Valuation (adjusted by default; *Raw siblings expose raw close):
closeUsd, capr, marketCapUsd, closeRawUsd, caprRaw, marketCapRawUsd
Notes
- Only dates that have completed computation runs are included; gaps in market data produce gaps in the series
dateandcloseare always returned regardless offieldsselection- Data is sorted chronologically (oldest first)
- Without
from/to, returns all available computed history for the symbol