Trend Metrics
Latest Metrics
GET /api/metrics/:symbol/latest Everything ByteTree has worked out about one asset as of the latest day: its four ByteTrend scores, its trend regime, and its risk and return figures. The full record has around a hundred fields, but most people need only a handful — the fields most people need are listed first, and the complete reference follows.
Currency pairs work too (EURUSD): when no asset metrics exist for a pair, the endpoint answers from exchange-rate data. For currency-only work, Get FX Pair is the dedicated endpoint; for every asset in one call, use Latest Metrics — All Assets.
Example
curl https://api.bytetree.io/api/metrics/AAPL/latest \
-H "Authorization: Bearer YOUR_API_KEY" const res = await fetch("https://api.bytetree.io/api/metrics/AAPL/latest", {
headers: { "Authorization": "Bearer YOUR_API_KEY" },
});
const body = await res.json(); import requests
res = requests.get(
"https://api.bytetree.io/api/metrics/AAPL/latest",
headers={"Authorization": "Bearer YOUR_API_KEY"},
)
body = res.json() 200 Abridged to a few fields {
"symbol": "AAPL",
"data": {
"date": "2026-10-08T00:00:00.000Z",
"closeUsd": 340.42,
"capr": 0.0690073179136851,
"byteTrendCapr200w": 5,
"trendRegimeCapr200w": "Neutral",
"changeCapr200w": 0,
"byteTrendCapr30d": 5,
"trendRegimeCapr30d": "Leading Trend",
"trendAge200w": 213,
"returnUsd12M": 0.32981757099886716,
"volatility30w": 0.26342058099673504,
"...": "..."
}
} Crypto
curl https://api.bytetree.io/api/metrics/BTCUSD/latest \
-H "Authorization: Bearer YOUR_API_KEY" The fields most people need
| Field | What it tells you |
|---|---|
closeUsd |
Latest closing price, in US dollars |
byteTrendCapr200w |
Long-term (Weekly) trend score against the world market, 0–5 — the headline score |
byteTrendLocal200w |
Long-term (Weekly) trend score of the asset’s own price, 0–5 |
byteTrendCapr30d / byteTrendLocal30d |
The same two scores on the shorter-term (Daily) timescale |
confirmedRegimeCapr200w |
The trend label — Leading Trend, Emerging Trend, Weakening Trend, Bear Trend or Neutral — once it has held for five days in a row |
returnUsd1M / returnUsd12M |
Return over the last month / 12 months, as a decimal (0.05 is 5%) |
volatility30w |
How much the price swings, annualised, as a decimal — higher means bumpier |
drawdown52w |
How far the price sits below its 52-week high, as a decimal (0 or below) |
Key Concepts explains the scores and labels in plain terms. Every field is described in full under Response.
Path Parameters
| Name | Type | Required | Description |
|---|---|---|---|
symbol |
string |
Yes | Ticker symbol (e.g. AAPL, BTCUSD). Case-insensitive. |
Response
| Field | Type | Description |
|---|---|---|
symbol |
string |
The normalised (uppercase) symbol |
data |
object | null |
Latest metrics record, or null if no computed data exists |
The data object contains date, close, and all computed metric fields at the top level (see below).
All numeric fields default to adjusted close (split- and dividend-adjusted). Every time-series metric (MAs, slopes, rolling highs/lows, ByteTrend scores, deviations, drawdowns, returns, risk) and the quoted-state fields under Valuation (
closeUsd,capr,marketCapUsd) are all computed on adjusted close. Three explicit raw counterparts (closeRawUsd,caprRaw,marketCapRawUsd) are available for forensic / market-printed-price views. See the Data Model page for the exact adjustment contract and the Changelog for cutover history.
ByteTrend Scores (0–5)
Each score counts how many of five trend rules hold, so it runs from 0 to 5 — see ByteTrend score for how the rules work. There are four scores — two ways of measuring, each on two timescales:
- Local vs CAPR — local close vs CAPR (close ÷ MSCI World close)
- Weekly (
200w) vs Daily (30d) — long-horizon weekly windows vs short-horizon daily windows
| Field | UI Label | Windows | Description |
|---|---|---|---|
byteTrendLocal200w |
Local (Weekly) | 200w / 30w / 20w on close | Weekly ByteTrend on local price |
byteTrendLocal30d |
Local (Daily) | 200d / 30d / 20d on close | Daily ByteTrend on local price |
byteTrendCapr200w |
CAPR (Weekly) | 200w / 30w / 20w on CAPR | Weekly ByteTrend on CAPR |
byteTrendCapr30d |
CAPR (Daily) | 200d / 30d / 20d on CAPR | Daily ByteTrend on CAPR |
Each score has companion fields that share the same suffix:
*Rules— the five binary rules that compose the score (booleans:aboveMaLong,aboveMaShort,maLongRising,maShortRising,lastTouchMax)change*— day-over-day change (range −5 to +5)trendRegime*— trend regime classification (see Trend Regime)consec*5/consec*0— consecutive days at score 5 or 0
Full set per score, e.g. for Local (Weekly): byteTrendLocal200w, byteTrendLocal200wRules, changeLocal200w, trendRegimeLocal200w, consecLocal200w5, consecLocal200w0. Three equivalent sets exist for Local30d, Capr200w, Capr30d.
Moving Averages
Long/short SMAs for each dimension and window. Every suffix denotes the actual window of that field. Slopes measure day-over-day MA change (trend acceleration).
| Field | Description |
|---|---|
localMaLong200w / localMaShort30w |
200-week / 30-week SMA of local close |
localMaLong200d / localMaShort30d |
200-day / 30-day SMA of local close |
caprMaLong200w / caprMaShort30w |
200-week / 30-week SMA of CAPR |
caprMaLong200d / caprMaShort30d |
200-day / 30-day SMA of CAPR |
localMaLong200wSlope / localMaShort30wSlope |
Day-over-day slope of Weekly Local MAs |
caprMaLong200wSlope / caprMaShort30wSlope |
Day-over-day slope of Weekly CAPR MAs |
localMaLong200dSlope / localMaShort30dSlope |
Day-over-day slope of Daily Local MAs |
caprMaLong200dSlope / caprMaShort30dSlope |
Day-over-day slope of Daily CAPR MAs |
Rolling Highs & Lows
Two daily windows (used by Daily score regime classification and lastTouchMax rule respectively) and two weekly windows (the 20-week rolling high/low and 200-week trend context).
| Field | Description |
|---|---|
localMax20d / localMin20d |
20-day rolling high/low on local close (used by Daily score’s lastTouchMax rule) |
caprMax20d / caprMin20d |
20-day rolling high/low on CAPR |
localMax30d / localMin30d |
30-day rolling high/low on local close (used by Daily score regime classification) |
caprMax30d / caprMin30d |
30-day rolling high/low on CAPR |
localMax20w / localMin20w |
20-week rolling high/low on local close |
caprMax20w / caprMin20w |
20-week rolling high/low on CAPR |
localMax200w |
200-week rolling high on local close |
caprMax200w |
200-week rolling high on CAPR |
Deviations
| Field | Description |
|---|---|
devFromLocalMaLong200w |
% deviation from 200-week local MA |
devFromCaprMaLong200w |
% deviation from 200-week CAPR MA |
devFromLocalHigh30d / devFromLocalLow30d |
% below 30-day high / above 30-day low (local) |
devFromCaprHigh30d / devFromCaprLow30d |
30-day CAPR equivalents |
devFromLocalHigh30w / devFromLocalHigh200w |
% below 30-week / 200-week high (local) |
devFromLocalLow30w |
% above 30-week low (local) |
devFromCaprHigh30w / devFromCaprHigh200w / devFromCaprLow30w |
CAPR equivalents |
Trend Regime
A trend regime labels a trend by its ByteTrend score and whether it is at a recent high or low — see Trend regime for how it is set.
| Field | Type | Description |
|---|---|---|
trendRegimeLocal200w / trendRegimeLocal30d |
string |
Trend regime for Weekly / Daily Local score |
trendRegimeCapr200w / trendRegimeCapr30d |
string |
Trend regime for Weekly / Daily CAPR score |
confirmedRegimeCapr200w |
string |
Weekly CAPR regime (trendRegimeCapr200w) that has persisted for ≥ 5 consecutive days (absorbs short flip-flops) |
pendingRegimeCapr200w |
string | null |
Candidate Weekly CAPR regime waiting on the 5-day confirmation threshold; null once it promotes to confirmedRegimeCapr200w |
pendingRegimeCount200w |
number |
Days the current pendingRegimeCapr200w has been pending |
trendAge200w |
number |
Days the current confirmedRegimeCapr200w has been in force, counted from its first day — so it reads 5 on the day a new regime is confirmed |
consecLocal200w5 / consecLocal200w0 |
number |
Consecutive days at Weekly Local score 5 or 0 |
consecLocal30d5 / consecLocal30d0 |
number |
Consecutive days at Daily Local score 5 or 0 |
consecCapr200w5 / consecCapr200w0 |
number |
Consecutive days at Weekly CAPR score 5 or 0 |
consecCapr30d5 / consecCapr30d0 |
number |
Consecutive days at Daily CAPR score 5 or 0 |
Every regime field takes one of five labels, the same for all four scores: Leading Trend, Emerging Trend, Weakening Trend, Bear Trend or Neutral.
Trend Quality & Conviction
| Field | Type | Description |
|---|---|---|
divergenceLocal |
number |
Daily Local − Weekly Local divergence (positive = Daily stronger) |
divergenceCapr |
number |
Daily CAPR − Weekly CAPR divergence |
scoreVelocity5d200w |
number |
5-day average change in byteTrendLocal200w |
volumeConfirmation30d |
number |
Current volume / 30-day average volume (null for indices) |
cumulHighs12w |
number |
Count of new highs within trailing 12-week window |
Historical divergence values — before the 2026-04-22 cutover
divergenceLocal/divergenceCaprcompared the Daily score against a VWAP-weighted weekly score. They now compare Daily against the true 200w-window weekly score. Keys and units are unchanged, but values pre- and post-cutover are not directly comparable in historical series.
Risk Metrics
| Field | Type | Description |
|---|---|---|
volatility30w |
number |
Annualised 30-week volatility (√252 stocks, √365 crypto) |
volatilityPctFamily30w |
number | null |
Percentile rank (0–100) of volatility30w among active assets of the same type — stocks against stocks, crypto against crypto. Higher means more volatile than its peers. null for indices and for assets left out of the ranking (for example, no recent metrics) |
sharpe52w |
number |
Rolling 52-week Sharpe ratio (risk-free rate 3.5% by default) |
beta52w |
number |
Rolling 52-week beta vs MSCI World benchmark |
returnVolRatio |
number |
12-month return / 30-week volatility (risk-adjusted momentum) |
Drawdown
| Field | Type | Description |
|---|---|---|
drawdown52w |
number |
Current % below 52-week high (always ≤ 0) |
drawdownATH |
number |
Current % below adjusted-close all-time high (always ≤ 0) |
allTimeHighAdjUsd |
number |
Running all-time high in USD on adjusted close (post split/dividend adjustments) |
maxDrawdown30w |
number |
Worst peak-to-trough in trailing 30 weeks |
maxDrawdown52w |
number |
Worst peak-to-trough in trailing 52 weeks |
Performance Returns (USD)
| Field | Description |
|---|---|
returnUsd1W / returnUsd1M / returnUsd3M / returnUsd6M / returnUsd12M |
Backward-looking returns as decimals (0.05 = 5%) |
returnFwdUsd1D |
Forward 1-day return (filled retroactively for backtesting) |
returnFwdUsd3D |
Forward 3-day return |
returnFwdUsd1W |
Forward 1-week return |
returnFwdUsd1M |
Forward 1-month return |
returnFwdUsd3M |
Forward 3-month return |
returnFwdUsd6M |
Forward 6-month return |
returnFwdUsd12M |
Forward 12-month return |
Relative Strength (vs MSCI World)
| Field | Description |
|---|---|
relStrengthRaw1M / relStrengthRaw3M / relStrengthRaw12M |
Asset return / benchmark return (unbounded) |
relStrengthCapped1M / relStrengthCapped3M / relStrengthCapped12M |
Log-scaled version for display |
Valuation
The default trio represents the latest quoted state on adjusted close — matching the basis used by every time-series metric on this page. The *Raw trio exposes the same values on raw close for forensic or audit consumers; see Data Model.
| Field | Type | Description |
|---|---|---|
closeUsd |
number |
Adjusted close price in USD |
capr |
number |
Currency-Adjusted Price Relative — adjusted USD close ÷ MSCI World adjusted close |
marketCapUsd |
number | null |
Market cap in USD on adjusted close |
closeRawUsd |
number |
Raw market-printed USD close (no split or dividend adjustment) |
caprRaw |
number |
Raw close ÷ MSCI World raw close |
marketCapRawUsd |
number | null |
Market cap in USD on raw close |
circulatingSupply |
number |
Crypto only: coins in circulation, the figure behind crypto marketCapUsd. The key is absent for other asset types |
Notes
- Returns the most recent record that has computed metrics; dates without a completed computation run are skipped
- For an asset, the newest row is dated the previous day (UTC) at the latest. A crypto row’s
closeUsd,caprand ByteTrend scores are normally final once published; they change only if the index publisher corrects a past price. Forward returns (returnFwd*) still fill in as their windows pass, as for every type - ByteTrend scores read 5 Strong Bullish · 4 Bullish · 3 Neutral-Bullish · 2 Neutral-Bearish · 1 Bearish · 0 Strong Bearish
- Returns
200withdata: nullif no computed data exists for the symbol, including a symbol ByteTrend doesn’t track:{ "symbol": "NOSUCHSYM", "data": null }