Usage
Get your credit usage
/v1/integration/platform/usageYour credit balance, and the credits you bought and used in a period, by client. One AI Interview uses one credit. Requires an API key with the `usage:read` scope.
Requires an Alfa API key as a bearer token. How API keys work
Query parameters
fromstringThe start of the period. Defaults to the start of the current month (UTC).
format date-time
tostringThe end of the period, excluded. Defaults to now.
format date-time
Response body
fromstringrequiredThe start of the period.
tostringrequiredThe end of the period, excluded.
balanceintegerrequiredCredits purchased minus credits used, all time. Negative once you use more than you bought; the overage is invoiced.
purchasedintegerrequiredCredits purchased in the period.
usedintegerrequiredCredits used in the period: one per AI Interview.
clientsobject[]requiredUsage by client in the period, highest first.
Show fields
companyIdstringrequiredThe client’s Company ID.
externalClientIdstring | nullrequiredYour id for the client.
namestring | nullrequiredThe client company name.
usedintegerrequiredCredits the client used in the period.
interviewsintegerrequiredAI Interviews in the period.
Responses
- 200Success.
- 400The request is malformed: invalid JSON, an unexpected body or an unknown query parameter. Problem details
- 401The bearer token is missing, expired or invalid. Problem details
- 403The caller may not perform this operation, or has no active organisation. Problem details
- 404The resource does not exist or is not visible to the caller. Problem details
- 422The request failed validation; `errors` lists each invalid field. Problem details
- 429Too many requests, or the AI service is busy. Retry after a short wait. Problem details
- 500An unexpected error. Quote the `correlationId` to support. Problem details