Skip to content

InteractionProcessTokenUsage

The tokens one agent turn of an interaction run used: the breakdown by kind (input, output, cache, reasoning), the provider and model that served it, the agent, and the key it ran on.

Kind: an object, used in responses.

Every field is present in a response; empty ones are null.

FieldTypeDescription
turnIduuidThe record’s own id. A turn that moved to another key or model part-way has one record for each, and a summary of the conversation has its own, so don’t treat it as an id for the turn.
datedatetimeWhen the call completed (UTC).
providerstringThe provider that served the call, such as Anthropic or OpenAi.
modelstringThe model used for the call.
agentNamestringThe participant whose turn used the tokens.
agentIduuid | nullThe agent that made the call, when it may differ from the participant’s own: a router’s choice takes the turn, and the routing call itself is the router’s. Null for Maitento’s own work, such as summarising the conversation or memory.
usagesInteractionTokenUsageItem[]The tokens used, by kind: input, output, cache_read, cache_creation_5m, cache_creation_1h and reasoning. Added to as the turn goes.
finishedbooleanTrue once the turn has completed. False while it is still going; a record left false means the turn was cut off, and its counts are what was recorded before that.
credentialIdstring | nullThe credentialId of the key that served the turn, maitento-fallback for Maitento’s own key, or null when no key applies (such as a self-hosted model).
isOwnLicensebooleanTrue when the turn ran on a key of your own; false for Maitento’s own key, or when unknown.
tierstring | nullThe pricing tier of the call, for a model priced in tiers. Null when there is none.
{
"turnId": "3f2b8c1e-5d4a-4e6b-9c7d-2a1b0c9d8e7f",
"date": "2026-10-26T12:00:00.0000000Z",
"provider": "...",
"model": "...",
"agentName": "...",
"agentId": "3f2b8c1e-5d4a-4e6b-9c7d-2a1b0c9d8e7f",
"usages": [
{
"type": "...",
"count": 0
}
],
"finished": false,
"credentialId": "...",
"isOwnLicense": false,
"tier": "..."
}