/api/orgs/{org_id}/usage/by-labelRoll up usage per end-user label
Grouped by the end-user id callers sent (safety_identifier, else user). Unlabeled requests are excluded, so an org that sends no label reads an empty list.
認証: AuthorizationヘッダーにBearer形式のAPIキー
パスパラメータ
org_idstring必須Your organization id (uuid).
GET /api/whoamireturns it.
クエリパラメータ
windowenumLookback window ending now.
24hbuckets hourly,7dand30ddaily.
レスポンス
200Per-label rollup.
レスポンス
windowenum必須labelsarray<object>必須labels
attribution_labelstring必須The end-user id the caller sent (
safety_identifier, else the deprecateduser).request_countinteger必須Every finished request, errors and pre-dispatch refusals included.
error_countinteger必須Subset whose terminal state was not
completed.input_tokensinteger必須output_tokensinteger必須cost_usdnumber必須Charged platform credits, dollars.
estimated_cost_usdnumber必須Never-charged BYOK estimate at list price, dollars.
free_usdnumber必須List-price value of promotion-funded usage, dollars (never charged).
last_used_atstring必須
400Unknown window.
レスポンス
errorstring必須Human-readable message.
codestringStable machine reason, when the route defines one (for example
pro_required).actionstringStable remediation action, when the route defines one.
detailsobjectCustomer-safe string facts the caller needs to act (for example a suggested identifier).
401Missing, unknown or revoked API key.
レスポンス
errorstring必須Human-readable message.
codestringStable machine reason, when the route defines one (for example
pro_required).actionstringStable remediation action, when the route defines one.
detailsobjectCustomer-safe string facts the caller needs to act (for example a suggested identifier).
404Unknown organization, or not the key's own organization.
レスポンス
errorstring必須Human-readable message.
codestringStable machine reason, when the route defines one (for example
pro_required).actionstringStable remediation action, when the route defines one.
detailsobjectCustomer-safe string facts the caller needs to act (for example a suggested identifier).
429Too many reads.
rate_limited: this organization's API-key reads of the request log are over about 10 per second (burst 30) or 4 in flight on one server (sessions are not limited).build_capacity: the shared analytics read slots are busy. Retry afterRetry-After.レスポンス
errorstring必須Human-readable message.
codestringStable machine reason, when the route defines one (for example
pro_required).actionstringStable remediation action, when the route defines one.
detailsobjectCustomer-safe string facts the caller needs to act (for example a suggested identifier).
503Usage analytics are temporarily unavailable. Retry shortly.
レスポンス
errorstring必須Human-readable message.
codestringStable machine reason, when the route defines one (for example
pro_required).actionstringStable remediation action, when the route defines one.
detailsobjectCustomer-safe string facts the caller needs to act (for example a suggested identifier).
リクエスト
curl https://api.experientiallabs.ai/api/orgs/3f6c2a1e-8b7d-4c2a-9e51-6a0d4b2f7c10/usage/by-label?window=24h \
-H "Authorization: Bearer YOUR_API_KEY"レスポンス
{
"window": "30d",
"labels": [
{
"attribution_label": "user_48121",
"request_count": 740,
"error_count": 2,
"input_tokens": 2810400,
"output_tokens": 190220,
"cost_usd": 1.31,
"estimated_cost_usd": 0,
"free_usd": 0,
"last_used_at": "2026-11-18T14:32:07.481Z"
}
]
}https://api.experientiallabs.ai/api/orgs/3f6c2a1e-8b7d-4c2a-9e51-6a0d4b2f7c10/usage/by-label?window=24h