ReportAiUsageMeResult report.ai-usage-me-result@1
Generated at from
openvibe-contracts v0.419.0 and
openvibe-sdk v0.161.0.
An older major, still in the catalog. The current one is
report.ai-usage-me-result@2.- Version
- 1.0.0
- Owner
- report
- Visibility
- public
- Status
- active
- Compatibility
- backward
- Schema
https://openvibe.network/contracts/report/ai-usage-me-result.v1.json
report.ai-usage-me-result@1: the AI usage of one person (plan L40/L41). GET /api/v1/me/ai/usage answers for the person themselves and nobody else: their rows, grouped by day, site, model, system or paid_by. The route answers 501 until Report has sign-in: the shape is fixed here first, so the route does not have to change when it opens.
Fields
| Field | Type | Required | Description | Constraints |
|---|---|---|---|---|
group | enum | yes |
| |
usage | array of object | yes |
| |
usage[].group | enum | yes |
| |
usage[].key | string | yes |
| |
usage[].calls | integer | yes |
| |
usage[].input | integer | yes |
| |
usage[].output | integer | yes |
| |
usage[].reasoning | integer | yes |
| |
usage[].cache_read | integer | yes |
| |
usage[].cache_write | integer | yes |
| |
usage[].list_cost_usd | number | yes |
| |
usage[].charged_usd | number | yes |
| |
usage[].fee_usd | number | yes |
| |
usage[].cache_saved_usd | number | yes |
| |
totals | object | yes |
Examples
From the contract's own test fixtures: valid ones validate, rejected ones must fail.
The fixtures that ship with the package are the current major's.
Validate
const contracts = require('openvibe-contracts');
contracts.validate('report.ai-usage-me-result@1', value); // { valid, errors: [{ path, message }] }