windmill-client 1.812.0 → 1.814.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/client.d.ts CHANGED
@@ -528,6 +528,13 @@ export interface TaskRetry {
528
528
  export interface TaskOptions {
529
529
  timeout?: number;
530
530
  tag?: string;
531
+ /** Seconds during which a previous result of this task is served instead of
532
+ * running it again. A task written inline in the workflow is keyed on its
533
+ * step key (its name and call order) and the workflow's input, not on the
534
+ * arguments it is called with, so cache one only when whether it runs, and
535
+ * what it receives, follow from the workflow's input alone. A `taskScript`
536
+ * target is keyed on the arguments it is called with. It has no effect on a
537
+ * `taskFlow` target, which keeps its flow's own cache policy. */
531
538
  cache_ttl?: number;
532
539
  priority?: number;
533
540
  concurrency_limit?: number;
@@ -29,7 +29,7 @@ const OpenAPI = {
29
29
  PASSWORD: void 0,
30
30
  TOKEN: getEnv("WM_TOKEN"),
31
31
  USERNAME: void 0,
32
- VERSION: "1.812.0",
32
+ VERSION: "1.814.0",
33
33
  WITH_CREDENTIALS: !getEnv("WM_RAW_APP"),
34
34
  interceptors: {
35
35
  request: new Interceptors(),
package/dist/index.js CHANGED
@@ -126,7 +126,7 @@ const OpenAPI = {
126
126
  PASSWORD: void 0,
127
127
  TOKEN: getEnv$1("WM_TOKEN"),
128
128
  USERNAME: void 0,
129
- VERSION: "1.812.0",
129
+ VERSION: "1.814.0",
130
130
  WITH_CREDENTIALS: !getEnv$1("WM_RAW_APP"),
131
131
  interceptors: {
132
132
  request: new Interceptors(),
@@ -2036,6 +2036,21 @@ var WorkspaceService = class {
2036
2036
  });
2037
2037
  }
2038
2038
  /**
2039
+ * get the AI session retention of workspaces referenced by client-side sessions
2040
+ * @param data The data for the request.
2041
+ * @param data.requestBody
2042
+ * @returns number map of workspace id to its `ai_config.sessions_retention_days`; a workspace without a retention, or one the caller cannot be authenticated into, is absent
2043
+ * @throws ApiError
2044
+ */
2045
+ static getSessionWorkspaceRetention(data) {
2046
+ return request(OpenAPI, {
2047
+ method: "POST",
2048
+ url: "/workspaces/session_workspace_retention",
2049
+ body: data.requestBody,
2050
+ mediaType: "application/json"
2051
+ });
2052
+ }
2053
+ /**
2039
2054
  * get workspace as super admin (require to be super admin)
2040
2055
  * @param data The data for the request.
2041
2056
  * @param data.workspace
@@ -6290,6 +6305,24 @@ var FlowService = class {
6290
6305
  });
6291
6306
  }
6292
6307
  /**
6308
+ * list flow paths with a step linked to a saved agent
6309
+ * @param data The data for the request.
6310
+ * @param data.workspace
6311
+ * @param data.path
6312
+ * @returns string paths of the flows linking the `ai_agent` resource, as of their last deploy
6313
+ * @throws ApiError
6314
+ */
6315
+ static listFlowPathsLinkingAgent(data) {
6316
+ return request(OpenAPI, {
6317
+ method: "GET",
6318
+ url: "/w/{workspace}/flows/list_paths_linking_agent/{path}",
6319
+ path: {
6320
+ workspace: data.workspace,
6321
+ path: data.path
6322
+ }
6323
+ });
6324
+ }
6325
+ /**
6293
6326
  * get flow version
6294
6327
  * @param data The data for the request.
6295
6328
  * @param data.workspace
@@ -8747,7 +8780,7 @@ var JobService = class {
8747
8780
  *
8748
8781
  * @param data.jobId The job id to assign to the created job. if missing, job is chosen randomly using the ULID scheme. If a job id already exists in the queue or as a completed job, the request to create one will fail (Bad Request)
8749
8782
  * @param data.skipPreprocessor skip the preprocessor
8750
- * @param data.memoryId memory ID for chat-enabled flows
8783
+ * @param data.memoryId Memory id for the flow's AI agent steps. A uuid is used as is; any other string is hashed within the workspace and flow, so the same string always names the same memory of that flow.
8751
8784
  * @returns unknown job result
8752
8785
  * @throws ApiError
8753
8786
  */
@@ -8783,7 +8816,7 @@ var JobService = class {
8783
8816
  *
8784
8817
  * @param data.jobId The job id to assign to the created job. if missing, job is chosen randomly using the ULID scheme. If a job id already exists in the queue or as a completed job, the request to create one will fail (Bad Request)
8785
8818
  * @param data.skipPreprocessor skip the preprocessor
8786
- * @param data.memoryId memory ID for chat-enabled flows
8819
+ * @param data.memoryId Memory id for the flow's AI agent steps. A uuid is used as is; any other string is hashed within the workspace and flow, so the same string always names the same memory of that flow.
8787
8820
  * @returns unknown job result
8788
8821
  * @throws ApiError
8789
8822
  */
@@ -8821,7 +8854,7 @@ var JobService = class {
8821
8854
  *
8822
8855
  * @param data.jobId The job id to assign to the created job. if missing, job is chosen randomly using the ULID scheme. If a job id already exists in the queue or as a completed job, the request to create one will fail (Bad Request)
8823
8856
  * @param data.skipPreprocessor skip the preprocessor
8824
- * @param data.memoryId memory ID for chat-enabled flows
8857
+ * @param data.memoryId Memory id for the flow's AI agent steps. A uuid is used as is; any other string is hashed within the workspace and flow, so the same string always names the same memory of that flow.
8825
8858
  * @returns unknown job result
8826
8859
  * @throws ApiError
8827
8860
  */
@@ -8856,7 +8889,7 @@ var JobService = class {
8856
8889
  *
8857
8890
  * @param data.jobId The job id to assign to the created job. if missing, job is chosen randomly using the ULID scheme. If a job id already exists in the queue or as a completed job, the request to create one will fail (Bad Request)
8858
8891
  * @param data.skipPreprocessor skip the preprocessor
8859
- * @param data.memoryId memory ID for chat-enabled flows
8892
+ * @param data.memoryId Memory id for the flow's AI agent steps. A uuid is used as is; any other string is hashed within the workspace and flow, so the same string always names the same memory of that flow.
8860
8893
  * @param data.pollDelayMs delay between polling for job updates in milliseconds
8861
8894
  * @returns string server-sent events stream of job updates
8862
8895
  * @throws ApiError
@@ -8896,7 +8929,7 @@ var JobService = class {
8896
8929
  *
8897
8930
  * @param data.jobId The job id to assign to the created job. if missing, job is chosen randomly using the ULID scheme. If a job id already exists in the queue or as a completed job, the request to create one will fail (Bad Request)
8898
8931
  * @param data.skipPreprocessor skip the preprocessor
8899
- * @param data.memoryId memory ID for chat-enabled flows
8932
+ * @param data.memoryId Memory id for the flow's AI agent steps. A uuid is used as is; any other string is hashed within the workspace and flow, so the same string always names the same memory of that flow.
8900
8933
  * @param data.pollDelayMs delay between polling for job updates in milliseconds
8901
8934
  * @returns string server-sent events stream of job updates
8902
8935
  * @throws ApiError
@@ -8933,7 +8966,7 @@ var JobService = class {
8933
8966
  *
8934
8967
  * @param data.jobId The job id to assign to the created job. if missing, job is chosen randomly using the ULID scheme. If a job id already exists in the queue or as a completed job, the request to create one will fail (Bad Request)
8935
8968
  * @param data.skipPreprocessor skip the preprocessor
8936
- * @param data.memoryId memory ID for chat-enabled flows
8969
+ * @param data.memoryId Memory id for the flow's AI agent steps. A uuid is used as is; any other string is hashed within the workspace and flow, so the same string always names the same memory of that flow.
8937
8970
  * @param data.pollDelayMs delay between polling for job updates in milliseconds
8938
8971
  * @returns string server-sent events stream of job updates
8939
8972
  * @throws ApiError
@@ -8973,7 +9006,7 @@ var JobService = class {
8973
9006
  *
8974
9007
  * @param data.jobId The job id to assign to the created job. if missing, job is chosen randomly using the ULID scheme. If a job id already exists in the queue or as a completed job, the request to create one will fail (Bad Request)
8975
9008
  * @param data.skipPreprocessor skip the preprocessor
8976
- * @param data.memoryId memory ID for chat-enabled flows
9009
+ * @param data.memoryId Memory id for the flow's AI agent steps. A uuid is used as is; any other string is hashed within the workspace and flow, so the same string always names the same memory of that flow.
8977
9010
  * @param data.pollDelayMs delay between polling for job updates in milliseconds
8978
9011
  * @returns string server-sent events stream of job updates
8979
9012
  * @throws ApiError
@@ -9243,7 +9276,7 @@ var JobService = class {
9243
9276
  * Header's key lowercased and '-'' replaced to '_' such that 'Content-Type' becomes the 'content_type' arg key
9244
9277
  *
9245
9278
  * @param data.invisibleToOwner make the run invisible to the the flow owner (default false)
9246
- * @param data.memoryId memory ID for chat-enabled flows
9279
+ * @param data.memoryId Memory id for the flow's AI agent steps. A uuid is used as is; any other string is hashed within the workspace and flow, so the same string always names the same memory of that flow.
9247
9280
  * @returns string job created
9248
9281
  * @throws ApiError
9249
9282
  */
@@ -9286,7 +9319,7 @@ var JobService = class {
9286
9319
  * Header's key lowercased and '-'' replaced to '_' such that 'Content-Type' becomes the 'content_type' arg key
9287
9320
  *
9288
9321
  * @param data.invisibleToOwner make the run invisible to the the flow owner (default false)
9289
- * @param data.memoryId memory ID for chat-enabled flows
9322
+ * @param data.memoryId Memory id for the flow's AI agent steps. A uuid is used as is; any other string is hashed within the workspace and flow, so the same string always names the same memory of that flow.
9290
9323
  * @returns string job created
9291
9324
  * @throws ApiError
9292
9325
  */
@@ -9601,7 +9634,7 @@ var JobService = class {
9601
9634
  *
9602
9635
  * @param data.invisibleToOwner make the run invisible to the the script owner (default false)
9603
9636
  * @param data.jobId The job id to assign to the created job. if missing, job is chosen randomly using the ULID scheme. If a job id already exists in the queue or as a completed job, the request to create one will fail (Bad Request)
9604
- * @param data.memoryId memory ID for chat-enabled flows
9637
+ * @param data.memoryId Memory id for the flow's AI agent steps. A uuid is used as is; any other string is hashed within the workspace and flow, so the same string always names the same memory of that flow.
9605
9638
  * @returns string job created
9606
9639
  * @throws ApiError
9607
9640
  */
@@ -9625,7 +9658,7 @@ var JobService = class {
9625
9658
  * @param data The data for the request.
9626
9659
  * @param data.workspace
9627
9660
  * @param data.requestBody preview
9628
- * @param data.memoryId memory ID for chat-enabled flows
9661
+ * @param data.memoryId Memory id for the flow's AI agent steps. A uuid is used as is; any other string is hashed within the workspace and flow, so the same string always names the same memory of that flow.
9629
9662
  * @returns unknown job result
9630
9663
  * @throws ApiError
9631
9664
  */
@@ -11400,6 +11433,7 @@ var FlowConversationsService = class {
11400
11433
  * @param data.page which page to return (start at 1, default 1)
11401
11434
  * @param data.perPage number of items to return for a given page (default 30, max 100)
11402
11435
  * @param data.flowPath filter conversations by flow path
11436
+ * @param data.kind which conversations to list - the flow editor's test chats, the deployed flow's own (the default), or both
11403
11437
  * @returns FlowConversation flow conversations list
11404
11438
  * @throws ApiError
11405
11439
  */
@@ -11411,11 +11445,33 @@ var FlowConversationsService = class {
11411
11445
  query: {
11412
11446
  page: data.page,
11413
11447
  per_page: data.perPage,
11414
- flow_path: data.flowPath
11448
+ flow_path: data.flowPath,
11449
+ kind: data.kind
11415
11450
  }
11416
11451
  });
11417
11452
  }
11418
11453
  /**
11454
+ * rename flow conversation
11455
+ * @param data The data for the request.
11456
+ * @param data.workspace
11457
+ * @param data.conversationId conversation id
11458
+ * @param data.requestBody
11459
+ * @returns string flow conversation updated
11460
+ * @throws ApiError
11461
+ */
11462
+ static updateFlowConversation(data) {
11463
+ return request(OpenAPI, {
11464
+ method: "POST",
11465
+ url: "/w/{workspace}/flow_conversations/update/{conversation_id}",
11466
+ path: {
11467
+ workspace: data.workspace,
11468
+ conversation_id: data.conversationId
11469
+ },
11470
+ body: data.requestBody,
11471
+ mediaType: "application/json"
11472
+ });
11473
+ }
11474
+ /**
11419
11475
  * delete flow conversation
11420
11476
  * @param data The data for the request.
11421
11477
  * @param data.workspace
@@ -11832,6 +11888,54 @@ var AiService = class {
11832
11888
  });
11833
11889
  }
11834
11890
  /**
11891
+ * list the calling user's AI session backups in the workspace object storage
11892
+ * @param data The data for the request.
11893
+ * @param data.workspace
11894
+ * @returns unknown backups, newest first; `enabled` is false when the workspace has no storage for them
11895
+ * @throws ApiError
11896
+ */
11897
+ static listAiSessionBackups(data) {
11898
+ return request(OpenAPI, {
11899
+ method: "GET",
11900
+ url: "/w/{workspace}/ai/sessions/list",
11901
+ path: { workspace: data.workspace }
11902
+ });
11903
+ }
11904
+ /**
11905
+ * fetch whole AI session backups
11906
+ * @param data The data for the request.
11907
+ * @param data.workspace
11908
+ * @param data.requestBody
11909
+ * @returns unknown the backups found; `deferred` lists ids that did not fit the response budget
11910
+ * @throws ApiError
11911
+ */
11912
+ static pullAiSessionBackups(data) {
11913
+ return request(OpenAPI, {
11914
+ method: "POST",
11915
+ url: "/w/{workspace}/ai/sessions/pull",
11916
+ path: { workspace: data.workspace },
11917
+ body: data.requestBody,
11918
+ mediaType: "application/json"
11919
+ });
11920
+ }
11921
+ /**
11922
+ * write changed pieces of AI sessions to their backups, and remove deleted ones
11923
+ * @param data The data for the request.
11924
+ * @param data.workspace
11925
+ * @param data.requestBody
11926
+ * @returns unknown one result per session written or removed, in request order
11927
+ * @throws ApiError
11928
+ */
11929
+ static pushAiSessionBackups(data) {
11930
+ return request(OpenAPI, {
11931
+ method: "POST",
11932
+ url: "/w/{workspace}/ai/sessions/push",
11933
+ path: { workspace: data.workspace },
11934
+ body: data.requestBody,
11935
+ mediaType: "application/json"
11936
+ });
11937
+ }
11938
+ /**
11835
11939
  * share an AI session artifact with the workspace
11836
11940
  * Stores a read-only copy that any member of the workspace can open by id. Sharing the same artifact again updates that copy, keeps its id, and restarts its retention window.
11837
11941
  *