All Docs
FeaturesDepositClearUpdated March 11, 2026

Accurate Portfolio Stats on the Deduction Claims Page

Accurate Portfolio Stats on the Deduction Claims Page

Introduced in v0.1.143

Overview

The Deduction Claims index page displays a row of four summary stat cards at the top of the dashboard:

CardWhat it shows
Total ClaimsTotal number of deduction claims in the portfolio
In ProgressClaims currently being processed
Over-DeductingClaims flagged as deducting more than is evidenced
DisputedClaims where a formal dispute has been raised

Prior to v0.1.143, these counts were derived from the current page of paginated results (page size: 25). On portfolios with more than 25 claims, the Over-Deducting and Disputed counts were partial — they reflected only the claims loaded on screen, not the full portfolio.

What Changed

As of v0.1.143, the summary stats are driven by two separate data sources:

  • Total Claims — sourced from data?.total, the server-side count returned alongside every paginated response. This was already accurate and remains unchanged.
  • In Progress, Over-Deducting, Disputed — now sourced from a dedicated trpc.deductionClaims.stats query that runs independently of pagination and aggregates counts across the entire portfolio on the server.

This means the stat cards are always an accurate, real-time snapshot of your full portfolio's health — regardless of which page you are viewing or how many total claims exist.

Why This Matters

Under the Renters' Rights Act, agents and landlords have a duty to handle deposit deductions fairly and transparently. Summary figures that underrepresent over-deductions or active disputes could cause compliance issues to go unnoticed. Accurate portfolio-wide stats ensure that nothing is hidden by pagination.

Notes for Developers

  • The trpc.deductionClaims.stats endpoint returns portfolio-wide aggregated status counts and is independent of the paginated trpc.deductionClaims.list query.
  • Both queries run in parallel on page load — there is no additional waterfall latency.
  • If you are extending the stats row with additional status types, add the new status to the server-side aggregation in deductionClaims.stats rather than deriving it from the paginated releases array on the client.