@naturali/sdk 0.109.0 → 0.109.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.d.cts +3 -3
- package/dist/index.d.mts +3 -3
- package/package.json +2 -2
package/dist/index.d.cts
CHANGED
|
@@ -5416,13 +5416,13 @@ type UsageGroup = {
|
|
|
5416
5416
|
cost_usd: number | null;
|
|
5417
5417
|
} & UsageTokens & UsageComponents;
|
|
5418
5418
|
/**
|
|
5419
|
-
* One page of buckets, one entry per distinct value in the chosen dimension. The rollup grows with the window —
|
|
5419
|
+
* One page of buckets, one entry per distinct value in the chosen dimension. The rollup grows with the window — day buckets per day, model per model served — so the buckets are paged while total counts the whole window. Ordered by cost_usd descending, ties broken by key then ai_provider_id ascending, nulls last: the first page is the biggest spenders, and paging never repeats or skips a bucket.
|
|
5420
5420
|
*
|
|
5421
5421
|
*/
|
|
5422
5422
|
type ProjectUsageGroups = {
|
|
5423
5423
|
data: Array<UsageGroup>;
|
|
5424
5424
|
/**
|
|
5425
|
-
* Distinct buckets in the window, independent of limit.
|
|
5425
|
+
* Distinct buckets in the window, independent of limit, including a null bucket for the events the chosen dimension does not apply to. It is a count of buckets and not of anything they describe: under group_by=run a project that runs no orchestration has exactly one bucket whatever its volume. How many runs an account made is GET /v1/users/me/usage.
|
|
5426
5426
|
*
|
|
5427
5427
|
*/
|
|
5428
5428
|
total: number;
|
|
@@ -15972,7 +15972,7 @@ type GetProjectUsageData = {
|
|
|
15972
15972
|
};
|
|
15973
15973
|
query?: {
|
|
15974
15974
|
/**
|
|
15975
|
-
* Dimension to bucket by. `day` buckets on the event's UTC calendar day; the others on the matching id. `model` buckets on the model *and* the provider that served it, so one model name served by two providers is two groups (see `ai_provider_id`). `ai_provider` buckets on the provider the spend was billed against — a routed generation's serving target, or the agent's pinned provider — which is the total a per-provider reconciliation wants, without summing the model dimension by hand.
|
|
15975
|
+
* Dimension to bucket by. `day` buckets on the event's UTC calendar day; the others on the matching id. `model` buckets on the model *and* the provider that served it, so one model name served by two providers is two groups (see `ai_provider_id`). `ai_provider` buckets on the provider the spend was billed against — a routed generation's serving target, or the agent's pinned provider — which is the total a per-provider reconciliation wants, without summing the model dimension by hand. `run` buckets on the orchestration run an event belongs to; work that runs no orchestration collapses into the single null bucket, so the bucket count there is not a count of runs.
|
|
15976
15976
|
*
|
|
15977
15977
|
*/
|
|
15978
15978
|
group_by?: 'model' | 'ai_provider' | 'agent' | 'run' | 'day' | 'meter_type';
|
package/dist/index.d.mts
CHANGED
|
@@ -5416,13 +5416,13 @@ type UsageGroup = {
|
|
|
5416
5416
|
cost_usd: number | null;
|
|
5417
5417
|
} & UsageTokens & UsageComponents;
|
|
5418
5418
|
/**
|
|
5419
|
-
* One page of buckets, one entry per distinct value in the chosen dimension. The rollup grows with the window —
|
|
5419
|
+
* One page of buckets, one entry per distinct value in the chosen dimension. The rollup grows with the window — day buckets per day, model per model served — so the buckets are paged while total counts the whole window. Ordered by cost_usd descending, ties broken by key then ai_provider_id ascending, nulls last: the first page is the biggest spenders, and paging never repeats or skips a bucket.
|
|
5420
5420
|
*
|
|
5421
5421
|
*/
|
|
5422
5422
|
type ProjectUsageGroups = {
|
|
5423
5423
|
data: Array<UsageGroup>;
|
|
5424
5424
|
/**
|
|
5425
|
-
* Distinct buckets in the window, independent of limit.
|
|
5425
|
+
* Distinct buckets in the window, independent of limit, including a null bucket for the events the chosen dimension does not apply to. It is a count of buckets and not of anything they describe: under group_by=run a project that runs no orchestration has exactly one bucket whatever its volume. How many runs an account made is GET /v1/users/me/usage.
|
|
5426
5426
|
*
|
|
5427
5427
|
*/
|
|
5428
5428
|
total: number;
|
|
@@ -15972,7 +15972,7 @@ type GetProjectUsageData = {
|
|
|
15972
15972
|
};
|
|
15973
15973
|
query?: {
|
|
15974
15974
|
/**
|
|
15975
|
-
* Dimension to bucket by. `day` buckets on the event's UTC calendar day; the others on the matching id. `model` buckets on the model *and* the provider that served it, so one model name served by two providers is two groups (see `ai_provider_id`). `ai_provider` buckets on the provider the spend was billed against — a routed generation's serving target, or the agent's pinned provider — which is the total a per-provider reconciliation wants, without summing the model dimension by hand.
|
|
15975
|
+
* Dimension to bucket by. `day` buckets on the event's UTC calendar day; the others on the matching id. `model` buckets on the model *and* the provider that served it, so one model name served by two providers is two groups (see `ai_provider_id`). `ai_provider` buckets on the provider the spend was billed against — a routed generation's serving target, or the agent's pinned provider — which is the total a per-provider reconciliation wants, without summing the model dimension by hand. `run` buckets on the orchestration run an event belongs to; work that runs no orchestration collapses into the single null bucket, so the bucket count there is not a count of runs.
|
|
15976
15976
|
*
|
|
15977
15977
|
*/
|
|
15978
15978
|
group_by?: 'model' | 'ai_provider' | 'agent' | 'run' | 'day' | 'meter_type';
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@naturali/sdk",
|
|
3
|
-
"version": "0.109.
|
|
3
|
+
"version": "0.109.1",
|
|
4
4
|
"description": "TypeScript SDK for the naturali.ai API, generated from its OpenAPI specs",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"sideEffects": false,
|
|
@@ -37,7 +37,7 @@
|
|
|
37
37
|
"tsx": "^4.23.1",
|
|
38
38
|
"typescript": "~6.0.3",
|
|
39
39
|
"vitest": "^4.1.10",
|
|
40
|
-
"@naturali/api": "0.109.
|
|
40
|
+
"@naturali/api": "0.109.1"
|
|
41
41
|
},
|
|
42
42
|
"scripts": {
|
|
43
43
|
"generate": "tsx scripts/generate.ts",
|