AiUsageResult ai.usage-result@1
Generated at from
openvibe-contracts v0.53.0 and
openvibe-sdk v0.11.0.
- Version
- 1.0.0
- Owner
- ai
- Visibility
- first-party
- Status
- active
- Compatibility
- backward
- Schema
https://openvibe.network/contracts/ai/usage-result.v1.json
ai.usage-result@1: answers of ai.usage.read on OpenVibe.AI (all GETs, parameters in the query). GET /api/v1/status → { providers, runs, today, workflows, templates, routes, inflight, quotas }; GET /api/v1/usage?from=&to=&requester= → { usage } (daily rows); GET /api/v1/quotas → { quotas, current }; GET /api/v1/requests?provider=&status=&run=&fallback=&limit= → { requests } (request-log metadata: hashes, tokens, cost, latency; raw debug fields only for provider managers who ask); GET /api/v1/audit → { audit }; GET /api/v1/cache → { cache }; GET /api/v1/providers → { providers }; GET /api/v1/models?provider= → { models }. Never raw prompts, never secrets.
Fields
This schema has no named fields.
Examples
From the contract's own test fixtures: valid ones validate, rejected ones must fail.
Valid: models
{
"models": [
{
"provider_key": "anthropic",
"model_key": "claude-sonnet-4-5",
"display_name": "Claude Sonnet 4.5",
"type": "chat",
"status": "active",
"context_window": 200000,
"max_output": 64000,
"cost": {
"in_per_mtok": 3,
"out_per_mtok": 15,
"cached_per_mtok": 0.3
},
"supports": {
"json": true,
"tools": true,
"streaming": true,
"vision": true
},
"metadata": {},
"created_at": "2026-09-20T10:00:00.000Z",
"updated_at": "2026-09-20T10:00:00.000Z"
}
]
}Valid: status
{
"providers": [
{
"key": "anthropic",
"kind": "anthropic",
"status": "active",
"credentials": "configured",
"health": "closed"
}
],
"runs": {
"succeeded": 1203,
"failed": 7
},
"today": {
"day": "2026-09-25",
"requests": 311,
"cost_usd": 1.84
},
"workflows": 23,
"templates": 19,
"routes": 6,
"inflight": 2,
"quotas": []
}Rejected: partial-status
{
"runs": {
"succeeded": 1
}
}Validate
const contracts = require('openvibe-contracts');
contracts.validate('ai.usage-result@1', value); // { valid, errors: [{ path, message }] }