> ## Documentation Index
> Fetch the complete documentation index at: https://docs.glider.fi/llms.txt
> Use this file to discover all available pages before exploring further.

# tRPC Fund Composition API

> Top holdings of the fund underlying an ETF ticker.

The `fundComposition.*` namespace serves the composition ("what's in this
fund") of the fund underlying a ticker. Data comes from Massive ETF Global
(constituents and profiles), which covers the broad US ETF universe and
refreshes roughly daily upstream.

* Base endpoint: `POST /v1/trpc`
* Namespace: `fundComposition.*`
* Auth: public (rate-limited, Tier 2)
* Display data only: composition never feeds pricing or execution.

## Procedures

* `fundComposition.getByTicker`
  * Purpose: the symbol page's "Fund composition" panel for ETFs
  * Input:
    * required `ticker`: underlying fund ticker (e.g. `AGG`); normalized to
      uppercase
  * Source: Massive ETF Global constituents (latest processed\_date
    snapshot; upstream `weight` fractions are converted to percent)
  * Response: `null` when the ticker has no constituent data (plain
    stocks, uncovered funds) or the entitlement is unavailable, so clients
    render nothing rather than an empty panel. Otherwise:
    * `asOf`: provider snapshot date (effective/processed date), or `null`
      when unreported
    * `source`: provider slug, currently always `etf-global`
    * `coveragePct`: sum of the returned holdings' weights — how much of
      the fund the response covers. Diversified funds can be small;
      clients must not renormalize weights to 100%.
    * `holdings`: up to ten rows, heaviest first:
      * `name`: display name (provider all-caps names are title-cased
        server-side)
      * `symbol`: underlying ticker for listed securities, else `null`
        (bonds, cash sleeves)
      * `weightPct`: percent of the whole fund (`0.42` = 0.42%)

* `fundComposition.getExposures`
  * Purpose: the symbol page's "Exposure" panel (Sectors / Countries tabs)
    plus the fund presentation of Key metrics and About (profile facts)
  * Input: required `ticker`
  * Source: Massive ETF Global profiles (sector\_exposure and
    geographic\_exposure arrive as fraction dicts and are converted to
    percent rows; country labels are ISO codes localized client-side)
  * Response: `null` when the ticker has no ETF Global profile or the
    entitlement is unavailable. Otherwise:
    * `asOf`: provider snapshot date, or `null`
    * `source`: provider slug, currently always `etf-global`
    * `aumUsd`: assets under management in USD, or `null`
    * `expenseRatioPct`: total expense ratio in percent points
      (`0.09` = 0.09%), or `null`
    * `sectors` / `countries`: `[{ label, weightPct }]` provider-reported
      percentages sorted descending; either list may be empty (the facts
      below still populate)
    * `facts`: fund-level profile facts, or `null`:
      * `fundName`: full fund name ("SPDR S\&P 500 ETF Trust")
      * `issuer`, `benchmark`, `assetClass`, `category`, `focus`:
        provider display strings, each nullable
      * `productType`: lowercase `etf`/`etn`
      * `managementClassification`: lowercase `active`/`passive`
      * `leverageFactor`: multiplier (`3` = 3x, negative = inverse),
        `null` when unleveraged
      * `inceptionDate`: `yyyy-mm-dd`
      * `distributionFrequency`: provider schedule code (`M`, `Q`, …)
      * `numHoldings`, `avgDailyVolumeShares`: nullable numbers
      * `netExpenseRatioPct`: net of fee waivers, percent points
      * `ttmDividendYieldPct`: trailing-12-month distribution yield in
        percent points, derived from Massive dividends and the snapshot
        price (funds are absent from the ratios endpoint); `null` when
        distributions or price are unavailable

* `fundComposition.getDistributions`
  * Purpose: backward-compatible fund namespace for dividend history; new
    symbol-page clients use `tradFiMarketData.getDividends` for both stocks and
    funds
  * Input: required `ticker`
  * Source: delegates to the instrument-neutral Massive dividend-history read
    documented under `tradFiMarketData.getDividends`
  * Response: `null` when there is no market-data source or the ticker
    has no payable cash distributions. Otherwise:
    * `annual`: ascending calendar years, at most the current year plus
      the nine before it: `{ year, totalPerShareUsd, partial }` where
      `partial` marks the in-progress current year
    * `avgYield5yPct`: average annual yield in percent points over the
      last five complete calendar years (each year's distributions over
      its year-end monthly close, from Massive aggregate bars); `null`
      when price history or distributions are unavailable
    * `recent`: the last payments, newest first, capped at ten:
      `{ exDate, payDate|null, amountPerShareUsd }`
