Trend Metrics
Latest Metrics — All Assets
GET /api/metrics/latest Every asset’s latest scores and metrics in a single call — the quickest way to fill a dashboard or a table of scores without asking for each asset in turn. Add ?type=fx for currency pairs instead.
Results are keyed by symbol and cover active assets by default.
Example
curl "https://api.bytetree.io/api/metrics/latest?type=fx" \
-H "Authorization: Bearer YOUR_API_KEY" const res = await fetch("https://api.bytetree.io/api/metrics/latest?type=fx", {
headers: { "Authorization": "Bearer YOUR_API_KEY" },
});
const body = await res.json(); import requests
res = requests.get(
"https://api.bytetree.io/api/metrics/latest?type=fx",
headers={"Authorization": "Bearer YOUR_API_KEY"},
)
body = res.json() 200 Abridged {
"count": 35,
"data": {
"EURUSD": {
"date": "2026-10-09T00:00:00.000Z",
"close": 1.12264,
"byteTrendCapr200w": 0,
"trendRegimeCapr200w": "Neutral",
"changeCapr200w": 0,
"...": "..."
},
"GBPUSD": {
"date": "2026-10-09T00:00:00.000Z",
"close": 1.32405,
"byteTrendCapr200w": 0,
"trendRegimeCapr200w": "Neutral",
"changeCapr200w": 0,
"...": "..."
},
"...": "..."
}
} Every active asset — about 21 MB, so prefer a type filter
curl https://api.bytetree.io/api/metrics/latest \
-H "Authorization: Bearer YOUR_API_KEY" Crypto only
curl "https://api.bytetree.io/api/metrics/latest?type=crypto" \
-H "Authorization: Bearer YOUR_API_KEY" Inactive stocks (default is active only; status has no effect on FX)
curl "https://api.bytetree.io/api/metrics/latest?type=stock&status=inactive" \
-H "Authorization: Bearer YOUR_API_KEY" Query Parameters
| Name | Type | Required | Description |
|---|---|---|---|
type |
string |
No | fx for currency pairs (rate-data-derived metrics for every tracked pair), or an asset type — stock, crypto, etf, index, commodity — to narrow the assets. Omit for every asset type |
status |
string |
No | Asset status filter: active (default), pending, or inactive. status has no effect on FX, but it must still be a valid value. |
An unknown type or status is a 400 — see Errors.
Size. The unfiltered map covers every active asset and is large — about 21 MB of JSON. Add a type filter unless you really need everything at once.
Response
Note: unlike most list endpoints on this API,
datais a plain object keyed by symbol, not an array. This is the single-shot dashboard shape — directdata[symbol]access is intentional.
| Field | Type | Description |
|---|---|---|
count |
number |
Number of symbols included |
data |
object |
Map of symbol → latest metric record |
Each value in data contains date, close, and all computed metric fields at the top level. See Latest Metrics for full field descriptions.
With ?format=csv the map renders as one row per symbol with a leading key column carrying the symbol — see How CSV is shaped.
Notes
- Without
type=fx, the map covers registered assets of the requestedstatus(defaultactive); withtype=fx, every tracked currency pair. Both share the same response envelope. - For per-symbol lookups use
/api/metrics/:symbol/latest; for an FX-scoped list with array envelope use/api/fx. - Symbols with no computed metrics in the last 7 days are omitted from
datarather than emitted withnullvalues. For one asset’s newest row whatever its age, use Latest Metrics.
Errors
| Status | When | Body |
|---|---|---|
400 |
type is not one of the five asset types or fx |
Invalid value for 'type': expected one of stock, crypto, etf, index, commodity, fx, received 'bogus'. |
400 |
status is not pending, active or inactive — also with type=fx |
Invalid value for 'status': expected one of pending, active, inactive, received 'bogus'. |