Skip to main content

Share-count reconciliation

Per (customer, instrument) tie-out of ledger share quantity vs live ViewTrade position quantity.

Why the cash recon isn't enough

The ledger's cash recon proves the DOLLAR totals match. But two different trade histories could produce the same cash total. Share counts are what prove the trade history itself.

Also: trade ingest is forward-only. A missed opening buy is exactly the failure mode this catches — the customer holds shares at ViewTrade the ledger has zero cost basis for.

The four states per instrument

StatusMeaning
matchLedger and ViewTrade agree (within tolerance)
mismatchBoth non-zero, different amounts — usually fractional-share drift or corp action
ledger_onlyLedger has shares, ViewTrade doesn't — likely a missed sell
viewtrade_onlyViewTrade has shares, ledger doesn't — missing buy ingest

Matches don't surface in the detail (too noisy). Only the non-matches show up.

What the report tends to surface

Occasional fractional-share drift where ledger qty and VT qty disagree by a small amount. Common causes:

  • A missed sell on ingest (ledger_only).
  • A corp-action-adjusted holding on the VT side (split, spinoff).
  • Dust from fractional-share arithmetic.

Each real mismatch is a signal to investigate. The posting-time ingest is the source of truth once fixed.

Where to see it

  • Frontend: the Holdings recon panel on /reconciliation (India book).
  • API: GET /v1/india/holdings-recon.
  • Related: the LRS ↔ ViewTrade tie-out does the cash side of the same problem.