Skip to main content

Health & observability

How to check the ledger is healthy end-to-end, and what to look at in each report.

The health flow

Three checks tell you the whole book is healthy:

  1. Both backends respond ready. DB reachable, migrations at head.
  2. Trial balance balances. Category-A recon returns ok on both books.
  3. The India-only tables reconcile. No fail on Category-B or C checks.

What each report signals

ReportLook for
ViewTrade overviewTotal funding in/out, buy/sell counts, brokerage revenue vs ViewTrade payable
GlomoPay overviewTotal remitted (USD + INR), confirmed vs paid, FX-spread revenue, per-PAN LRS
TreasuryMerchant balance should be non-negative, live INR→USD rate
NAV / MTMValued vs no-link vs error counts, firm NAV, top positions
Capital gainsRealized STCG/LTCG, open lots, oversell warnings
DividendsEffective WHT % should be near the DTAA rate (~25%)
Schedule FAPer-asset acquisition + initial + peak (lower bound) + closing + income + WHT
LRS / TCSPer-PAN cap utilisation, TCS basis (actual/estimate/mixed)
Holdings reconReconciled vs flagged; mismatch / ledger-only / viewtrade-only counts
LRS ↔ ViewTrade reconmatched / in-transit / unmatched-funding + per-customer diff
Remittance exceptionsActionable count (non-zero = follow up)
Settlement auditMissing UTR count, uncoded purpose-code count, lag stats
Broker feesModeled vs expected vs actual drift, Daily-Ledger match rate
FX marginRealized vs assumed, drift, avg realized bps
ComplianceActive vs trading_halted vs error customer counts
Ledger reconPer-customer cash+sec variance vs live VT balance

Signals worth a follow-up

  • Any Category-A recon fail → trial balance broken. Highest priority.
  • error_count > 0 on NAV or Holdings recon → live broker fetch failed for some customers. Check the error field per row.
  • flagged_count > 0 on Ledger recon or Holdings recon → real drift. Investigate the flagged customers.
  • actionable_count > 0 on Remittance exceptions → a stuck / failed remittance needs someone.
  • missing_utr_count > 0 on Settlement audit → credited remittances with no bank reference. Check the settlement-fetch path.
  • uncoded_count > 0 on Settlement audit → upstream isn't populating LRS purpose codes.
  • tcs_basis = estimate on LRS/TCS → no quote tax captured; the report is falling back to the 20% estimate.
  • Large total_drift_usd on Broker fees → the flat-bps cost assumption is drifting from real fees. Consider a piecewise fee schedule.

Frontend health

Every page has a KPI header. If the numbers render, the endpoint is up. If a card shows an error, the response failed — check backend logs.