api.valarhq.ai.
Base URL
Authentication
Pass your API key as a Bearer token in theAuthorization header on every request.
The key here is identical to the one used by the inference API at
api.valarhq.ai. Generate and manage keys from the Valar
dashboard.Endpoints
The complete reference for each
GET /v1/usage route, covering parameters,
response shapes, error formats, and headers.Organization and workspace costs
By default,/v1/usage and /v1/usage/breakdown include all workspaces in your
organization, not just the workspace that owns your API key.
- Add
workspace_id=ws_...to either endpoint to filter costs to one workspace. - Add
group_by=workspaceto/v1/usage/breakdownto get workspace IDs, names, totals, and per-model costs in one response.
Expect a small lag in usage data - it is not reported in real time.