@soat/sdk 0.13.2 → 0.13.4

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
@@ -2358,7 +2358,7 @@ var Tools = class {
2358
2358
  /**
2359
2359
  * Call a tool
2360
2360
  *
2361
- * Directly invokes a tool and returns its output. Supported for `http`, `soat`, and `mcp` tools. `client` tools cannot be invoked server-side and will return 422.
2361
+ * Directly invokes a tool and returns its output. Supported for `http`, `soat`, `mcp`, and `pipeline` tools. `client` tools cannot be invoked server-side and will return 422. A `pipeline` tool runs its declared steps in order and returns the mapped `output` (or the last step's output); `action` is ignored and `input` is the pipeline input.
2362
2362
  * For `soat` and `mcp` tools the `action` field is required and identifies which action (SOAT) or tool name (MCP) to invoke. For `http` tools `action` is ignored.
2363
2363
  * `preset_parameters` stored on the tool are merged with the caller-supplied `input` before execution; preset keys take lower precedence.
2364
2364
  *
package/dist/index.d.cts CHANGED
@@ -1265,7 +1265,11 @@ type DocumentRecord = {
1265
1265
  */
1266
1266
  size?: number;
1267
1267
  /**
1268
- * Text content (only present on getDocument)
1268
+ * Ingestion lifecycle state. `pending` enqueued; `processing` — chunks being extracted and embedded; `ready` — fully indexed; `failed` — processing error (see `metadata.failure_reason`).
1269
+ */
1270
+ status?: 'pending' | 'processing' | 'ready' | 'failed';
1271
+ /**
1272
+ * Text content (only present on getDocument, and only when status is ready)
1269
1273
  */
1270
1274
  content?: string | null;
1271
1275
  created_at?: Date;
@@ -1692,7 +1696,7 @@ type AiProviderResourceProperties = {
1692
1696
  } | null;
1693
1697
  };
1694
1698
  /**
1695
- * Defines a tool (HTTP endpoint, MCP server, or SOAT action) that agents can invoke during a generation.
1699
+ * Defines a tool (HTTP endpoint, MCP server, SOAT action, or pipeline) that agents can invoke during a generation.
1696
1700
  */
1697
1701
  type ToolResourceProperties = {
1698
1702
  /**
@@ -1700,7 +1704,7 @@ type ToolResourceProperties = {
1700
1704
  */
1701
1705
  name: string;
1702
1706
  /**
1703
- * Tool type hint (e.g. http, mcp, soat)
1707
+ * Tool type hint (e.g. http, mcp, soat, pipeline)
1704
1708
  */
1705
1709
  type?: string | null;
1706
1710
  /**
@@ -1757,6 +1761,12 @@ type ToolResourceProperties = {
1757
1761
  preset_parameters?: {
1758
1762
  [key: string]: unknown;
1759
1763
  } | null;
1764
+ /**
1765
+ * Pipeline definition for `pipeline` tools: an ordered `steps` array, each invoking another tool by `tool_id` (optional `action`) with an `input` built from earlier results via JSON Logic over `{ input, steps }`, plus an optional `output` mapping. Step `input` keys and `var` paths use camelCase (the runtime form). Free-form, user-defined.
1766
+ */
1767
+ pipeline?: {
1768
+ [key: string]: unknown;
1769
+ } | null;
1760
1770
  };
1761
1771
  /**
1762
1772
  * Stores a text document in a project, optionally indexing it for knowledge retrieval.
@@ -1821,9 +1831,9 @@ type MemoryEntryResourceProperties = {
1821
1831
  */
1822
1832
  content: string;
1823
1833
  /**
1824
- * Origin label (e.g. manual, document, import)
1834
+ * How this entry was created (defaults to manual)
1825
1835
  */
1826
- source?: string | null;
1836
+ source_type?: 'manual' | 'agent' | 'extraction';
1827
1837
  };
1828
1838
  /**
1829
1839
  * Registers an HTTPS endpoint to receive SOAT platform event notifications.
@@ -2137,7 +2147,7 @@ type Generation = {
2137
2147
  */
2138
2148
  trace_id?: string;
2139
2149
  /**
2140
- * Public ID of the generation that triggered this one via a sub-agent call. Null for top-level generations.
2150
+ * Public ID of the generation that triggered this one. Set for debate perspective/synthesis child generations and sub-agent invocations alike. Null for top-level generations.
2141
2151
  *
2142
2152
  */
2143
2153
  initiator_generation_id?: string | null;
@@ -2242,7 +2252,7 @@ type DocumentKnowledgeResult = {
2242
2252
  /**
2243
2253
  * Semantic similarity score (0–1). Only present when `query` was provided.
2244
2254
  */
2245
- score?: number;
2255
+ similarity_score?: number;
2246
2256
  /**
2247
2257
  * Creation timestamp
2248
2258
  */
@@ -2265,6 +2275,10 @@ type MemoryKnowledgeResult = {
2265
2275
  * Public ID of the parent memory
2266
2276
  */
2267
2277
  memory_id: string;
2278
+ /**
2279
+ * Human-readable name of the parent memory
2280
+ */
2281
+ memory_name: string;
2268
2282
  /**
2269
2283
  * Text content of the memory entry
2270
2284
  */
@@ -2272,7 +2286,7 @@ type MemoryKnowledgeResult = {
2272
2286
  /**
2273
2287
  * Semantic similarity score (0–1). Only present when `query` was provided.
2274
2288
  */
2275
- score?: number;
2289
+ similarity_score?: number;
2276
2290
  /**
2277
2291
  * Creation timestamp
2278
2292
  */
@@ -2298,7 +2312,7 @@ type MemoryEntry = {
2298
2312
  id?: string;
2299
2313
  memory_id?: string;
2300
2314
  content?: string;
2301
- source?: 'manual' | 'agent' | 'extraction';
2315
+ source_type?: 'manual' | 'agent' | 'extraction';
2302
2316
  created_at?: Date;
2303
2317
  updated_at?: Date;
2304
2318
  };
@@ -2319,17 +2333,17 @@ type OrchestrationNode = {
2319
2333
  /**
2320
2334
  * Node execution type.
2321
2335
  */
2322
- type: 'agent' | 'tool' | 'transform' | 'knowledge' | 'memory_write' | 'condition' | 'human' | 'loop' | 'delay' | 'webhook' | 'sub_orchestration';
2336
+ type: 'agent' | 'tool' | 'transform' | 'knowledge' | 'memory_write' | 'condition' | 'human' | 'loop' | 'poll' | 'delay' | 'webhook' | 'sub_orchestration';
2323
2337
  /**
2324
2338
  * For agent nodes — public ID of the agent to invoke.
2325
2339
  */
2326
2340
  agent_id?: string;
2327
2341
  /**
2328
- * For tool nodes — public ID of the tool to call.
2342
+ * For tool and poll nodes — public ID of the tool to call.
2329
2343
  */
2330
2344
  tool_id?: string;
2331
2345
  /**
2332
- * For tool nodes — specific operation/action on MCP/SOAT tools.
2346
+ * For tool and poll nodes — specific operation/action on MCP/SOAT tools.
2333
2347
  */
2334
2348
  operation_id?: string;
2335
2349
  /**
@@ -2338,6 +2352,13 @@ type OrchestrationNode = {
2338
2352
  expression?: {
2339
2353
  [key: string]: unknown;
2340
2354
  };
2355
+ /**
2356
+ * For poll nodes — JSON Logic stop condition, evaluated each attempt against the run state augmented with `response` (the latest tool result) and `attempt` (1-based count); a truthy result stops polling.
2357
+ *
2358
+ */
2359
+ exit_condition?: {
2360
+ [key: string]: unknown;
2361
+ };
2341
2362
  /**
2342
2363
  * For human nodes — prompt shown to the human reviewer.
2343
2364
  */
@@ -2377,16 +2398,23 @@ type OrchestrationNode = {
2377
2398
  * For loop nodes — variable name injected into state for each item.
2378
2399
  */
2379
2400
  item_variable?: string;
2380
- /**
2381
- * For loop nodes — sub-graph definition to run per item.
2382
- */
2383
- sub_graph?: string;
2384
2401
  /**
2385
2402
  * For loop nodes — number of items to process in parallel.
2386
2403
  */
2387
2404
  parallelism?: number;
2388
2405
  /**
2389
- * For delay nodes — ISO 8601 duration (e.g. PT5S).
2406
+ * For poll nodes — wait between attempts. Accepts a friendly suffix form (`5s`, `30s`, `5m`, `2h`, `500ms`) or ISO 8601 (e.g. PT5S).
2407
+ *
2408
+ */
2409
+ interval?: string;
2410
+ /**
2411
+ * For poll nodes — when max_iterations is reached without the exit condition becoming true, fail the run (true) instead of completing with condition_met=false (default false).
2412
+ *
2413
+ */
2414
+ fail_on_timeout?: boolean;
2415
+ /**
2416
+ * For delay nodes — how long to wait. Accepts a friendly suffix form (`5s`, `30s`, `5m`, `2h`, `500ms`) or ISO 8601 (e.g. PT5S).
2417
+ *
2390
2418
  */
2391
2419
  duration?: string;
2392
2420
  /**
@@ -2398,11 +2426,13 @@ type OrchestrationNode = {
2398
2426
  */
2399
2427
  webhook_url?: string;
2400
2428
  /**
2401
- * For sub_orchestration nodes public ID of the child orchestration.
2429
+ * Public ID of the orchestration this node runs — the child orchestration for sub_orchestration nodes, and the orchestration run once per item for loop nodes.
2430
+ *
2402
2431
  */
2403
2432
  orchestration_id?: string;
2404
2433
  /**
2405
- * Maximum iterations before the node is aborted.
2434
+ * Maximum iterations before the node is aborted. For poll nodes this is the maximum number of attempts (default 10, ceiling 1000).
2435
+ *
2406
2436
  */
2407
2437
  max_iterations?: number;
2408
2438
  };
@@ -2567,7 +2597,7 @@ type NodeExecution = {
2567
2597
  * Type of the executed node (e.g. agent, transform).
2568
2598
  */
2569
2599
  node_type?: string | null;
2570
- status: 'completed' | 'failed' | 'requires_action';
2600
+ status: 'completed' | 'failed' | 'requires_action' | 'skipped';
2571
2601
  /**
2572
2602
  * Resolved input_mapping the node received.
2573
2603
  */
@@ -2905,7 +2935,7 @@ type Tool = {
2905
2935
  /**
2906
2936
  * Tool type
2907
2937
  */
2908
- type?: 'http' | 'client' | 'mcp' | 'soat';
2938
+ type?: 'http' | 'client' | 'mcp' | 'soat' | 'pipeline';
2909
2939
  /**
2910
2940
  * What the tool does (sent to the model)
2911
2941
  */
@@ -2939,6 +2969,12 @@ type Tool = {
2939
2969
  preset_parameters?: {
2940
2970
  [key: string]: unknown;
2941
2971
  } | null;
2972
+ /**
2973
+ * Pipeline definition for `pipeline` tools: an ordered `steps` array, each step invoking another tool by `tool_id` (optional `action`) and building its `input` from earlier results via JSON Logic evaluated over `{ input, steps }`. An optional `output` maps the final result.
2974
+ */
2975
+ pipeline?: {
2976
+ [key: string]: unknown;
2977
+ } | null;
2942
2978
  created_at?: Date;
2943
2979
  updated_at?: Date;
2944
2980
  };
@@ -2954,7 +2990,7 @@ type CreateToolRequest = {
2954
2990
  /**
2955
2991
  * Tool type (default http)
2956
2992
  */
2957
- type?: 'http' | 'client' | 'mcp' | 'soat';
2993
+ type?: 'http' | 'client' | 'mcp' | 'soat' | 'pipeline';
2958
2994
  /**
2959
2995
  * What the tool does
2960
2996
  */
@@ -2988,10 +3024,16 @@ type CreateToolRequest = {
2988
3024
  preset_parameters?: {
2989
3025
  [key: string]: unknown;
2990
3026
  };
3027
+ /**
3028
+ * Pipeline definition for `pipeline` tools. See the `pipeline` field on the Tool schema for the full structure.
3029
+ */
3030
+ pipeline?: {
3031
+ [key: string]: unknown;
3032
+ };
2991
3033
  };
2992
3034
  type UpdateToolRequest = {
2993
3035
  name?: string;
2994
- type?: 'http' | 'client' | 'mcp' | 'soat';
3036
+ type?: 'http' | 'client' | 'mcp' | 'soat' | 'pipeline';
2995
3037
  description?: string | null;
2996
3038
  parameters?: {
2997
3039
  [key: string]: unknown;
@@ -3013,6 +3055,12 @@ type UpdateToolRequest = {
3013
3055
  preset_parameters?: {
3014
3056
  [key: string]: unknown;
3015
3057
  } | null;
3058
+ /**
3059
+ * Pipeline definition for `pipeline` tools. See the `pipeline` field on the Tool schema for the full structure.
3060
+ */
3061
+ pipeline?: {
3062
+ [key: string]: unknown;
3063
+ } | null;
3016
3064
  };
3017
3065
  type CallToolRequest = {
3018
3066
  /**
@@ -3098,6 +3146,11 @@ type TraceTreeNode = {
3098
3146
  * Child traces triggered by sub-agent calls from this trace
3099
3147
  */
3100
3148
  children?: Array<TraceTreeNode>;
3149
+ /**
3150
+ * Generations that belong to this trace node. Only present when `include=generations` is requested. Includes top-level generations and debate child generations (perspective turns and synthesis steps) linked via `initiator_generation_id`.
3151
+ *
3152
+ */
3153
+ generations?: Array<Generation>;
3101
3154
  };
3102
3155
  type UserRecord = {
3103
3156
  /**
@@ -4953,12 +5006,17 @@ type IngestDocumentData = {
4953
5006
  chunk_overlap?: number;
4954
5007
  };
4955
5008
  path?: never;
4956
- query?: never;
5009
+ query?: {
5010
+ /**
5011
+ * When omitted or `true` (default), processing runs in the background and `202 Accepted` is returned immediately with `status=pending`. Pass `false` to run synchronously and receive `201 Created` with `status=ready`.
5012
+ */
5013
+ async?: boolean;
5014
+ };
4957
5015
  url: '/api/v1/documents/ingest';
4958
5016
  };
4959
5017
  type IngestDocumentErrors = {
4960
5018
  /**
4961
- * Invalid request, file not found, unsupported content type, or no extractable text
5019
+ * Invalid request, file not found, or unsupported content type
4962
5020
  */
4963
5021
  400: ErrorResponse;
4964
5022
  /**
@@ -4973,9 +5031,13 @@ type IngestDocumentErrors = {
4973
5031
  type IngestDocumentError = IngestDocumentErrors[keyof IngestDocumentErrors];
4974
5032
  type IngestDocumentResponses = {
4975
5033
  /**
4976
- * Document created from file
5034
+ * Ingestion completed synchronously (only when `?async=false`). The document is fully indexed and ready for search.
4977
5035
  */
4978
5036
  201: IngestedDocumentRecord;
5037
+ /**
5038
+ * Ingestion accepted. The document record has been created with `status=pending` and processing runs in the background. Poll `GET /api/v1/documents/{document_id}` until `status` is `ready` or `failed`.
5039
+ */
5040
+ 202: IngestedDocumentRecord;
4979
5041
  };
4980
5042
  type IngestDocumentResponse = IngestDocumentResponses[keyof IngestDocumentResponses];
4981
5043
  type DeleteDocumentData = {
@@ -5990,6 +6052,11 @@ type ListGenerationsData = {
5990
6052
  * Filter by trace public ID
5991
6053
  */
5992
6054
  trace_id?: string;
6055
+ /**
6056
+ * Filter by the public ID of the parent generation. Returns all generations triggered by that generation — debate perspective turns, synthesis steps, and sub-agent invocations. Null-initiated (top-level) generations are not returned.
6057
+ *
6058
+ */
6059
+ initiator_generation_id?: string;
5993
6060
  /**
5994
6061
  * Filter by lifecycle status
5995
6062
  */
@@ -6364,7 +6431,7 @@ type CreateMemoryEntryData = {
6364
6431
  /**
6365
6432
  * How this entry was created
6366
6433
  */
6367
- source?: 'manual' | 'agent' | 'extraction';
6434
+ source_type?: 'manual' | 'agent' | 'extraction';
6368
6435
  /**
6369
6436
  * Cosine similarity score at or above which the incoming content is considered a duplicate and skipped (default 0.95)
6370
6437
  */
@@ -8071,7 +8138,13 @@ type GetTraceTreeData = {
8071
8138
  */
8072
8139
  trace_id: string;
8073
8140
  };
8074
- query?: never;
8141
+ query?: {
8142
+ /**
8143
+ * Comma-separated list of related resources to embed on each node. Supported value: `generations` — attaches all generations that belong to each trace node (including debate perspective/synthesis children linked via `initiator_generation_id`).
8144
+ *
8145
+ */
8146
+ include?: string;
8147
+ };
8075
8148
  url: '/api/v1/traces/{trace_id}/tree';
8076
8149
  };
8077
8150
  type GetTraceTreeErrors = {
@@ -9436,7 +9509,7 @@ declare class Tools {
9436
9509
  /**
9437
9510
  * Call a tool
9438
9511
  *
9439
- * Directly invokes a tool and returns its output. Supported for `http`, `soat`, and `mcp` tools. `client` tools cannot be invoked server-side and will return 422.
9512
+ * Directly invokes a tool and returns its output. Supported for `http`, `soat`, `mcp`, and `pipeline` tools. `client` tools cannot be invoked server-side and will return 422. A `pipeline` tool runs its declared steps in order and returns the mapped `output` (or the last step's output); `action` is ignored and `input` is the pipeline input.
9440
9513
  * For `soat` and `mcp` tools the `action` field is required and identifies which action (SOAT) or tool name (MCP) to invoke. For `http` tools `action` is ignored.
9441
9514
  * `preset_parameters` stored on the tool are merged with the caller-supplied `input` before execution; preset keys take lower precedence.
9442
9515
  *
package/dist/index.d.mts CHANGED
@@ -1265,7 +1265,11 @@ type DocumentRecord = {
1265
1265
  */
1266
1266
  size?: number;
1267
1267
  /**
1268
- * Text content (only present on getDocument)
1268
+ * Ingestion lifecycle state. `pending` enqueued; `processing` — chunks being extracted and embedded; `ready` — fully indexed; `failed` — processing error (see `metadata.failure_reason`).
1269
+ */
1270
+ status?: 'pending' | 'processing' | 'ready' | 'failed';
1271
+ /**
1272
+ * Text content (only present on getDocument, and only when status is ready)
1269
1273
  */
1270
1274
  content?: string | null;
1271
1275
  created_at?: Date;
@@ -1692,7 +1696,7 @@ type AiProviderResourceProperties = {
1692
1696
  } | null;
1693
1697
  };
1694
1698
  /**
1695
- * Defines a tool (HTTP endpoint, MCP server, or SOAT action) that agents can invoke during a generation.
1699
+ * Defines a tool (HTTP endpoint, MCP server, SOAT action, or pipeline) that agents can invoke during a generation.
1696
1700
  */
1697
1701
  type ToolResourceProperties = {
1698
1702
  /**
@@ -1700,7 +1704,7 @@ type ToolResourceProperties = {
1700
1704
  */
1701
1705
  name: string;
1702
1706
  /**
1703
- * Tool type hint (e.g. http, mcp, soat)
1707
+ * Tool type hint (e.g. http, mcp, soat, pipeline)
1704
1708
  */
1705
1709
  type?: string | null;
1706
1710
  /**
@@ -1757,6 +1761,12 @@ type ToolResourceProperties = {
1757
1761
  preset_parameters?: {
1758
1762
  [key: string]: unknown;
1759
1763
  } | null;
1764
+ /**
1765
+ * Pipeline definition for `pipeline` tools: an ordered `steps` array, each invoking another tool by `tool_id` (optional `action`) with an `input` built from earlier results via JSON Logic over `{ input, steps }`, plus an optional `output` mapping. Step `input` keys and `var` paths use camelCase (the runtime form). Free-form, user-defined.
1766
+ */
1767
+ pipeline?: {
1768
+ [key: string]: unknown;
1769
+ } | null;
1760
1770
  };
1761
1771
  /**
1762
1772
  * Stores a text document in a project, optionally indexing it for knowledge retrieval.
@@ -1821,9 +1831,9 @@ type MemoryEntryResourceProperties = {
1821
1831
  */
1822
1832
  content: string;
1823
1833
  /**
1824
- * Origin label (e.g. manual, document, import)
1834
+ * How this entry was created (defaults to manual)
1825
1835
  */
1826
- source?: string | null;
1836
+ source_type?: 'manual' | 'agent' | 'extraction';
1827
1837
  };
1828
1838
  /**
1829
1839
  * Registers an HTTPS endpoint to receive SOAT platform event notifications.
@@ -2137,7 +2147,7 @@ type Generation = {
2137
2147
  */
2138
2148
  trace_id?: string;
2139
2149
  /**
2140
- * Public ID of the generation that triggered this one via a sub-agent call. Null for top-level generations.
2150
+ * Public ID of the generation that triggered this one. Set for debate perspective/synthesis child generations and sub-agent invocations alike. Null for top-level generations.
2141
2151
  *
2142
2152
  */
2143
2153
  initiator_generation_id?: string | null;
@@ -2242,7 +2252,7 @@ type DocumentKnowledgeResult = {
2242
2252
  /**
2243
2253
  * Semantic similarity score (0–1). Only present when `query` was provided.
2244
2254
  */
2245
- score?: number;
2255
+ similarity_score?: number;
2246
2256
  /**
2247
2257
  * Creation timestamp
2248
2258
  */
@@ -2265,6 +2275,10 @@ type MemoryKnowledgeResult = {
2265
2275
  * Public ID of the parent memory
2266
2276
  */
2267
2277
  memory_id: string;
2278
+ /**
2279
+ * Human-readable name of the parent memory
2280
+ */
2281
+ memory_name: string;
2268
2282
  /**
2269
2283
  * Text content of the memory entry
2270
2284
  */
@@ -2272,7 +2286,7 @@ type MemoryKnowledgeResult = {
2272
2286
  /**
2273
2287
  * Semantic similarity score (0–1). Only present when `query` was provided.
2274
2288
  */
2275
- score?: number;
2289
+ similarity_score?: number;
2276
2290
  /**
2277
2291
  * Creation timestamp
2278
2292
  */
@@ -2298,7 +2312,7 @@ type MemoryEntry = {
2298
2312
  id?: string;
2299
2313
  memory_id?: string;
2300
2314
  content?: string;
2301
- source?: 'manual' | 'agent' | 'extraction';
2315
+ source_type?: 'manual' | 'agent' | 'extraction';
2302
2316
  created_at?: Date;
2303
2317
  updated_at?: Date;
2304
2318
  };
@@ -2319,17 +2333,17 @@ type OrchestrationNode = {
2319
2333
  /**
2320
2334
  * Node execution type.
2321
2335
  */
2322
- type: 'agent' | 'tool' | 'transform' | 'knowledge' | 'memory_write' | 'condition' | 'human' | 'loop' | 'delay' | 'webhook' | 'sub_orchestration';
2336
+ type: 'agent' | 'tool' | 'transform' | 'knowledge' | 'memory_write' | 'condition' | 'human' | 'loop' | 'poll' | 'delay' | 'webhook' | 'sub_orchestration';
2323
2337
  /**
2324
2338
  * For agent nodes — public ID of the agent to invoke.
2325
2339
  */
2326
2340
  agent_id?: string;
2327
2341
  /**
2328
- * For tool nodes — public ID of the tool to call.
2342
+ * For tool and poll nodes — public ID of the tool to call.
2329
2343
  */
2330
2344
  tool_id?: string;
2331
2345
  /**
2332
- * For tool nodes — specific operation/action on MCP/SOAT tools.
2346
+ * For tool and poll nodes — specific operation/action on MCP/SOAT tools.
2333
2347
  */
2334
2348
  operation_id?: string;
2335
2349
  /**
@@ -2338,6 +2352,13 @@ type OrchestrationNode = {
2338
2352
  expression?: {
2339
2353
  [key: string]: unknown;
2340
2354
  };
2355
+ /**
2356
+ * For poll nodes — JSON Logic stop condition, evaluated each attempt against the run state augmented with `response` (the latest tool result) and `attempt` (1-based count); a truthy result stops polling.
2357
+ *
2358
+ */
2359
+ exit_condition?: {
2360
+ [key: string]: unknown;
2361
+ };
2341
2362
  /**
2342
2363
  * For human nodes — prompt shown to the human reviewer.
2343
2364
  */
@@ -2377,16 +2398,23 @@ type OrchestrationNode = {
2377
2398
  * For loop nodes — variable name injected into state for each item.
2378
2399
  */
2379
2400
  item_variable?: string;
2380
- /**
2381
- * For loop nodes — sub-graph definition to run per item.
2382
- */
2383
- sub_graph?: string;
2384
2401
  /**
2385
2402
  * For loop nodes — number of items to process in parallel.
2386
2403
  */
2387
2404
  parallelism?: number;
2388
2405
  /**
2389
- * For delay nodes — ISO 8601 duration (e.g. PT5S).
2406
+ * For poll nodes — wait between attempts. Accepts a friendly suffix form (`5s`, `30s`, `5m`, `2h`, `500ms`) or ISO 8601 (e.g. PT5S).
2407
+ *
2408
+ */
2409
+ interval?: string;
2410
+ /**
2411
+ * For poll nodes — when max_iterations is reached without the exit condition becoming true, fail the run (true) instead of completing with condition_met=false (default false).
2412
+ *
2413
+ */
2414
+ fail_on_timeout?: boolean;
2415
+ /**
2416
+ * For delay nodes — how long to wait. Accepts a friendly suffix form (`5s`, `30s`, `5m`, `2h`, `500ms`) or ISO 8601 (e.g. PT5S).
2417
+ *
2390
2418
  */
2391
2419
  duration?: string;
2392
2420
  /**
@@ -2398,11 +2426,13 @@ type OrchestrationNode = {
2398
2426
  */
2399
2427
  webhook_url?: string;
2400
2428
  /**
2401
- * For sub_orchestration nodes public ID of the child orchestration.
2429
+ * Public ID of the orchestration this node runs — the child orchestration for sub_orchestration nodes, and the orchestration run once per item for loop nodes.
2430
+ *
2402
2431
  */
2403
2432
  orchestration_id?: string;
2404
2433
  /**
2405
- * Maximum iterations before the node is aborted.
2434
+ * Maximum iterations before the node is aborted. For poll nodes this is the maximum number of attempts (default 10, ceiling 1000).
2435
+ *
2406
2436
  */
2407
2437
  max_iterations?: number;
2408
2438
  };
@@ -2567,7 +2597,7 @@ type NodeExecution = {
2567
2597
  * Type of the executed node (e.g. agent, transform).
2568
2598
  */
2569
2599
  node_type?: string | null;
2570
- status: 'completed' | 'failed' | 'requires_action';
2600
+ status: 'completed' | 'failed' | 'requires_action' | 'skipped';
2571
2601
  /**
2572
2602
  * Resolved input_mapping the node received.
2573
2603
  */
@@ -2905,7 +2935,7 @@ type Tool = {
2905
2935
  /**
2906
2936
  * Tool type
2907
2937
  */
2908
- type?: 'http' | 'client' | 'mcp' | 'soat';
2938
+ type?: 'http' | 'client' | 'mcp' | 'soat' | 'pipeline';
2909
2939
  /**
2910
2940
  * What the tool does (sent to the model)
2911
2941
  */
@@ -2939,6 +2969,12 @@ type Tool = {
2939
2969
  preset_parameters?: {
2940
2970
  [key: string]: unknown;
2941
2971
  } | null;
2972
+ /**
2973
+ * Pipeline definition for `pipeline` tools: an ordered `steps` array, each step invoking another tool by `tool_id` (optional `action`) and building its `input` from earlier results via JSON Logic evaluated over `{ input, steps }`. An optional `output` maps the final result.
2974
+ */
2975
+ pipeline?: {
2976
+ [key: string]: unknown;
2977
+ } | null;
2942
2978
  created_at?: Date;
2943
2979
  updated_at?: Date;
2944
2980
  };
@@ -2954,7 +2990,7 @@ type CreateToolRequest = {
2954
2990
  /**
2955
2991
  * Tool type (default http)
2956
2992
  */
2957
- type?: 'http' | 'client' | 'mcp' | 'soat';
2993
+ type?: 'http' | 'client' | 'mcp' | 'soat' | 'pipeline';
2958
2994
  /**
2959
2995
  * What the tool does
2960
2996
  */
@@ -2988,10 +3024,16 @@ type CreateToolRequest = {
2988
3024
  preset_parameters?: {
2989
3025
  [key: string]: unknown;
2990
3026
  };
3027
+ /**
3028
+ * Pipeline definition for `pipeline` tools. See the `pipeline` field on the Tool schema for the full structure.
3029
+ */
3030
+ pipeline?: {
3031
+ [key: string]: unknown;
3032
+ };
2991
3033
  };
2992
3034
  type UpdateToolRequest = {
2993
3035
  name?: string;
2994
- type?: 'http' | 'client' | 'mcp' | 'soat';
3036
+ type?: 'http' | 'client' | 'mcp' | 'soat' | 'pipeline';
2995
3037
  description?: string | null;
2996
3038
  parameters?: {
2997
3039
  [key: string]: unknown;
@@ -3013,6 +3055,12 @@ type UpdateToolRequest = {
3013
3055
  preset_parameters?: {
3014
3056
  [key: string]: unknown;
3015
3057
  } | null;
3058
+ /**
3059
+ * Pipeline definition for `pipeline` tools. See the `pipeline` field on the Tool schema for the full structure.
3060
+ */
3061
+ pipeline?: {
3062
+ [key: string]: unknown;
3063
+ } | null;
3016
3064
  };
3017
3065
  type CallToolRequest = {
3018
3066
  /**
@@ -3098,6 +3146,11 @@ type TraceTreeNode = {
3098
3146
  * Child traces triggered by sub-agent calls from this trace
3099
3147
  */
3100
3148
  children?: Array<TraceTreeNode>;
3149
+ /**
3150
+ * Generations that belong to this trace node. Only present when `include=generations` is requested. Includes top-level generations and debate child generations (perspective turns and synthesis steps) linked via `initiator_generation_id`.
3151
+ *
3152
+ */
3153
+ generations?: Array<Generation>;
3101
3154
  };
3102
3155
  type UserRecord = {
3103
3156
  /**
@@ -4953,12 +5006,17 @@ type IngestDocumentData = {
4953
5006
  chunk_overlap?: number;
4954
5007
  };
4955
5008
  path?: never;
4956
- query?: never;
5009
+ query?: {
5010
+ /**
5011
+ * When omitted or `true` (default), processing runs in the background and `202 Accepted` is returned immediately with `status=pending`. Pass `false` to run synchronously and receive `201 Created` with `status=ready`.
5012
+ */
5013
+ async?: boolean;
5014
+ };
4957
5015
  url: '/api/v1/documents/ingest';
4958
5016
  };
4959
5017
  type IngestDocumentErrors = {
4960
5018
  /**
4961
- * Invalid request, file not found, unsupported content type, or no extractable text
5019
+ * Invalid request, file not found, or unsupported content type
4962
5020
  */
4963
5021
  400: ErrorResponse;
4964
5022
  /**
@@ -4973,9 +5031,13 @@ type IngestDocumentErrors = {
4973
5031
  type IngestDocumentError = IngestDocumentErrors[keyof IngestDocumentErrors];
4974
5032
  type IngestDocumentResponses = {
4975
5033
  /**
4976
- * Document created from file
5034
+ * Ingestion completed synchronously (only when `?async=false`). The document is fully indexed and ready for search.
4977
5035
  */
4978
5036
  201: IngestedDocumentRecord;
5037
+ /**
5038
+ * Ingestion accepted. The document record has been created with `status=pending` and processing runs in the background. Poll `GET /api/v1/documents/{document_id}` until `status` is `ready` or `failed`.
5039
+ */
5040
+ 202: IngestedDocumentRecord;
4979
5041
  };
4980
5042
  type IngestDocumentResponse = IngestDocumentResponses[keyof IngestDocumentResponses];
4981
5043
  type DeleteDocumentData = {
@@ -5990,6 +6052,11 @@ type ListGenerationsData = {
5990
6052
  * Filter by trace public ID
5991
6053
  */
5992
6054
  trace_id?: string;
6055
+ /**
6056
+ * Filter by the public ID of the parent generation. Returns all generations triggered by that generation — debate perspective turns, synthesis steps, and sub-agent invocations. Null-initiated (top-level) generations are not returned.
6057
+ *
6058
+ */
6059
+ initiator_generation_id?: string;
5993
6060
  /**
5994
6061
  * Filter by lifecycle status
5995
6062
  */
@@ -6364,7 +6431,7 @@ type CreateMemoryEntryData = {
6364
6431
  /**
6365
6432
  * How this entry was created
6366
6433
  */
6367
- source?: 'manual' | 'agent' | 'extraction';
6434
+ source_type?: 'manual' | 'agent' | 'extraction';
6368
6435
  /**
6369
6436
  * Cosine similarity score at or above which the incoming content is considered a duplicate and skipped (default 0.95)
6370
6437
  */
@@ -8071,7 +8138,13 @@ type GetTraceTreeData = {
8071
8138
  */
8072
8139
  trace_id: string;
8073
8140
  };
8074
- query?: never;
8141
+ query?: {
8142
+ /**
8143
+ * Comma-separated list of related resources to embed on each node. Supported value: `generations` — attaches all generations that belong to each trace node (including debate perspective/synthesis children linked via `initiator_generation_id`).
8144
+ *
8145
+ */
8146
+ include?: string;
8147
+ };
8075
8148
  url: '/api/v1/traces/{trace_id}/tree';
8076
8149
  };
8077
8150
  type GetTraceTreeErrors = {
@@ -9436,7 +9509,7 @@ declare class Tools {
9436
9509
  /**
9437
9510
  * Call a tool
9438
9511
  *
9439
- * Directly invokes a tool and returns its output. Supported for `http`, `soat`, and `mcp` tools. `client` tools cannot be invoked server-side and will return 422.
9512
+ * Directly invokes a tool and returns its output. Supported for `http`, `soat`, `mcp`, and `pipeline` tools. `client` tools cannot be invoked server-side and will return 422. A `pipeline` tool runs its declared steps in order and returns the mapped `output` (or the last step's output); `action` is ignored and `input` is the pipeline input.
9440
9513
  * For `soat` and `mcp` tools the `action` field is required and identifies which action (SOAT) or tool name (MCP) to invoke. For `http` tools `action` is ignored.
9441
9514
  * `preset_parameters` stored on the tool are merged with the caller-supplied `input` before execution; preset keys take lower precedence.
9442
9515
  *
package/dist/index.mjs CHANGED
@@ -2357,7 +2357,7 @@ var Tools = class {
2357
2357
  /**
2358
2358
  * Call a tool
2359
2359
  *
2360
- * Directly invokes a tool and returns its output. Supported for `http`, `soat`, and `mcp` tools. `client` tools cannot be invoked server-side and will return 422.
2360
+ * Directly invokes a tool and returns its output. Supported for `http`, `soat`, `mcp`, and `pipeline` tools. `client` tools cannot be invoked server-side and will return 422. A `pipeline` tool runs its declared steps in order and returns the mapped `output` (or the last step's output); `action` is ignored and `input` is the pipeline input.
2361
2361
  * For `soat` and `mcp` tools the `action` field is required and identifies which action (SOAT) or tool name (MCP) to invoke. For `http` tools `action` is ignored.
2362
2362
  * `preset_parameters` stored on the tool are merged with the caller-supplied `input` before execution; preset keys take lower precedence.
2363
2363
  *
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@soat/sdk",
3
- "version": "0.13.2",
3
+ "version": "0.13.4",
4
4
  "description": "TypeScript SDK for the SOAT API",
5
5
  "type": "module",
6
6
  "main": "dist/index.mjs",