feat: add billing type tracking and cost enhancements

Add AdapterBillingType (api/subscription/unknown) to adapter execution results
so the system can distinguish API-billed vs subscription-billed runs. Enhance
cost service to aggregate subscription vs API run counts and token breakdowns.
Add limit param to heartbeat runs list API and client.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
Forgotten
2026-02-25 21:35:44 -06:00
parent 20a4ca08a5
commit 45c4df7b8a
8 changed files with 104 additions and 13 deletions

View File

@@ -29,4 +29,8 @@ export interface CostByAgent {
costCents: number;
inputTokens: number;
outputTokens: number;
apiRunCount: number;
subscriptionRunCount: number;
subscriptionInputTokens: number;
subscriptionOutputTokens: number;
}