Skip to main content
GET
/
api
/
v1
/
dashboard
curl --request GET \
  --url "https://app.tingting.io/api/v1/dashboard/?days=30" \
  --header "Authorization: Bearer <token>"
{
    "total_credits_purchased": 1000,
    "credits_used": 450,
    "remaining_credits": 550,
    "campaigns": {},
    "outbound_calls": 1200,
    "outbound_sms": 300,
    "total_call_duration": "05:30:00",
    "total_owned_numbers": 5,
    "total_playback": {},
    "credit_spent": 0.375,
    "top_performing_campaign": {},
    "playback_distribution": {},
    "campaign_type_ratio": {},
    "call_outcomes": {},
    "credit_usage_overtime": []
}

Dashboard stats

Returns a snapshot of your account activity over a configurable time window. Use this endpoint to build reporting dashboards or monitor credit consumption and campaign health.

Authentication

All requests require a Bearer token in the Authorization header. See Authentication for details.

Query parameters

days
integer
Number of days to compute stats over. If omitted, the API returns stats for the default period.

Response fields

total_credits_purchased
integer
Total credits purchased on your account.
credits_used
integer
Credits consumed over the requested period.
remaining_credits
integer
Credits remaining on your account.
campaigns
object
Campaign statistics for the requested period.
outbound_calls
integer
Total number of outbound calls made.
outbound_sms
integer
Total number of outbound SMS messages sent.
total_call_duration
string
Combined duration of all calls, formatted as HH:MM:SS (e.g. "05:30:00").
total_owned_numbers
integer
Number of phone numbers currently assigned to your account.
total_playback
object
Aggregated playback statistics across all campaigns.
credit_spent
number
Total credits spent, expressed as a decimal (e.g. 0.375).
top_performing_campaign
object
Details of the best-performing campaign in the requested period.
playback_distribution
object
Breakdown of call playback events by type or outcome.
campaign_type_ratio
object
Ratio of campaign types run in the requested period.
call_outcomes
object
Breakdown of call results (e.g. answered, unanswered, failed).
credit_usage_overtime
array
Time-series data of credit consumption. Each entry represents usage at a point in time.
curl --request GET \
  --url "https://app.tingting.io/api/v1/dashboard/?days=30" \
  --header "Authorization: Bearer <token>"
{
    "total_credits_purchased": 1000,
    "credits_used": 450,
    "remaining_credits": 550,
    "campaigns": {},
    "outbound_calls": 1200,
    "outbound_sms": 300,
    "total_call_duration": "05:30:00",
    "total_owned_numbers": 5,
    "total_playback": {},
    "credit_spent": 0.375,
    "top_performing_campaign": {},
    "playback_distribution": {},
    "campaign_type_ratio": {},
    "call_outcomes": {},
    "credit_usage_overtime": []
}