Get In Call Payments
GET
/api/v1/in-call-payments
const url = 'https://api.ultimateteam.ai/api/v1/in-call-payments?period=7d';const options = {method: 'GET', headers: {'X-API-Key': '<X-API-Key>'}};
try { const response = await fetch(url, options); const data = await response.json(); console.log(data);} catch (error) { console.error(error);}curl --request GET \ --url 'https://api.ultimateteam.ai/api/v1/in-call-payments?period=7d' \ --header 'X-API-Key: <X-API-Key>'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
Section titled “Authorizations”Parameters
Section titled “ Parameters ”Query Parameters
Section titled “Query Parameters”period
Period
string
Responses
Section titled “ Responses ”Successful Response
Media typeapplication/json
InCallPaymentMetrics
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
followup_conversion_rate
required
Followup Conversion Rate
number
in_call_conversion_rate
required
In Call Conversion Rate
number
period_days
required
Period Days
integer
sample_count_followup
required
Sample Count Followup
integer
sample_count_in_call
required
Sample Count In Call
integer
total_followup_cents
required
Total Followup Cents
integer
total_in_call_cents
required
Total In Call Cents
integer
Examplegenerated
{ "avg_days_to_collect_followup": 1, "avg_days_to_collect_in_call": 1, "followup_conversion_rate": 1, "in_call_conversion_rate": 1, "period_days": 1, "sample_count_followup": 1, "sample_count_in_call": 1, "total_followup_cents": 1, "total_in_call_cents": 1}Validation Error
Media typeapplication/json
HTTPValidationError
object
detail
Detail
Array<object>
ValidationErrorobject
ctx
Context
object
input
Input
loc
required
Location
Array
msg
required
Message
string
type
required
Error Type
string
Examplegenerated
{ "detail": [ { "ctx": {}, "input": "example", "loc": [ "example" ], "msg": "example", "type": "example" } ]}