@naturali/sdk 0.173.2 → 0.173.3

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 CHANGED
@@ -5035,7 +5035,7 @@ type Generation = {
5035
5035
  */
5036
5036
  trace_id?: string;
5037
5037
  /**
5038
- * Public ID of the generation that triggered this one. Set for sub-agent invocations. Null for top-level generations.
5038
+ * Public ID of the generation that started this one: a sub-agent invocation, an approval continuation, a client-tool re-handoff or a memory-rule handler turn. Null for top-level generations.
5039
5039
  *
5040
5040
  */
5041
5041
  initiator_generation_id?: string | null;
@@ -6659,13 +6659,13 @@ type OrchestrationRun = {
6659
6659
  */
6660
6660
  node_executions?: Array<NodeExecution>;
6661
6661
  /**
6662
- * What the run cost: token counts and `cost_usd` summed across every metered generation it produced **and every run it started** through `loop` / `sub_orchestration` nodes, at any depth. Present on the single-run read; omitted from run list responses.
6662
+ * What the run cost: token counts and `cost_usd` summed across every metered generation it produced **and every run it started** through `loop` / `sub_orchestration` nodes, at any depth. Present only on the single-run read (`GET /v1/projects/{project_id}/orchestration-runs/{orchestration_run_id}`); omitted from run lists and from every write's response, including a start with `wait: true`.
6663
6663
  *
6664
6664
  * A nested child is a run record of its own, so this figure spans several of them. Two consequences: summing `usage` across a list that mixes parents and children double-counts (filter with `nested=false`), and the per-event receipt at `/v1/projects/{project_id}/usage/receipt` stays scoped to one run — its line items carry a `node_id` from one graph only.
6665
6665
  */
6666
6666
  usage?: UsageTotals;
6667
6667
  /**
6668
- * The same roll-up restricted to **this run's own nodes**, excluding every nested run it started. Equal to `usage` for a run with no children; below it for a run that delegates. Present on the single-run read; omitted from run list responses.
6668
+ * The same roll-up restricted to **this run's own nodes**, excluding every nested run it started. Equal to `usage` for a run with no children; below it for a run that delegates. Present only on the single-run read, like `usage`.
6669
6669
  *
6670
6670
  * This is the field to read to see where cost sits in a run tree — own versus subtree — without walking the children.
6671
6671
  */
@@ -10465,7 +10465,7 @@ type CreateAgentGenerationErrors = {
10465
10465
  */
10466
10466
  409: ErrorResponse;
10467
10467
  /**
10468
- * `SHARE_CAP_EXCEEDED`: the agent is another project's, reached through a share whose `cap` is spent for the window. Carries a `Retry-After` header and `error.meta.retry_after`.
10468
+ * `QUOTA_EXCEEDED`: an `enforce`-mode generation quota is exhausted; `error.meta` carries `quota_id`, `metric`, `limit`, `window` and `resets_at`. `SHARE_CAP_EXCEEDED`: the agent is another project's, reached through a share whose `cap` is spent for the window; `error.meta.retry_after` says when. Both carry a `Retry-After` header.
10469
10469
  */
10470
10470
  429: ErrorResponse;
10471
10471
  /**
@@ -10522,6 +10522,11 @@ type SubmitAgentToolOutputsErrors = {
10522
10522
  * Agent or generation not found
10523
10523
  */
10524
10524
  404: ErrorResponse;
10525
+ /**
10526
+ * The generation is not paused on client tool calls (GENERATION_NOT_AWAITING_TOOL_OUTPUTS): it never paused, or its outputs were already submitted. Each pause accepts outputs once.
10527
+ *
10528
+ */
10529
+ 409: ErrorResponse;
10525
10530
  /**
10526
10531
  * Upstream AI provider error (AI_PROVIDER_ERROR); model output that does not satisfy the agent's `output_schema` (OUTPUT_SCHEMA_VALIDATION_FAILED); or a model that wrote a tool invocation out as plain assistant text instead of calling the tool (TEXT_ENCODED_TOOL_CALL — `meta.tool_name` names the tool). The resumed generation is recorded `failed`.
10527
10532
  *
@@ -13350,6 +13355,10 @@ type GenerateConversationMessageErrors = {
13350
13355
  * Conversation or actor not found
13351
13356
  */
13352
13357
  404: ErrorResponse;
13358
+ /**
13359
+ * `QUOTA_EXCEEDED`: an `enforce`-mode generation quota is exhausted. `error.meta` carries `quota_id`, `metric`, `limit`, `window` and `resets_at`, with a `Retry-After` header. Only with `?wait=true`: a background call is answered `202` before the quota is read.
13360
+ */
13361
+ 429: ErrorResponse;
13353
13362
  /**
13354
13363
  * Streaming not implemented
13355
13364
  */
@@ -16974,7 +16983,7 @@ type ListGenerationsData = {
16974
16983
  */
16975
16984
  actor_id?: string;
16976
16985
  /**
16977
- * Filter by the public ID of the parent generation. Returns all generations triggered by that generation — sub-agent invocations. Null-initiated (top-level) generations are not returned.
16986
+ * Filter by the public ID of the parent generation. Returns every generation started by that generation: sub-agent invocations, approval continuations, client-tool re-handoffs and memory-rule handler turns. Top-level generations are not returned.
16978
16987
  *
16979
16988
  */
16980
16989
  initiator_generation_id?: string;
@@ -22495,6 +22504,10 @@ type AddSessionMessageErrors = {
22495
22504
  * The resource does not exist (existence is not leaked).
22496
22505
  */
22497
22506
  404: ErrorResponse;
22507
+ /**
22508
+ * `QUOTA_EXCEEDED`: the session auto-generates and an `enforce`-mode generation quota is exhausted. `error.meta` carries `quota_id`, `metric`, `limit`, `window` and `resets_at`, with a `Retry-After` header. The message is saved. A session with `message_delay_seconds` answers `201` before the quota is read.
22509
+ */
22510
+ 429: ErrorResponse;
22498
22511
  };
22499
22512
  type AddSessionMessageError = AddSessionMessageErrors[keyof AddSessionMessageErrors];
22500
22513
  type AddSessionMessageResponses = {
@@ -22549,6 +22562,10 @@ type GenerateSessionResponseErrors = {
22549
22562
  * Session has expired due to inactivity
22550
22563
  */
22551
22564
  410: ErrorResponse;
22565
+ /**
22566
+ * `QUOTA_EXCEEDED`: an `enforce`-mode generation quota is exhausted. `error.meta` carries `quota_id`, `metric`, `limit`, `window` and `resets_at`, with a `Retry-After` header. Only with `?wait=true`: a background call is answered `202` before the quota is read.
22567
+ */
22568
+ 429: ErrorResponse;
22552
22569
  /**
22553
22570
  * Upstream AI provider error (AI_PROVIDER_ERROR). The error `meta` includes the `generation_id` and `trace_id` of the failed generation for post-mortem debugging via GET /v1/projects/{project_id}/generations/{generation_id}.
22554
22571
  *
@@ -22598,6 +22615,11 @@ type SubmitSessionToolOutputsErrors = {
22598
22615
  * The resource does not exist (existence is not leaked).
22599
22616
  */
22600
22617
  404: ErrorResponse;
22618
+ /**
22619
+ * The generation is not paused on client tool calls (GENERATION_NOT_AWAITING_TOOL_OUTPUTS): it never paused, or its outputs were already submitted. Each pause accepts outputs once.
22620
+ *
22621
+ */
22622
+ 409: ErrorResponse;
22601
22623
  };
22602
22624
  type SubmitSessionToolOutputsError = SubmitSessionToolOutputsErrors[keyof SubmitSessionToolOutputsErrors];
22603
22625
  type SubmitSessionToolOutputsResponses = {
package/dist/index.d.mts CHANGED
@@ -5035,7 +5035,7 @@ type Generation = {
5035
5035
  */
5036
5036
  trace_id?: string;
5037
5037
  /**
5038
- * Public ID of the generation that triggered this one. Set for sub-agent invocations. Null for top-level generations.
5038
+ * Public ID of the generation that started this one: a sub-agent invocation, an approval continuation, a client-tool re-handoff or a memory-rule handler turn. Null for top-level generations.
5039
5039
  *
5040
5040
  */
5041
5041
  initiator_generation_id?: string | null;
@@ -6659,13 +6659,13 @@ type OrchestrationRun = {
6659
6659
  */
6660
6660
  node_executions?: Array<NodeExecution>;
6661
6661
  /**
6662
- * What the run cost: token counts and `cost_usd` summed across every metered generation it produced **and every run it started** through `loop` / `sub_orchestration` nodes, at any depth. Present on the single-run read; omitted from run list responses.
6662
+ * What the run cost: token counts and `cost_usd` summed across every metered generation it produced **and every run it started** through `loop` / `sub_orchestration` nodes, at any depth. Present only on the single-run read (`GET /v1/projects/{project_id}/orchestration-runs/{orchestration_run_id}`); omitted from run lists and from every write's response, including a start with `wait: true`.
6663
6663
  *
6664
6664
  * A nested child is a run record of its own, so this figure spans several of them. Two consequences: summing `usage` across a list that mixes parents and children double-counts (filter with `nested=false`), and the per-event receipt at `/v1/projects/{project_id}/usage/receipt` stays scoped to one run — its line items carry a `node_id` from one graph only.
6665
6665
  */
6666
6666
  usage?: UsageTotals;
6667
6667
  /**
6668
- * The same roll-up restricted to **this run's own nodes**, excluding every nested run it started. Equal to `usage` for a run with no children; below it for a run that delegates. Present on the single-run read; omitted from run list responses.
6668
+ * The same roll-up restricted to **this run's own nodes**, excluding every nested run it started. Equal to `usage` for a run with no children; below it for a run that delegates. Present only on the single-run read, like `usage`.
6669
6669
  *
6670
6670
  * This is the field to read to see where cost sits in a run tree — own versus subtree — without walking the children.
6671
6671
  */
@@ -10465,7 +10465,7 @@ type CreateAgentGenerationErrors = {
10465
10465
  */
10466
10466
  409: ErrorResponse;
10467
10467
  /**
10468
- * `SHARE_CAP_EXCEEDED`: the agent is another project's, reached through a share whose `cap` is spent for the window. Carries a `Retry-After` header and `error.meta.retry_after`.
10468
+ * `QUOTA_EXCEEDED`: an `enforce`-mode generation quota is exhausted; `error.meta` carries `quota_id`, `metric`, `limit`, `window` and `resets_at`. `SHARE_CAP_EXCEEDED`: the agent is another project's, reached through a share whose `cap` is spent for the window; `error.meta.retry_after` says when. Both carry a `Retry-After` header.
10469
10469
  */
10470
10470
  429: ErrorResponse;
10471
10471
  /**
@@ -10522,6 +10522,11 @@ type SubmitAgentToolOutputsErrors = {
10522
10522
  * Agent or generation not found
10523
10523
  */
10524
10524
  404: ErrorResponse;
10525
+ /**
10526
+ * The generation is not paused on client tool calls (GENERATION_NOT_AWAITING_TOOL_OUTPUTS): it never paused, or its outputs were already submitted. Each pause accepts outputs once.
10527
+ *
10528
+ */
10529
+ 409: ErrorResponse;
10525
10530
  /**
10526
10531
  * Upstream AI provider error (AI_PROVIDER_ERROR); model output that does not satisfy the agent's `output_schema` (OUTPUT_SCHEMA_VALIDATION_FAILED); or a model that wrote a tool invocation out as plain assistant text instead of calling the tool (TEXT_ENCODED_TOOL_CALL — `meta.tool_name` names the tool). The resumed generation is recorded `failed`.
10527
10532
  *
@@ -13350,6 +13355,10 @@ type GenerateConversationMessageErrors = {
13350
13355
  * Conversation or actor not found
13351
13356
  */
13352
13357
  404: ErrorResponse;
13358
+ /**
13359
+ * `QUOTA_EXCEEDED`: an `enforce`-mode generation quota is exhausted. `error.meta` carries `quota_id`, `metric`, `limit`, `window` and `resets_at`, with a `Retry-After` header. Only with `?wait=true`: a background call is answered `202` before the quota is read.
13360
+ */
13361
+ 429: ErrorResponse;
13353
13362
  /**
13354
13363
  * Streaming not implemented
13355
13364
  */
@@ -16974,7 +16983,7 @@ type ListGenerationsData = {
16974
16983
  */
16975
16984
  actor_id?: string;
16976
16985
  /**
16977
- * Filter by the public ID of the parent generation. Returns all generations triggered by that generation — sub-agent invocations. Null-initiated (top-level) generations are not returned.
16986
+ * Filter by the public ID of the parent generation. Returns every generation started by that generation: sub-agent invocations, approval continuations, client-tool re-handoffs and memory-rule handler turns. Top-level generations are not returned.
16978
16987
  *
16979
16988
  */
16980
16989
  initiator_generation_id?: string;
@@ -22495,6 +22504,10 @@ type AddSessionMessageErrors = {
22495
22504
  * The resource does not exist (existence is not leaked).
22496
22505
  */
22497
22506
  404: ErrorResponse;
22507
+ /**
22508
+ * `QUOTA_EXCEEDED`: the session auto-generates and an `enforce`-mode generation quota is exhausted. `error.meta` carries `quota_id`, `metric`, `limit`, `window` and `resets_at`, with a `Retry-After` header. The message is saved. A session with `message_delay_seconds` answers `201` before the quota is read.
22509
+ */
22510
+ 429: ErrorResponse;
22498
22511
  };
22499
22512
  type AddSessionMessageError = AddSessionMessageErrors[keyof AddSessionMessageErrors];
22500
22513
  type AddSessionMessageResponses = {
@@ -22549,6 +22562,10 @@ type GenerateSessionResponseErrors = {
22549
22562
  * Session has expired due to inactivity
22550
22563
  */
22551
22564
  410: ErrorResponse;
22565
+ /**
22566
+ * `QUOTA_EXCEEDED`: an `enforce`-mode generation quota is exhausted. `error.meta` carries `quota_id`, `metric`, `limit`, `window` and `resets_at`, with a `Retry-After` header. Only with `?wait=true`: a background call is answered `202` before the quota is read.
22567
+ */
22568
+ 429: ErrorResponse;
22552
22569
  /**
22553
22570
  * Upstream AI provider error (AI_PROVIDER_ERROR). The error `meta` includes the `generation_id` and `trace_id` of the failed generation for post-mortem debugging via GET /v1/projects/{project_id}/generations/{generation_id}.
22554
22571
  *
@@ -22598,6 +22615,11 @@ type SubmitSessionToolOutputsErrors = {
22598
22615
  * The resource does not exist (existence is not leaked).
22599
22616
  */
22600
22617
  404: ErrorResponse;
22618
+ /**
22619
+ * The generation is not paused on client tool calls (GENERATION_NOT_AWAITING_TOOL_OUTPUTS): it never paused, or its outputs were already submitted. Each pause accepts outputs once.
22620
+ *
22621
+ */
22622
+ 409: ErrorResponse;
22601
22623
  };
22602
22624
  type SubmitSessionToolOutputsError = SubmitSessionToolOutputsErrors[keyof SubmitSessionToolOutputsErrors];
22603
22625
  type SubmitSessionToolOutputsResponses = {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@naturali/sdk",
3
- "version": "0.173.2",
3
+ "version": "0.173.3",
4
4
  "description": "TypeScript SDK for the naturali.ai API, generated from its OpenAPI specs",
5
5
  "type": "module",
6
6
  "sideEffects": false,
@@ -31,7 +31,7 @@
31
31
  },
32
32
  "devDependencies": {
33
33
  "@hey-api/openapi-ts": "^0.99.0",
34
- "@naturali/api": "0.173.2",
34
+ "@naturali/api": "0.173.3",
35
35
  "@ttoss/openapi-codegen": "^0.5.0",
36
36
  "@types/node": "^26.5.1",
37
37
  "tsdown": "^0.23.0",