ByteTree API documentation

Get Asset

Look up one asset by its symbol — AAPL, BTCUSD — to get its name, classification and market value. You can also look it up by its internal ID.

Currency pairs such as EURUSD work too: when no asset record exists for a pair, the endpoint builds one from exchange-rate data — see Polymorphic FX fallback.

Request

# By symbol
curl https://api.bytetree.io/api/assets/AAPL

# By MongoDB ID
curl https://api.bytetree.io/api/assets/66f1a2b3c4d5e6f7a8b9c0d1

Path Parameters

NameTypeRequiredDescription
idstringYesMongoDB document ID or ticker symbol (case-insensitive)

Response

FieldTypeDescription
dataobjectThe asset document

The asset object has the same fields as entries in List Assets, including universes[] and the dimensions object described below — except the latest-metrics fields (mktCapUsd and the ByteTrend score, regime and change), which only list rows carry. For those, use Latest Metrics.

With ?format=csv the document renders as a single row; nested objects flatten to dotted column names (metadata.exchange) — see How CSV is shaped.

{
  "data": {
    "_id": "66f1a2b3c4d5e6f7a8b9c0d1",
    "symbol": "AAPL",
    "name": "Apple Inc.",
    "isin": "US0378331005",
    "type": "stock",
    "status": "active",
    "sector": "Technology",
    "industry": "Consumer Electronics",
    "country": "US",
    "region": "North America",
    "universes": ["bytetrend"],
    "dimensions": {
      "raw": { "sector": "Technology", "industry": "Consumer Electronics", "country": "US" },
      "override": { "sector": null, "industry": null, "country": null, "region": null }
    },
    "currency": "USD",
    "mktCap": 3900000000000
  }
}

Dimensions

region, sector, industry, country and type are the asset’s resolved values in the five global dimensions. type is ByteTree’s own classification and has no other layer. For the other four, the dimensions object exposes what the resolved value was built from:

FieldTypeDescription
dimensions.rawobjectProvider-native sector, industry, country (each string | null)
dimensions.overrideobjectPer-asset curated overrides for sector, industry, country, region (each string | null; null = no override). region has no raw slot because it is derived from country

The top-level value is the override where one is set, otherwise the raw value (mapped through the dimension’s mapping for region). Always present; all null inside when nothing has been recorded.

Polymorphic FX fallback

If the lookup :id is a valid FX pair symbol (e.g. EURUSD, GBPUSD) and no Asset document exists for it, the endpoint returns a synthesised row built from rate data. The shape matches a standard asset record, with asset-only fields (isin, sector, industry, country, region, mktCap) null. name spells out the two currencies (e.g. "Euro / US Dollar"), falling back to slash form (e.g. "AED/USD") where a currency’s name isn’t known, and the row carries base and quote currency codes, with baseName / quoteName where known. MongoDB-ID lookups are not synthesised — only symbol lookups trigger fallback.

For currency-only work, GET /api/fx/:symbol is the dedicated endpoint. This endpoint’s fallback exists for callers that resolve mixed asset types through a single path.

Errors

StatusDescription
404Asset not found and the symbol does not match a known FX pair