@naturali/cli 0.102.0 → 0.103.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.mjs +48 -4
- package/package.json +2 -2
package/dist/index.mjs
CHANGED
|
@@ -14,7 +14,7 @@ var __exportAll = (all, no_symbols) => {
|
|
|
14
14
|
};
|
|
15
15
|
//#endregion
|
|
16
16
|
//#region package.json
|
|
17
|
-
var version = "0.
|
|
17
|
+
var version = "0.103.1";
|
|
18
18
|
//#endregion
|
|
19
19
|
//#region ../sdk/src/generated/core/bodySerializer.gen.ts
|
|
20
20
|
const serializeFormDataPair = (data, key, value) => {
|
|
@@ -1087,7 +1087,7 @@ var Admin = class {
|
|
|
1087
1087
|
/**
|
|
1088
1088
|
* Read a user's credit ledger
|
|
1089
1089
|
*
|
|
1090
|
-
* A cursor page of the account's credit lines, newest first, with the balance they sum to. Needs the `admin` role — including for the account's own owner,
|
|
1090
|
+
* A cursor page of the account's credit lines, newest first, with the balance they sum to. Needs the `admin` role — including for the account's own owner, who reads their own balance at `GET /v1/users/me/billing` rather than here. That answers what is left; this is the line-by-line record behind it.
|
|
1091
1091
|
* What an operator reads it for is writing a correction: the line that was wrong stays on the record, so it has to be legible before it can be compensated for.
|
|
1092
1092
|
*
|
|
1093
1093
|
*/
|
|
@@ -4257,6 +4257,24 @@ var Users = class {
|
|
|
4257
4257
|
...options
|
|
4258
4258
|
});
|
|
4259
4259
|
}
|
|
4260
|
+
/**
|
|
4261
|
+
* Get the current account's runs this billing cycle
|
|
4262
|
+
*
|
|
4263
|
+
* How many runs the account has made this billing cycle, and how many its plan includes. A **run is one agent generation** — the unit every rung is priced in.
|
|
4264
|
+
*
|
|
4265
|
+
* Counted across the projects this account is the billing owner of, over the current UTC calendar month, from the meter itself. Archived projects are included: the runs they already made were made.
|
|
4266
|
+
*
|
|
4267
|
+
* **Nothing is refused against this.** The allowance is published, not enforced — an account past it keeps running. What does stop a managed-model generation is a negative credit balance, which is `GET /v1/users/me/billing`.
|
|
4268
|
+
*
|
|
4269
|
+
* This read is more expensive than the balance one: it asks the meter once per project. Poll it on the order of minutes, not seconds.
|
|
4270
|
+
*
|
|
4271
|
+
*/
|
|
4272
|
+
static getCurrentUserUsage(options) {
|
|
4273
|
+
return (options?.client ?? client).get({
|
|
4274
|
+
url: "/v1/users/me/usage",
|
|
4275
|
+
...options
|
|
4276
|
+
});
|
|
4277
|
+
}
|
|
4260
4278
|
};
|
|
4261
4279
|
var Webhooks = class {
|
|
4262
4280
|
/**
|
|
@@ -5738,7 +5756,7 @@ const routes = {
|
|
|
5738
5756
|
"list-user-credits": {
|
|
5739
5757
|
serviceClass: "Admin",
|
|
5740
5758
|
operationId: "listUserCredits",
|
|
5741
|
-
description: "A cursor page of the account's credit lines, newest first, with the balance they sum to. Needs the `admin` role — including for the account's own owner,
|
|
5759
|
+
description: "A cursor page of the account's credit lines, newest first, with the balance they sum to. Needs the `admin` role — including for the account's own owner, who reads their own balance at `GET /v1/users/me/billing` rather than here. That answers what is left; this is the line-by-line record behind it. What an operator reads it for is writing a correction: the line that was wrong stays on the record, so it has to be legible before it can be compensated for.",
|
|
5742
5760
|
moduleDocsUrl: "https://docs.naturali.ai/docs/modules/admin",
|
|
5743
5761
|
httpMethod: "get",
|
|
5744
5762
|
pathParams: ["user_id"],
|
|
@@ -13260,7 +13278,9 @@ const routes = {
|
|
|
13260
13278
|
"group_by",
|
|
13261
13279
|
"meter_type",
|
|
13262
13280
|
"from",
|
|
13263
|
-
"to"
|
|
13281
|
+
"to",
|
|
13282
|
+
"limit",
|
|
13283
|
+
"offset"
|
|
13264
13284
|
],
|
|
13265
13285
|
flags: [
|
|
13266
13286
|
{
|
|
@@ -13297,6 +13317,20 @@ const routes = {
|
|
|
13297
13317
|
"required": false,
|
|
13298
13318
|
"type": "string",
|
|
13299
13319
|
"in": "query"
|
|
13320
|
+
},
|
|
13321
|
+
{
|
|
13322
|
+
"name": "limit",
|
|
13323
|
+
"description": "Maximum number of groups entries to return. Does not affect the top-level totals or groups.total, which describe the whole window. A value above 100 is refused rather than clamped, so a caller paging by their own stride never silently skips a bucket.\n",
|
|
13324
|
+
"required": false,
|
|
13325
|
+
"type": "integer",
|
|
13326
|
+
"in": "query"
|
|
13327
|
+
},
|
|
13328
|
+
{
|
|
13329
|
+
"name": "offset",
|
|
13330
|
+
"description": "Number of groups entries to skip.",
|
|
13331
|
+
"required": false,
|
|
13332
|
+
"type": "integer",
|
|
13333
|
+
"in": "query"
|
|
13300
13334
|
}
|
|
13301
13335
|
]
|
|
13302
13336
|
},
|
|
@@ -15385,6 +15419,16 @@ const routes = {
|
|
|
15385
15419
|
queryParams: [],
|
|
15386
15420
|
flags: []
|
|
15387
15421
|
},
|
|
15422
|
+
"get-current-user-usage": {
|
|
15423
|
+
serviceClass: "Users",
|
|
15424
|
+
operationId: "getCurrentUserUsage",
|
|
15425
|
+
description: "How many runs the account has made this billing cycle, and how many its plan includes. A **run is one agent generation** — the unit every rung is priced in. Counted across the projects this account is the billing owner of, over the current UTC calendar month, from the meter itself. Archived projects are included: the runs they already made were made. **Nothing is refused against this.** The allowance is published, not enforced — an account past it keeps running. What does stop a managed-model generation is a negative credit balance, which is `GET /v1/users/me/billing`. This read is more expensive than the balance one: it asks the meter once per project. Poll it on the order of minutes, not seconds.",
|
|
15426
|
+
moduleDocsUrl: "https://docs.naturali.ai/docs/modules/users",
|
|
15427
|
+
httpMethod: "get",
|
|
15428
|
+
pathParams: [],
|
|
15429
|
+
queryParams: [],
|
|
15430
|
+
flags: []
|
|
15431
|
+
},
|
|
15388
15432
|
"list-webhooks": {
|
|
15389
15433
|
serviceClass: "Webhooks",
|
|
15390
15434
|
operationId: "listWebhooks",
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@naturali/cli",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.103.1",
|
|
4
4
|
"description": "Command-line interface for the naturali.ai API, generated from its OpenAPI specs",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"bin": {
|
|
@@ -30,7 +30,7 @@
|
|
|
30
30
|
"tsx": "^4.23.1",
|
|
31
31
|
"typescript": "~6.0.3",
|
|
32
32
|
"vitest": "^4.1.10",
|
|
33
|
-
"@naturali/sdk": "0.
|
|
33
|
+
"@naturali/sdk": "0.103.1"
|
|
34
34
|
},
|
|
35
35
|
"scripts": {
|
|
36
36
|
"generate": "tsx scripts/generate.ts",
|