Internal management API. These endpoints are authenticated via TutorFlow admin auth, not via Platform API keys.
GET /v1/platform/admin/stats
Get platform-wide aggregated statistics.
Query Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
startDate | string | No | ISO 8601 date to filter from |
endDate | string | No | ISO 8601 date to filter until |
service | string | No | Filter by service (e.g., evaluation, course) |
Example Request
curl "https://api.tutorflow.io/v1/platform/admin/stats?startDate=2025-01-01&endDate=2025-01-31" \
-H "Authorization: Bearer tf_platform_..."Response Fields
| Field | Type | Description |
|---|---|---|
totalOrganizations | number | Total number of organizations on the platform |
totalApiKeys | number | Total number of API keys issued |
totalRequests | number | Total number of API requests processed |
totalCreditCost | number | Total credits consumed across all organizations |
totalBillableAmountUsd | number | Total billable amount in USD |
totalFinalizedAmountUsd | number | Total finalized (invoiced) amount in USD |
totalInputTokens | number | Total input tokens consumed by AI models |
totalOutputTokens | number | Total output tokens produced by AI models |
byService | array | Breakdown of usage by service type |
byService[].service | string | Service name (e.g., evaluation, course) |
byService[].count | number | Number of requests for this service |
byService[].creditCost | number | Credits consumed by this service |
byService[].billableAmountUsd | number | Billable amount in USD for this service |
byService[].finalizedAmountUsd | number | Finalized amount in USD for this service |
Example Response
{
"totalOrganizations": 42,
"totalApiKeys": 87,
"totalRequests": 15230,
"totalCreditCost": 4521.75,
"totalBillableAmountUsd": 1892.40,
"totalFinalizedAmountUsd": 1650.00,
"totalInputTokens": 28450000,
"totalOutputTokens": 12300000,
"byService": [
{
"service": "evaluation",
"count": 12400,
"creditCost": 3100.00,
"billableAmountUsd": 1240.00,
"finalizedAmountUsd": 1100.00
},
{
"service": "course",
"count": 2830,
"creditCost": 1421.75,
"billableAmountUsd": 652.40,
"finalizedAmountUsd": 550.00
}
]
}GET /v1/platform/admin/stats/daily
Get daily usage breakdown for the platform.
Query Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
startDate | string | No | ISO 8601 date to filter from |
endDate | string | No | ISO 8601 date to filter until |
service | string | No | Filter by service |
Example Request
curl "https://api.tutorflow.io/v1/platform/admin/stats/daily?startDate=2025-01-01&endDate=2025-01-31" \
-H "Authorization: Bearer tf_platform_..."Response Fields
The response is an array of daily usage records.
| Field | Type | Description |
|---|---|---|
date | string | Date in YYYY-MM-DD format |
requests | number | Number of requests on this date |
creditCost | number | Credits consumed on this date |
billableAmountUsd | number | Billable amount in USD for this date |
finalizedAmountUsd | number | Finalized amount in USD for this date |
inputTokens | number | Input tokens consumed on this date |
outputTokens | number | Output tokens produced on this date |
Example Response
[
{
"date": "2026-01-15",
"requests": 523,
"creditCost": 156.75,
"billableAmountUsd": 65.30,
"finalizedAmountUsd": 58.00,
"inputTokens": 980000,
"outputTokens": 420000
},
{
"date": "2026-01-16",
"requests": 487,
"creditCost": 142.10,
"billableAmountUsd": 59.80,
"finalizedAmountUsd": 54.50,
"inputTokens": 910000,
"outputTokens": 395000
}
]GET /v1/platform/admin/stats/organizations
Get usage statistics ranked by organization. Returns up to 50 organizations sorted by usage volume (descending).
This endpoint does not currently accept query parameters. It returns all-time usage across all organizations.
Example Request
curl "https://api.tutorflow.io/v1/platform/admin/stats/organizations" \
-H "Authorization: Bearer tf_platform_..."Response Fields
The response is an array of organization usage summaries.
| Field | Type | Description |
|---|---|---|
organizationId | string | Unique identifier of the organization |
organizationName | string | Display name of the organization |
organizationSlug | string | URL-safe slug of the organization |
totalRequests | number | Total requests made by this organization |
totalCreditCost | number | Total credits consumed by this organization |
totalBillableAmountUsd | number | Total billable amount in USD |
totalFinalizedAmountUsd | number | Total finalized amount in USD |
Example Response
[
{
"organizationId": "b3f1a2c4-d5e6-7f8a-9b0c-1d2e3f4a5b6c",
"organizationName": "Acme University",
"organizationSlug": "acme-university",
"totalRequests": 4820,
"totalCreditCost": 1205.00,
"totalBillableAmountUsd": 502.10,
"totalFinalizedAmountUsd": 450.00
},
{
"organizationId": "c4d5e6f7-a8b9-0c1d-2e3f-4a5b6c7d8e9f",
"organizationName": "LearnCo Academy",
"organizationSlug": "learnco-academy",
"totalRequests": 3150,
"totalCreditCost": 892.50,
"totalBillableAmountUsd": 378.20,
"totalFinalizedAmountUsd": 340.00
}
]