Skip to content

Get In Call Payments

GET
/api/v1/in-call-payments

Return in-call vs follow-up collection metrics for the period.

Args: period: One of 7d, 30d, 90d. FastAPI returns 422 on any other value via the Literal validator. current_tenant: Authenticated tenant context (RLS boundary). session: Async SQLAlchemy session.

Returns: :class:InCallPaymentMetrics scoped to the tenant.

Authorizations

Parameters

Query Parameters

period
string
default: 30d
Allowed values: 7d 30d 90d

Responses

200

Successful Response

Aggregated collection metrics for a tenant over a period window.

All monetary values are cents. Conversion rates are 0.0-1.0 inclusive. avg_days_to_collect_* is None when the corresponding sample_count_* is zero — division by zero is not a zero, it’s undefined, and the frontend renders a dash.

object
avg_days_to_collect_followup
required
Any of:
number
avg_days_to_collect_in_call
required
Any of:
number
followup_conversion_rate
required
number
<= 1
in_call_conversion_rate
required
number
<= 1
period_days
required
integer
> 0
sample_count_followup
required
integer
sample_count_in_call
required
integer
total_followup_cents
required
integer
total_in_call_cents
required
integer

422

Validation Error

object
detail
Array<object>
object
ctx
object
input
loc
required
Array
msg
required
string
type
required
string