MCPcopy
hub / github.com/midday-ai/midday / TeamCollectionMetrics

Interface TeamCollectionMetrics

packages/db/src/queries/reports.ts:2489–2493  ·  view source on GitHub ↗

* Calculate team's actual historical collection metrics from paid invoices. * Used to adjust collection probability based on real payment behavior.

Source from the content-addressed store, hash-verified

2487 * Used to adjust collection probability based on real payment behavior.
2488 */
2489interface TeamCollectionMetrics {
2490 onTimeRate: number; // Percentage paid on or before due date
2491 avgDaysToPay: number; // Average days from issue to payment
2492 sampleSize: number; // Number of invoices in calculation
2493}
2494
2495async function getTeamCollectionMetrics(
2496 db: Database,

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected