@soat/sdk 0.92.1 → 0.93.0

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.cjs CHANGED
@@ -3719,6 +3719,8 @@ var Playbooks = class {
3719
3719
  * Validate a playbook definition
3720
3720
  *
3721
3721
  * Answers what a create or update would be told about a definition, without writing: `valid`, and every graph problem it holds. A definition whose shape cannot be read is `400 VALIDATION_FAILED`, as on a write.
3722
+ *
3723
+ * With `project_id`, the upstreams are also read against that project's playbooks, as a write there would read them, and the caller needs both `playbooks:ValidatePlaybook` and `playbooks:ListPlaybooks` on the project. Without it, only the definition's own graph is checked.
3722
3724
  */
3723
3725
  static validatePlaybook(options) {
3724
3726
  return (options.client ?? client).post({
@@ -3980,6 +3982,8 @@ var Playbooks = class {
3980
3982
  *
3981
3983
  * Moves a case to another version of its playbook: the playbook's current version, or the `version` named, an earlier one included. Values carry over by node ID, and every node's state is read against the new version: a node added is open, a node removed leaves the structure while its entries stay, a node whose input reads another field is `stale`, and a value its input's new schema refuses is missing again. The cascade then runs what became runnable. With `wait: true` it answers once every execution queued, and every one those queue, has settled or parked. Each upgrade is recorded with what moved; the version the case is already on records nothing.
3982
3984
  *
3985
+ * The case's upstream bindings follow the target version: a name it declares on the same playbook keeps its case, any other binding is dropped, and each name it declares that the case does not bind is bound from `upstreams`, by the rules of create. A declared name left unbound is `400 PLAYBOOK_CASE_UPSTREAM_INVALID` and moves nothing.
3986
+ *
3983
3987
  * An execution running is `409 PLAYBOOK_CASE_BUSY`; one queued but not started settles `superseded`. An upgrade made with a credential the case's own work, or that of a case reading it as an upstream, runs as is `403 PLAYBOOK_SELF_WRITE`.
3984
3988
  */
3985
3989
  static upgradePlaybookCase(options) {
package/dist/index.d.cts CHANGED
@@ -6174,6 +6174,10 @@ type PlaybookExecutor = {
6174
6174
  * The ID of the agent, tool, decider, workflow or orchestration
6175
6175
  */
6176
6176
  id: string;
6177
+ /**
6178
+ * Only on a `tool` executor: which action of a multi-action (`mcp`, `soat`) tool to call — the same selector an orchestration `tool` node's `operation_id` is. Required by an `mcp` tool.
6179
+ */
6180
+ operation_id?: string;
6177
6181
  /**
6178
6182
  * JSON Logic over the node's inputs, as an orchestration's `input_mapping`: each key is a field of the executor's input. Absent, the executor receives the node's input values as they are.
6179
6183
  */
@@ -6300,6 +6304,14 @@ type UpdatePlaybookRequest = {
6300
6304
  expected_version?: ExpectedVersion;
6301
6305
  };
6302
6306
  type ValidatePlaybookRequest = {
6307
+ /**
6308
+ * Also check the upstreams against this project's playbooks: `UNKNOWN_UPSTREAM`, and the `MISSING_NODE` and `UNKNOWN_FIELD` of what an upstream node pulls.
6309
+ */
6310
+ project_id?: string;
6311
+ /**
6312
+ * The playbook the definition would update, so an upstream reading it back is `UPSTREAM_CYCLE`. Requires `project_id`.
6313
+ */
6314
+ playbook_id?: string;
6303
6315
  /**
6304
6316
  * The definition to check
6305
6317
  */
@@ -6308,7 +6320,7 @@ type ValidatePlaybookRequest = {
6308
6320
  type PlaybookValidationResult = {
6309
6321
  valid: boolean;
6310
6322
  /**
6311
- * Every reason the definition cannot be stored: `DUPLICATE_NODE`, `DUPLICATE_INPUT`, `MISSING_NODE`, `UNKNOWN_FIELD`, `EXECUTOR_REQUIRED`, `EXECUTOR_FORBIDDEN`, `TRANSFORMATIONS_NOT_FINAL`, `DUPLICATE_TRANSFORMATION` or `CYCLE`. The same items a refused write lists under `meta.problems`.
6323
+ * Every reason the definition cannot be stored: `DUPLICATE_NODE`, `DUPLICATE_INPUT`, `MISSING_NODE`, `UNKNOWN_FIELD`, `EXECUTOR_REQUIRED`, `EXECUTOR_FORBIDDEN`, `TRANSFORMATIONS_NOT_FINAL`, `DUPLICATE_TRANSFORMATION`, `CYCLE`, and, with `project_id`, `UNKNOWN_UPSTREAM` or `UPSTREAM_CYCLE`. The same items a refused write lists under `meta.problems`.
6312
6324
  */
6313
6325
  problems: Array<ValidationProblem>;
6314
6326
  };
@@ -6438,7 +6450,7 @@ type PlaybookCaseSummary = {
6438
6450
  updated_at?: Date;
6439
6451
  };
6440
6452
  /**
6441
- * The case bound to each of the playbook's declared `upstreams`, by name: every declared name and no other, each a case of the declared playbook. Fixed at create; empty when the playbook declares none.
6453
+ * The case bound to each of the playbook's declared `upstreams`, by name: every declared name and no other, each a case of the declared playbook. Bound at create and fitted to the version at each upgrade; empty when the version declares none.
6442
6454
  */
6443
6455
  type PlaybookCaseUpstreams = {
6444
6456
  [key: string]: string;
@@ -6665,6 +6677,10 @@ type UpgradePlaybookCaseRequest = {
6665
6677
  * The version to move the case to; the playbook's current one when omitted
6666
6678
  */
6667
6679
  version?: number;
6680
+ /**
6681
+ * A case for each upstream the target version declares and the case does not bind yet, by name, checked as at create. A binding the target version declares on the same playbook is kept and never named here; every other binding is dropped.
6682
+ */
6683
+ upstreams?: PlaybookCaseUpstreams;
6668
6684
  /**
6669
6685
  * Answer once every execution the write queued, and every one those queue in turn, has settled or parked, instead of right away
6670
6686
  */
@@ -18643,13 +18659,21 @@ type ValidatePlaybookData = {
18643
18659
  };
18644
18660
  type ValidatePlaybookErrors = {
18645
18661
  /**
18646
- * Bad request — the definition's shape cannot be read
18662
+ * Bad request — the definition's shape cannot be read, or `playbook_id` is given without `project_id`
18647
18663
  */
18648
18664
  400: unknown;
18649
18665
  /**
18650
18666
  * Unauthorized
18651
18667
  */
18652
18668
  401: unknown;
18669
+ /**
18670
+ * Forbidden
18671
+ */
18672
+ 403: unknown;
18673
+ /**
18674
+ * `playbook_id` names no playbook of the project
18675
+ */
18676
+ 404: unknown;
18653
18677
  };
18654
18678
  type ValidatePlaybookResponses = {
18655
18679
  /**
@@ -19491,7 +19515,7 @@ type UpgradePlaybookCaseData = {
19491
19515
  };
19492
19516
  type UpgradePlaybookCaseErrors = {
19493
19517
  /**
19494
- * Bad request — a version the playbook does not have
19518
+ * Bad request — a version the playbook does not have, or `PLAYBOOK_CASE_UPSTREAM_INVALID`: an upstream the target version declares left unbound, a name it does not declare or the case already binds, or a case that cannot be bound
19495
19519
  */
19496
19520
  400: unknown;
19497
19521
  /**
@@ -25865,6 +25889,8 @@ export declare class Playbooks {
25865
25889
  * Validate a playbook definition
25866
25890
  *
25867
25891
  * Answers what a create or update would be told about a definition, without writing: `valid`, and every graph problem it holds. A definition whose shape cannot be read is `400 VALIDATION_FAILED`, as on a write.
25892
+ *
25893
+ * With `project_id`, the upstreams are also read against that project's playbooks, as a write there would read them, and the caller needs both `playbooks:ValidatePlaybook` and `playbooks:ListPlaybooks` on the project. Without it, only the definition's own graph is checked.
25868
25894
  */
25869
25895
  static validatePlaybook<ThrowOnError extends boolean = false>(options: Options<ValidatePlaybookData, ThrowOnError>): RequestResult<ValidatePlaybookResponses, ValidatePlaybookErrors, ThrowOnError>;
25870
25896
  /**
@@ -25998,6 +26024,8 @@ export declare class Playbooks {
25998
26024
  *
25999
26025
  * Moves a case to another version of its playbook: the playbook's current version, or the `version` named, an earlier one included. Values carry over by node ID, and every node's state is read against the new version: a node added is open, a node removed leaves the structure while its entries stay, a node whose input reads another field is `stale`, and a value its input's new schema refuses is missing again. The cascade then runs what became runnable. With `wait: true` it answers once every execution queued, and every one those queue, has settled or parked. Each upgrade is recorded with what moved; the version the case is already on records nothing.
26000
26026
  *
26027
+ * The case's upstream bindings follow the target version: a name it declares on the same playbook keeps its case, any other binding is dropped, and each name it declares that the case does not bind is bound from `upstreams`, by the rules of create. A declared name left unbound is `400 PLAYBOOK_CASE_UPSTREAM_INVALID` and moves nothing.
26028
+ *
26001
26029
  * An execution running is `409 PLAYBOOK_CASE_BUSY`; one queued but not started settles `superseded`. An upgrade made with a credential the case's own work, or that of a case reading it as an upstream, runs as is `403 PLAYBOOK_SELF_WRITE`.
26002
26030
  */
26003
26031
  static upgradePlaybookCase<ThrowOnError extends boolean = false>(options: Options<UpgradePlaybookCaseData, ThrowOnError>): RequestResult<UpgradePlaybookCaseResponses, UpgradePlaybookCaseErrors, ThrowOnError>;
package/dist/index.d.mts CHANGED
@@ -6174,6 +6174,10 @@ type PlaybookExecutor = {
6174
6174
  * The ID of the agent, tool, decider, workflow or orchestration
6175
6175
  */
6176
6176
  id: string;
6177
+ /**
6178
+ * Only on a `tool` executor: which action of a multi-action (`mcp`, `soat`) tool to call — the same selector an orchestration `tool` node's `operation_id` is. Required by an `mcp` tool.
6179
+ */
6180
+ operation_id?: string;
6177
6181
  /**
6178
6182
  * JSON Logic over the node's inputs, as an orchestration's `input_mapping`: each key is a field of the executor's input. Absent, the executor receives the node's input values as they are.
6179
6183
  */
@@ -6300,6 +6304,14 @@ type UpdatePlaybookRequest = {
6300
6304
  expected_version?: ExpectedVersion;
6301
6305
  };
6302
6306
  type ValidatePlaybookRequest = {
6307
+ /**
6308
+ * Also check the upstreams against this project's playbooks: `UNKNOWN_UPSTREAM`, and the `MISSING_NODE` and `UNKNOWN_FIELD` of what an upstream node pulls.
6309
+ */
6310
+ project_id?: string;
6311
+ /**
6312
+ * The playbook the definition would update, so an upstream reading it back is `UPSTREAM_CYCLE`. Requires `project_id`.
6313
+ */
6314
+ playbook_id?: string;
6303
6315
  /**
6304
6316
  * The definition to check
6305
6317
  */
@@ -6308,7 +6320,7 @@ type ValidatePlaybookRequest = {
6308
6320
  type PlaybookValidationResult = {
6309
6321
  valid: boolean;
6310
6322
  /**
6311
- * Every reason the definition cannot be stored: `DUPLICATE_NODE`, `DUPLICATE_INPUT`, `MISSING_NODE`, `UNKNOWN_FIELD`, `EXECUTOR_REQUIRED`, `EXECUTOR_FORBIDDEN`, `TRANSFORMATIONS_NOT_FINAL`, `DUPLICATE_TRANSFORMATION` or `CYCLE`. The same items a refused write lists under `meta.problems`.
6323
+ * Every reason the definition cannot be stored: `DUPLICATE_NODE`, `DUPLICATE_INPUT`, `MISSING_NODE`, `UNKNOWN_FIELD`, `EXECUTOR_REQUIRED`, `EXECUTOR_FORBIDDEN`, `TRANSFORMATIONS_NOT_FINAL`, `DUPLICATE_TRANSFORMATION`, `CYCLE`, and, with `project_id`, `UNKNOWN_UPSTREAM` or `UPSTREAM_CYCLE`. The same items a refused write lists under `meta.problems`.
6312
6324
  */
6313
6325
  problems: Array<ValidationProblem>;
6314
6326
  };
@@ -6438,7 +6450,7 @@ type PlaybookCaseSummary = {
6438
6450
  updated_at?: Date;
6439
6451
  };
6440
6452
  /**
6441
- * The case bound to each of the playbook's declared `upstreams`, by name: every declared name and no other, each a case of the declared playbook. Fixed at create; empty when the playbook declares none.
6453
+ * The case bound to each of the playbook's declared `upstreams`, by name: every declared name and no other, each a case of the declared playbook. Bound at create and fitted to the version at each upgrade; empty when the version declares none.
6442
6454
  */
6443
6455
  type PlaybookCaseUpstreams = {
6444
6456
  [key: string]: string;
@@ -6665,6 +6677,10 @@ type UpgradePlaybookCaseRequest = {
6665
6677
  * The version to move the case to; the playbook's current one when omitted
6666
6678
  */
6667
6679
  version?: number;
6680
+ /**
6681
+ * A case for each upstream the target version declares and the case does not bind yet, by name, checked as at create. A binding the target version declares on the same playbook is kept and never named here; every other binding is dropped.
6682
+ */
6683
+ upstreams?: PlaybookCaseUpstreams;
6668
6684
  /**
6669
6685
  * Answer once every execution the write queued, and every one those queue in turn, has settled or parked, instead of right away
6670
6686
  */
@@ -18643,13 +18659,21 @@ type ValidatePlaybookData = {
18643
18659
  };
18644
18660
  type ValidatePlaybookErrors = {
18645
18661
  /**
18646
- * Bad request — the definition's shape cannot be read
18662
+ * Bad request — the definition's shape cannot be read, or `playbook_id` is given without `project_id`
18647
18663
  */
18648
18664
  400: unknown;
18649
18665
  /**
18650
18666
  * Unauthorized
18651
18667
  */
18652
18668
  401: unknown;
18669
+ /**
18670
+ * Forbidden
18671
+ */
18672
+ 403: unknown;
18673
+ /**
18674
+ * `playbook_id` names no playbook of the project
18675
+ */
18676
+ 404: unknown;
18653
18677
  };
18654
18678
  type ValidatePlaybookResponses = {
18655
18679
  /**
@@ -19491,7 +19515,7 @@ type UpgradePlaybookCaseData = {
19491
19515
  };
19492
19516
  type UpgradePlaybookCaseErrors = {
19493
19517
  /**
19494
- * Bad request — a version the playbook does not have
19518
+ * Bad request — a version the playbook does not have, or `PLAYBOOK_CASE_UPSTREAM_INVALID`: an upstream the target version declares left unbound, a name it does not declare or the case already binds, or a case that cannot be bound
19495
19519
  */
19496
19520
  400: unknown;
19497
19521
  /**
@@ -25865,6 +25889,8 @@ export declare class Playbooks {
25865
25889
  * Validate a playbook definition
25866
25890
  *
25867
25891
  * Answers what a create or update would be told about a definition, without writing: `valid`, and every graph problem it holds. A definition whose shape cannot be read is `400 VALIDATION_FAILED`, as on a write.
25892
+ *
25893
+ * With `project_id`, the upstreams are also read against that project's playbooks, as a write there would read them, and the caller needs both `playbooks:ValidatePlaybook` and `playbooks:ListPlaybooks` on the project. Without it, only the definition's own graph is checked.
25868
25894
  */
25869
25895
  static validatePlaybook<ThrowOnError extends boolean = false>(options: Options<ValidatePlaybookData, ThrowOnError>): RequestResult<ValidatePlaybookResponses, ValidatePlaybookErrors, ThrowOnError>;
25870
25896
  /**
@@ -25998,6 +26024,8 @@ export declare class Playbooks {
25998
26024
  *
25999
26025
  * Moves a case to another version of its playbook: the playbook's current version, or the `version` named, an earlier one included. Values carry over by node ID, and every node's state is read against the new version: a node added is open, a node removed leaves the structure while its entries stay, a node whose input reads another field is `stale`, and a value its input's new schema refuses is missing again. The cascade then runs what became runnable. With `wait: true` it answers once every execution queued, and every one those queue, has settled or parked. Each upgrade is recorded with what moved; the version the case is already on records nothing.
26000
26026
  *
26027
+ * The case's upstream bindings follow the target version: a name it declares on the same playbook keeps its case, any other binding is dropped, and each name it declares that the case does not bind is bound from `upstreams`, by the rules of create. A declared name left unbound is `400 PLAYBOOK_CASE_UPSTREAM_INVALID` and moves nothing.
26028
+ *
26001
26029
  * An execution running is `409 PLAYBOOK_CASE_BUSY`; one queued but not started settles `superseded`. An upgrade made with a credential the case's own work, or that of a case reading it as an upstream, runs as is `403 PLAYBOOK_SELF_WRITE`.
26002
26030
  */
26003
26031
  static upgradePlaybookCase<ThrowOnError extends boolean = false>(options: Options<UpgradePlaybookCaseData, ThrowOnError>): RequestResult<UpgradePlaybookCaseResponses, UpgradePlaybookCaseErrors, ThrowOnError>;
package/dist/index.mjs CHANGED
@@ -3718,6 +3718,8 @@ var Playbooks = class {
3718
3718
  * Validate a playbook definition
3719
3719
  *
3720
3720
  * Answers what a create or update would be told about a definition, without writing: `valid`, and every graph problem it holds. A definition whose shape cannot be read is `400 VALIDATION_FAILED`, as on a write.
3721
+ *
3722
+ * With `project_id`, the upstreams are also read against that project's playbooks, as a write there would read them, and the caller needs both `playbooks:ValidatePlaybook` and `playbooks:ListPlaybooks` on the project. Without it, only the definition's own graph is checked.
3721
3723
  */
3722
3724
  static validatePlaybook(options) {
3723
3725
  return (options.client ?? client).post({
@@ -3979,6 +3981,8 @@ var Playbooks = class {
3979
3981
  *
3980
3982
  * Moves a case to another version of its playbook: the playbook's current version, or the `version` named, an earlier one included. Values carry over by node ID, and every node's state is read against the new version: a node added is open, a node removed leaves the structure while its entries stay, a node whose input reads another field is `stale`, and a value its input's new schema refuses is missing again. The cascade then runs what became runnable. With `wait: true` it answers once every execution queued, and every one those queue, has settled or parked. Each upgrade is recorded with what moved; the version the case is already on records nothing.
3981
3983
  *
3984
+ * The case's upstream bindings follow the target version: a name it declares on the same playbook keeps its case, any other binding is dropped, and each name it declares that the case does not bind is bound from `upstreams`, by the rules of create. A declared name left unbound is `400 PLAYBOOK_CASE_UPSTREAM_INVALID` and moves nothing.
3985
+ *
3982
3986
  * An execution running is `409 PLAYBOOK_CASE_BUSY`; one queued but not started settles `superseded`. An upgrade made with a credential the case's own work, or that of a case reading it as an upstream, runs as is `403 PLAYBOOK_SELF_WRITE`.
3983
3987
  */
3984
3988
  static upgradePlaybookCase(options) {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@soat/sdk",
3
- "version": "0.92.1",
3
+ "version": "0.93.0",
4
4
  "description": "TypeScript SDK for SOAT — open-source infrastructure for production-ready AI agents.",
5
5
  "keywords": [
6
6
  "ai-agents",