Skip to main content
Need your Valar usage figures inside a script, CLI tool, or custom dashboard? The Usage API exposes them directly. It authenticates with the very same key that powers your calls to api.valarhq.ai.

Base URL

https://usage.valarhq.ai

Authentication

Pass your API key as a Bearer token in the Authorization 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.
import requests

headers = {"Authorization": "Bearer YOUR_VALAR_API_KEY"}
resp = requests.get("https://usage.valarhq.ai/v1/usage", headers=headers)
print(resp.json())

Endpoints

The complete reference for each GET /v1/usage route, covering parameters, response shapes, error formats, and headers.
Expect a small lag in usage data — it is not reported in real time.