@knowledge-stack/ksapi 3.13.1 → 3.14.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/.openapi-generator/FILES +4 -0
- package/README.md +6 -2
- package/dist/apis/DocumentVersionsApi.d.ts +4 -4
- package/dist/apis/DocumentVersionsApi.js +2 -2
- package/dist/apis/DocumentsApi.d.ts +4 -4
- package/dist/apis/DocumentsApi.js +2 -2
- package/dist/apis/SystemJobsApi.d.ts +126 -17
- package/dist/apis/SystemJobsApi.js +137 -8
- package/dist/esm/apis/DocumentVersionsApi.d.ts +4 -4
- package/dist/esm/apis/DocumentVersionsApi.js +2 -2
- package/dist/esm/apis/DocumentsApi.d.ts +4 -4
- package/dist/esm/apis/DocumentsApi.js +2 -2
- package/dist/esm/apis/SystemJobsApi.d.ts +126 -17
- package/dist/esm/apis/SystemJobsApi.js +138 -9
- package/dist/esm/models/BulkFailureReason.d.ts +3 -0
- package/dist/esm/models/BulkFailureReason.js +4 -1
- package/dist/esm/models/BulkRerunRequest.d.ts +47 -0
- package/dist/esm/models/BulkRerunRequest.js +42 -0
- package/dist/esm/models/PaginatedResponseUserInfo.d.ts +66 -0
- package/dist/esm/models/PaginatedResponseUserInfo.js +70 -0
- package/dist/esm/models/WorkflowDetailResponse.d.ts +26 -1
- package/dist/esm/models/WorkflowDetailResponse.js +17 -0
- package/dist/esm/models/WorkflowSummaryResponse.d.ts +26 -1
- package/dist/esm/models/WorkflowSummaryResponse.js +17 -0
- package/dist/esm/models/index.d.ts +2 -0
- package/dist/esm/models/index.js +2 -0
- package/dist/models/BulkFailureReason.d.ts +3 -0
- package/dist/models/BulkFailureReason.js +4 -1
- package/dist/models/BulkRerunRequest.d.ts +47 -0
- package/dist/models/BulkRerunRequest.js +50 -0
- package/dist/models/PaginatedResponseUserInfo.d.ts +66 -0
- package/dist/models/PaginatedResponseUserInfo.js +78 -0
- package/dist/models/WorkflowDetailResponse.d.ts +26 -1
- package/dist/models/WorkflowDetailResponse.js +17 -0
- package/dist/models/WorkflowSummaryResponse.d.ts +26 -1
- package/dist/models/WorkflowSummaryResponse.js +17 -0
- package/dist/models/index.d.ts +2 -0
- package/dist/models/index.js +2 -0
- package/docs/BulkRerunRequest.md +35 -0
- package/docs/DocumentVersionsApi.md +1 -1
- package/docs/DocumentsApi.md +1 -1
- package/docs/PaginatedResponseUserInfo.md +40 -0
- package/docs/SystemJobsApi.md +190 -5
- package/docs/WorkflowDetailResponse.md +8 -0
- package/docs/WorkflowSummaryResponse.md +8 -0
- package/package.json +1 -1
- package/src/apis/DocumentVersionsApi.ts +4 -4
- package/src/apis/DocumentsApi.ts +4 -4
- package/src/apis/SystemJobsApi.ts +272 -16
- package/src/models/BulkFailureReason.ts +4 -1
- package/src/models/BulkRerunRequest.ts +82 -0
- package/src/models/PaginatedResponseUserInfo.ts +130 -0
- package/src/models/WorkflowDetailResponse.ts +44 -1
- package/src/models/WorkflowSummaryResponse.ts +44 -1
- package/src/models/index.ts +2 -0
|
@@ -10,7 +10,10 @@
|
|
|
10
10
|
* Do not edit the class manually.
|
|
11
11
|
*/
|
|
12
12
|
import * as runtime from '../runtime';
|
|
13
|
-
import type { PaginatedResponseWorkflowSummaryResponse, TemporalWorkflowStatusResponse, WorkflowActionResponse, WorkflowCancelResponse, WorkflowDetailResponse, ZipIngestionStatusResponse } from '../models/index';
|
|
13
|
+
import type { BulkOperationResponse, BulkRerunRequest, PaginatedResponseUserInfo, PaginatedResponseWorkflowSummaryResponse, PipelineStatus, SortDirection, TemporalWorkflowStatusResponse, WorkflowActionResponse, WorkflowCancelResponse, WorkflowDetailResponse, ZipIngestionStatusResponse } from '../models/index';
|
|
14
|
+
export interface BulkRerunDvWorkflowsRequest {
|
|
15
|
+
bulkRerunRequest: BulkRerunRequest;
|
|
16
|
+
}
|
|
14
17
|
export interface CancelTemporalWorkflowRequest {
|
|
15
18
|
workflowId: string;
|
|
16
19
|
}
|
|
@@ -26,9 +29,23 @@ export interface GetTemporalWorkflowStatusRequest {
|
|
|
26
29
|
export interface GetZipIngestionStatusRequest {
|
|
27
30
|
workflowId: string;
|
|
28
31
|
}
|
|
32
|
+
export interface ListDvWorkflowUploadersRequest {
|
|
33
|
+
usernameLike?: string | null;
|
|
34
|
+
limit?: number;
|
|
35
|
+
offset?: number;
|
|
36
|
+
}
|
|
29
37
|
export interface ListDvWorkflowsRequest {
|
|
30
38
|
limit?: number;
|
|
31
39
|
offset?: number;
|
|
40
|
+
sortDir?: SortDirection;
|
|
41
|
+
status?: Array<PipelineStatus> | null;
|
|
42
|
+
nameLike?: string | null;
|
|
43
|
+
latestVersionOnly?: boolean;
|
|
44
|
+
uploaderUserId?: string | null;
|
|
45
|
+
createdAfter?: Date | null;
|
|
46
|
+
createdBefore?: Date | null;
|
|
47
|
+
updatedAfter?: Date | null;
|
|
48
|
+
updatedBefore?: Date | null;
|
|
32
49
|
}
|
|
33
50
|
/**
|
|
34
51
|
* SystemJobsApi - interface
|
|
@@ -37,6 +54,27 @@ export interface ListDvWorkflowsRequest {
|
|
|
37
54
|
* @interface SystemJobsApiInterface
|
|
38
55
|
*/
|
|
39
56
|
export interface SystemJobsApiInterface {
|
|
57
|
+
/**
|
|
58
|
+
* Creates request options for bulkRerunDvWorkflows without sending the request
|
|
59
|
+
* @param {BulkRerunRequest} bulkRerunRequest
|
|
60
|
+
* @throws {RequiredError}
|
|
61
|
+
* @memberof SystemJobsApiInterface
|
|
62
|
+
*/
|
|
63
|
+
bulkRerunDvWorkflowsRequestOpts(requestParameters: BulkRerunDvWorkflowsRequest): Promise<runtime.RequestOpts>;
|
|
64
|
+
/**
|
|
65
|
+
* Re-run ingestion for the selected document versions, reporting per item. ``not_found``: missing, trashed, never ingested or without its stored source; ``forbidden``: no ``can_write``; ``in_progress_workflow``: still pending/processing; ``already_ingested``: completed; ``unsupported_document_type``: a type that is no longer ingested; ``superseded``: a newer version of the document exists. More than 200 ids is a 400 before any re-run.
|
|
66
|
+
* @summary Bulk Rerun Dv Workflows Handler
|
|
67
|
+
* @param {BulkRerunRequest} bulkRerunRequest
|
|
68
|
+
* @param {*} [options] Override http request option.
|
|
69
|
+
* @throws {RequiredError}
|
|
70
|
+
* @memberof SystemJobsApiInterface
|
|
71
|
+
*/
|
|
72
|
+
bulkRerunDvWorkflowsRaw(requestParameters: BulkRerunDvWorkflowsRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<BulkOperationResponse>>;
|
|
73
|
+
/**
|
|
74
|
+
* Re-run ingestion for the selected document versions, reporting per item. ``not_found``: missing, trashed, never ingested or without its stored source; ``forbidden``: no ``can_write``; ``in_progress_workflow``: still pending/processing; ``already_ingested``: completed; ``unsupported_document_type``: a type that is no longer ingested; ``superseded``: a newer version of the document exists. More than 200 ids is a 400 before any re-run.
|
|
75
|
+
* Bulk Rerun Dv Workflows Handler
|
|
76
|
+
*/
|
|
77
|
+
bulkRerunDvWorkflows(requestParameters: BulkRerunDvWorkflowsRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<BulkOperationResponse>;
|
|
40
78
|
/**
|
|
41
79
|
* Creates request options for cancelTemporalWorkflow without sending the request
|
|
42
80
|
* @param {string} workflowId
|
|
@@ -45,7 +83,7 @@ export interface SystemJobsApiInterface {
|
|
|
45
83
|
*/
|
|
46
84
|
cancelTemporalWorkflowRequestOpts(requestParameters: CancelTemporalWorkflowRequest): Promise<runtime.RequestOpts>;
|
|
47
85
|
/**
|
|
48
|
-
* Cancel any Temporal workflow owned by the caller\'s tenant. No status guard — this is a thin Temporal wrapper. Cancelling an already-terminal workflow is a no-op on the Temporal side.
|
|
86
|
+
* Cancel any Temporal workflow owned by the caller\'s tenant. No status guard — this is a thin Temporal wrapper. Cancelling an already-terminal workflow is a no-op on the Temporal side. A run no worker ever picked up is terminated instead, since a cancel request is itself a workflow task nobody would process. When Temporal no longer has the run, or it was terminated here, a document version still showing it running is settled as cancelled (needs ``can_write``) so it can be re-run.
|
|
49
87
|
* @summary Cancel Temporal Workflow Handler
|
|
50
88
|
* @param {string} workflowId
|
|
51
89
|
* @param {*} [options] Override http request option.
|
|
@@ -54,7 +92,7 @@ export interface SystemJobsApiInterface {
|
|
|
54
92
|
*/
|
|
55
93
|
cancelTemporalWorkflowRaw(requestParameters: CancelTemporalWorkflowRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<WorkflowCancelResponse>>;
|
|
56
94
|
/**
|
|
57
|
-
* Cancel any Temporal workflow owned by the caller\'s tenant. No status guard — this is a thin Temporal wrapper. Cancelling an already-terminal workflow is a no-op on the Temporal side.
|
|
95
|
+
* Cancel any Temporal workflow owned by the caller\'s tenant. No status guard — this is a thin Temporal wrapper. Cancelling an already-terminal workflow is a no-op on the Temporal side. A run no worker ever picked up is terminated instead, since a cancel request is itself a workflow task nobody would process. When Temporal no longer has the run, or it was terminated here, a document version still showing it running is settled as cancelled (needs ``can_write``) so it can be re-run.
|
|
58
96
|
* Cancel Temporal Workflow Handler
|
|
59
97
|
*/
|
|
60
98
|
cancelTemporalWorkflow(requestParameters: CancelTemporalWorkflowRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<WorkflowCancelResponse>;
|
|
@@ -66,7 +104,7 @@ export interface SystemJobsApiInterface {
|
|
|
66
104
|
*/
|
|
67
105
|
dvWorkflowRerunRequestOpts(requestParameters: DvWorkflowRerunRequest): Promise<runtime.RequestOpts>;
|
|
68
106
|
/**
|
|
69
|
-
* Rerun a workflow. USER role requires ``can_write`` on the document path. ``s3_client`` is injected because ``DocumentIngestionService.__init__`` requires it, even though the re-ingestion path reuses the existing S3 source.
|
|
107
|
+
* Rerun a workflow. USER role requires ``can_write`` on the document path. A version that a newer live version supersedes is refused with 409. ``s3_client`` is injected because ``DocumentIngestionService.__init__`` requires it, even though the re-ingestion path reuses the existing S3 source.
|
|
70
108
|
* @summary Dv Workflow Rerun Handler
|
|
71
109
|
* @param {string} workflowId
|
|
72
110
|
* @param {*} [options] Override http request option.
|
|
@@ -75,7 +113,7 @@ export interface SystemJobsApiInterface {
|
|
|
75
113
|
*/
|
|
76
114
|
dvWorkflowRerunRaw(requestParameters: DvWorkflowRerunRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<WorkflowActionResponse>>;
|
|
77
115
|
/**
|
|
78
|
-
* Rerun a workflow. USER role requires ``can_write`` on the document path. ``s3_client`` is injected because ``DocumentIngestionService.__init__`` requires it, even though the re-ingestion path reuses the existing S3 source.
|
|
116
|
+
* Rerun a workflow. USER role requires ``can_write`` on the document path. A version that a newer live version supersedes is refused with 409. ``s3_client`` is injected because ``DocumentIngestionService.__init__`` requires it, even though the re-ingestion path reuses the existing S3 source.
|
|
79
117
|
* Dv Workflow Rerun Handler
|
|
80
118
|
*/
|
|
81
119
|
dvWorkflowRerun(requestParameters: DvWorkflowRerunRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<WorkflowActionResponse>;
|
|
@@ -129,7 +167,7 @@ export interface SystemJobsApiInterface {
|
|
|
129
167
|
*/
|
|
130
168
|
getZipIngestionStatusRequestOpts(requestParameters: GetZipIngestionStatusRequest): Promise<runtime.RequestOpts>;
|
|
131
169
|
/**
|
|
132
|
-
* Get a ZIP fan-out\'s live status + per-member outcomes. Tenant-scoped via the TenantId search attribute (no per-path can_read check — intentionally consistent with the sibling generic Temporal endpoints below; the opaque workflow_id is only handed to the uploader, who had can_write on the target). The per-member results come from the workflow\'s ``results`` query (served from retained history), so once Temporal retention expires this 404s.
|
|
170
|
+
* Get a ZIP fan-out\'s live status + per-member outcomes. Tenant-scoped via the TenantId search attribute (no per-path can_read check — intentionally consistent with the sibling generic Temporal endpoints below; the opaque workflow_id is only handed to the uploader, who had can_write on the target). The per-member results come from the workflow\'s ``results`` query (served from retained history), so once Temporal retention expires this 404s. Any other workflow type has no ``results`` query and is a 404, not a 500.
|
|
133
171
|
* @summary Get Zip Ingestion Status Handler
|
|
134
172
|
* @param {string} workflowId
|
|
135
173
|
* @param {*} [options] Override http request option.
|
|
@@ -138,30 +176,73 @@ export interface SystemJobsApiInterface {
|
|
|
138
176
|
*/
|
|
139
177
|
getZipIngestionStatusRaw(requestParameters: GetZipIngestionStatusRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<ZipIngestionStatusResponse>>;
|
|
140
178
|
/**
|
|
141
|
-
* Get a ZIP fan-out\'s live status + per-member outcomes. Tenant-scoped via the TenantId search attribute (no per-path can_read check — intentionally consistent with the sibling generic Temporal endpoints below; the opaque workflow_id is only handed to the uploader, who had can_write on the target). The per-member results come from the workflow\'s ``results`` query (served from retained history), so once Temporal retention expires this 404s.
|
|
179
|
+
* Get a ZIP fan-out\'s live status + per-member outcomes. Tenant-scoped via the TenantId search attribute (no per-path can_read check — intentionally consistent with the sibling generic Temporal endpoints below; the opaque workflow_id is only handed to the uploader, who had can_write on the target). The per-member results come from the workflow\'s ``results`` query (served from retained history), so once Temporal retention expires this 404s. Any other workflow type has no ``results`` query and is a 404, not a 500.
|
|
142
180
|
* Get Zip Ingestion Status Handler
|
|
143
181
|
*/
|
|
144
182
|
getZipIngestionStatus(requestParameters: GetZipIngestionStatusRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<ZipIngestionStatusResponse>;
|
|
183
|
+
/**
|
|
184
|
+
* Creates request options for listDvWorkflowUploaders without sending the request
|
|
185
|
+
* @param {string} [usernameLike] Case-insensitive substring of the first or last name
|
|
186
|
+
* @param {number} [limit] Number of items per page
|
|
187
|
+
* @param {number} [offset] Number of items to skip
|
|
188
|
+
* @throws {RequiredError}
|
|
189
|
+
* @memberof SystemJobsApiInterface
|
|
190
|
+
*/
|
|
191
|
+
listDvWorkflowUploadersRequestOpts(requestParameters: ListDvWorkflowUploadersRequest): Promise<runtime.RequestOpts>;
|
|
192
|
+
/**
|
|
193
|
+
* People who uploaded a version the caller can list, for the uploader filter. Scoped like ``list_dv_workflows``: USER only counts versions under readable paths.
|
|
194
|
+
* @summary List Dv Workflow Uploaders Handler
|
|
195
|
+
* @param {string} [usernameLike] Case-insensitive substring of the first or last name
|
|
196
|
+
* @param {number} [limit] Number of items per page
|
|
197
|
+
* @param {number} [offset] Number of items to skip
|
|
198
|
+
* @param {*} [options] Override http request option.
|
|
199
|
+
* @throws {RequiredError}
|
|
200
|
+
* @memberof SystemJobsApiInterface
|
|
201
|
+
*/
|
|
202
|
+
listDvWorkflowUploadersRaw(requestParameters: ListDvWorkflowUploadersRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<PaginatedResponseUserInfo>>;
|
|
203
|
+
/**
|
|
204
|
+
* People who uploaded a version the caller can list, for the uploader filter. Scoped like ``list_dv_workflows``: USER only counts versions under readable paths.
|
|
205
|
+
* List Dv Workflow Uploaders Handler
|
|
206
|
+
*/
|
|
207
|
+
listDvWorkflowUploaders(requestParameters: ListDvWorkflowUploadersRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<PaginatedResponseUserInfo>;
|
|
145
208
|
/**
|
|
146
209
|
* Creates request options for listDvWorkflows without sending the request
|
|
147
210
|
* @param {number} [limit] Number of items per page
|
|
148
211
|
* @param {number} [offset] Number of items to skip
|
|
212
|
+
* @param {SortDirection} [sortDir] Sort direction (ASC or DESC); overrides the field\'s natural default. Every sort field supports both directions.
|
|
213
|
+
* @param {Array<PipelineStatus>} [status] Only versions in one of these pipeline statuses
|
|
214
|
+
* @param {string} [nameLike] Case-insensitive substring filter on document name
|
|
215
|
+
* @param {boolean} [latestVersionOnly] Skip versions superseded by a newer version
|
|
216
|
+
* @param {string} [uploaderUserId] Filter to versions uploaded by this user
|
|
217
|
+
* @param {Date} [createdAfter] Only items created at or after this timestamp (inclusive)
|
|
218
|
+
* @param {Date} [createdBefore] Only items created strictly before this timestamp
|
|
219
|
+
* @param {Date} [updatedAfter] Only items updated at or after this timestamp (inclusive)
|
|
220
|
+
* @param {Date} [updatedBefore] Only items updated strictly before this timestamp
|
|
149
221
|
* @throws {RequiredError}
|
|
150
222
|
* @memberof SystemJobsApiInterface
|
|
151
223
|
*/
|
|
152
224
|
listDvWorkflowsRequestOpts(requestParameters: ListDvWorkflowsRequest): Promise<runtime.RequestOpts>;
|
|
153
225
|
/**
|
|
154
|
-
* List
|
|
226
|
+
* List ingestions of live documents in the current tenant, newest upload first. ADMIN/OWNER see every version; USER only versions under readable paths. ``sort_dir=ASC`` lists the oldest upload first.
|
|
155
227
|
* @summary List Dv Workflows Handler
|
|
156
228
|
* @param {number} [limit] Number of items per page
|
|
157
229
|
* @param {number} [offset] Number of items to skip
|
|
230
|
+
* @param {SortDirection} [sortDir] Sort direction (ASC or DESC); overrides the field\'s natural default. Every sort field supports both directions.
|
|
231
|
+
* @param {Array<PipelineStatus>} [status] Only versions in one of these pipeline statuses
|
|
232
|
+
* @param {string} [nameLike] Case-insensitive substring filter on document name
|
|
233
|
+
* @param {boolean} [latestVersionOnly] Skip versions superseded by a newer version
|
|
234
|
+
* @param {string} [uploaderUserId] Filter to versions uploaded by this user
|
|
235
|
+
* @param {Date} [createdAfter] Only items created at or after this timestamp (inclusive)
|
|
236
|
+
* @param {Date} [createdBefore] Only items created strictly before this timestamp
|
|
237
|
+
* @param {Date} [updatedAfter] Only items updated at or after this timestamp (inclusive)
|
|
238
|
+
* @param {Date} [updatedBefore] Only items updated strictly before this timestamp
|
|
158
239
|
* @param {*} [options] Override http request option.
|
|
159
240
|
* @throws {RequiredError}
|
|
160
241
|
* @memberof SystemJobsApiInterface
|
|
161
242
|
*/
|
|
162
243
|
listDvWorkflowsRaw(requestParameters: ListDvWorkflowsRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<PaginatedResponseWorkflowSummaryResponse>>;
|
|
163
244
|
/**
|
|
164
|
-
* List
|
|
245
|
+
* List ingestions of live documents in the current tenant, newest upload first. ADMIN/OWNER see every version; USER only versions under readable paths. ``sort_dir=ASC`` lists the oldest upload first.
|
|
165
246
|
* List Dv Workflows Handler
|
|
166
247
|
*/
|
|
167
248
|
listDvWorkflows(requestParameters: ListDvWorkflowsRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<PaginatedResponseWorkflowSummaryResponse>;
|
|
@@ -170,17 +251,31 @@ export interface SystemJobsApiInterface {
|
|
|
170
251
|
*
|
|
171
252
|
*/
|
|
172
253
|
export declare class SystemJobsApi extends runtime.BaseAPI implements SystemJobsApiInterface {
|
|
254
|
+
/**
|
|
255
|
+
* Creates request options for bulkRerunDvWorkflows without sending the request
|
|
256
|
+
*/
|
|
257
|
+
bulkRerunDvWorkflowsRequestOpts(requestParameters: BulkRerunDvWorkflowsRequest): Promise<runtime.RequestOpts>;
|
|
258
|
+
/**
|
|
259
|
+
* Re-run ingestion for the selected document versions, reporting per item. ``not_found``: missing, trashed, never ingested or without its stored source; ``forbidden``: no ``can_write``; ``in_progress_workflow``: still pending/processing; ``already_ingested``: completed; ``unsupported_document_type``: a type that is no longer ingested; ``superseded``: a newer version of the document exists. More than 200 ids is a 400 before any re-run.
|
|
260
|
+
* Bulk Rerun Dv Workflows Handler
|
|
261
|
+
*/
|
|
262
|
+
bulkRerunDvWorkflowsRaw(requestParameters: BulkRerunDvWorkflowsRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<BulkOperationResponse>>;
|
|
263
|
+
/**
|
|
264
|
+
* Re-run ingestion for the selected document versions, reporting per item. ``not_found``: missing, trashed, never ingested or without its stored source; ``forbidden``: no ``can_write``; ``in_progress_workflow``: still pending/processing; ``already_ingested``: completed; ``unsupported_document_type``: a type that is no longer ingested; ``superseded``: a newer version of the document exists. More than 200 ids is a 400 before any re-run.
|
|
265
|
+
* Bulk Rerun Dv Workflows Handler
|
|
266
|
+
*/
|
|
267
|
+
bulkRerunDvWorkflows(requestParameters: BulkRerunDvWorkflowsRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<BulkOperationResponse>;
|
|
173
268
|
/**
|
|
174
269
|
* Creates request options for cancelTemporalWorkflow without sending the request
|
|
175
270
|
*/
|
|
176
271
|
cancelTemporalWorkflowRequestOpts(requestParameters: CancelTemporalWorkflowRequest): Promise<runtime.RequestOpts>;
|
|
177
272
|
/**
|
|
178
|
-
* Cancel any Temporal workflow owned by the caller\'s tenant. No status guard — this is a thin Temporal wrapper. Cancelling an already-terminal workflow is a no-op on the Temporal side.
|
|
273
|
+
* Cancel any Temporal workflow owned by the caller\'s tenant. No status guard — this is a thin Temporal wrapper. Cancelling an already-terminal workflow is a no-op on the Temporal side. A run no worker ever picked up is terminated instead, since a cancel request is itself a workflow task nobody would process. When Temporal no longer has the run, or it was terminated here, a document version still showing it running is settled as cancelled (needs ``can_write``) so it can be re-run.
|
|
179
274
|
* Cancel Temporal Workflow Handler
|
|
180
275
|
*/
|
|
181
276
|
cancelTemporalWorkflowRaw(requestParameters: CancelTemporalWorkflowRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<WorkflowCancelResponse>>;
|
|
182
277
|
/**
|
|
183
|
-
* Cancel any Temporal workflow owned by the caller\'s tenant. No status guard — this is a thin Temporal wrapper. Cancelling an already-terminal workflow is a no-op on the Temporal side.
|
|
278
|
+
* Cancel any Temporal workflow owned by the caller\'s tenant. No status guard — this is a thin Temporal wrapper. Cancelling an already-terminal workflow is a no-op on the Temporal side. A run no worker ever picked up is terminated instead, since a cancel request is itself a workflow task nobody would process. When Temporal no longer has the run, or it was terminated here, a document version still showing it running is settled as cancelled (needs ``can_write``) so it can be re-run.
|
|
184
279
|
* Cancel Temporal Workflow Handler
|
|
185
280
|
*/
|
|
186
281
|
cancelTemporalWorkflow(requestParameters: CancelTemporalWorkflowRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<WorkflowCancelResponse>;
|
|
@@ -189,12 +284,12 @@ export declare class SystemJobsApi extends runtime.BaseAPI implements SystemJobs
|
|
|
189
284
|
*/
|
|
190
285
|
dvWorkflowRerunRequestOpts(requestParameters: DvWorkflowRerunRequest): Promise<runtime.RequestOpts>;
|
|
191
286
|
/**
|
|
192
|
-
* Rerun a workflow. USER role requires ``can_write`` on the document path. ``s3_client`` is injected because ``DocumentIngestionService.__init__`` requires it, even though the re-ingestion path reuses the existing S3 source.
|
|
287
|
+
* Rerun a workflow. USER role requires ``can_write`` on the document path. A version that a newer live version supersedes is refused with 409. ``s3_client`` is injected because ``DocumentIngestionService.__init__`` requires it, even though the re-ingestion path reuses the existing S3 source.
|
|
193
288
|
* Dv Workflow Rerun Handler
|
|
194
289
|
*/
|
|
195
290
|
dvWorkflowRerunRaw(requestParameters: DvWorkflowRerunRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<WorkflowActionResponse>>;
|
|
196
291
|
/**
|
|
197
|
-
* Rerun a workflow. USER role requires ``can_write`` on the document path. ``s3_client`` is injected because ``DocumentIngestionService.__init__`` requires it, even though the re-ingestion path reuses the existing S3 source.
|
|
292
|
+
* Rerun a workflow. USER role requires ``can_write`` on the document path. A version that a newer live version supersedes is refused with 409. ``s3_client`` is injected because ``DocumentIngestionService.__init__`` requires it, even though the re-ingestion path reuses the existing S3 source.
|
|
198
293
|
* Dv Workflow Rerun Handler
|
|
199
294
|
*/
|
|
200
295
|
dvWorkflowRerun(requestParameters: DvWorkflowRerunRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<WorkflowActionResponse>;
|
|
@@ -231,26 +326,40 @@ export declare class SystemJobsApi extends runtime.BaseAPI implements SystemJobs
|
|
|
231
326
|
*/
|
|
232
327
|
getZipIngestionStatusRequestOpts(requestParameters: GetZipIngestionStatusRequest): Promise<runtime.RequestOpts>;
|
|
233
328
|
/**
|
|
234
|
-
* Get a ZIP fan-out\'s live status + per-member outcomes. Tenant-scoped via the TenantId search attribute (no per-path can_read check — intentionally consistent with the sibling generic Temporal endpoints below; the opaque workflow_id is only handed to the uploader, who had can_write on the target). The per-member results come from the workflow\'s ``results`` query (served from retained history), so once Temporal retention expires this 404s.
|
|
329
|
+
* Get a ZIP fan-out\'s live status + per-member outcomes. Tenant-scoped via the TenantId search attribute (no per-path can_read check — intentionally consistent with the sibling generic Temporal endpoints below; the opaque workflow_id is only handed to the uploader, who had can_write on the target). The per-member results come from the workflow\'s ``results`` query (served from retained history), so once Temporal retention expires this 404s. Any other workflow type has no ``results`` query and is a 404, not a 500.
|
|
235
330
|
* Get Zip Ingestion Status Handler
|
|
236
331
|
*/
|
|
237
332
|
getZipIngestionStatusRaw(requestParameters: GetZipIngestionStatusRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<ZipIngestionStatusResponse>>;
|
|
238
333
|
/**
|
|
239
|
-
* Get a ZIP fan-out\'s live status + per-member outcomes. Tenant-scoped via the TenantId search attribute (no per-path can_read check — intentionally consistent with the sibling generic Temporal endpoints below; the opaque workflow_id is only handed to the uploader, who had can_write on the target). The per-member results come from the workflow\'s ``results`` query (served from retained history), so once Temporal retention expires this 404s.
|
|
334
|
+
* Get a ZIP fan-out\'s live status + per-member outcomes. Tenant-scoped via the TenantId search attribute (no per-path can_read check — intentionally consistent with the sibling generic Temporal endpoints below; the opaque workflow_id is only handed to the uploader, who had can_write on the target). The per-member results come from the workflow\'s ``results`` query (served from retained history), so once Temporal retention expires this 404s. Any other workflow type has no ``results`` query and is a 404, not a 500.
|
|
240
335
|
* Get Zip Ingestion Status Handler
|
|
241
336
|
*/
|
|
242
337
|
getZipIngestionStatus(requestParameters: GetZipIngestionStatusRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<ZipIngestionStatusResponse>;
|
|
338
|
+
/**
|
|
339
|
+
* Creates request options for listDvWorkflowUploaders without sending the request
|
|
340
|
+
*/
|
|
341
|
+
listDvWorkflowUploadersRequestOpts(requestParameters: ListDvWorkflowUploadersRequest): Promise<runtime.RequestOpts>;
|
|
342
|
+
/**
|
|
343
|
+
* People who uploaded a version the caller can list, for the uploader filter. Scoped like ``list_dv_workflows``: USER only counts versions under readable paths.
|
|
344
|
+
* List Dv Workflow Uploaders Handler
|
|
345
|
+
*/
|
|
346
|
+
listDvWorkflowUploadersRaw(requestParameters: ListDvWorkflowUploadersRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<PaginatedResponseUserInfo>>;
|
|
347
|
+
/**
|
|
348
|
+
* People who uploaded a version the caller can list, for the uploader filter. Scoped like ``list_dv_workflows``: USER only counts versions under readable paths.
|
|
349
|
+
* List Dv Workflow Uploaders Handler
|
|
350
|
+
*/
|
|
351
|
+
listDvWorkflowUploaders(requestParameters?: ListDvWorkflowUploadersRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<PaginatedResponseUserInfo>;
|
|
243
352
|
/**
|
|
244
353
|
* Creates request options for listDvWorkflows without sending the request
|
|
245
354
|
*/
|
|
246
355
|
listDvWorkflowsRequestOpts(requestParameters: ListDvWorkflowsRequest): Promise<runtime.RequestOpts>;
|
|
247
356
|
/**
|
|
248
|
-
* List
|
|
357
|
+
* List ingestions of live documents in the current tenant, newest upload first. ADMIN/OWNER see every version; USER only versions under readable paths. ``sort_dir=ASC`` lists the oldest upload first.
|
|
249
358
|
* List Dv Workflows Handler
|
|
250
359
|
*/
|
|
251
360
|
listDvWorkflowsRaw(requestParameters: ListDvWorkflowsRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<PaginatedResponseWorkflowSummaryResponse>>;
|
|
252
361
|
/**
|
|
253
|
-
* List
|
|
362
|
+
* List ingestions of live documents in the current tenant, newest upload first. ADMIN/OWNER see every version; USER only versions under readable paths. ``sort_dir=ASC`` lists the oldest upload first.
|
|
254
363
|
* List Dv Workflows Handler
|
|
255
364
|
*/
|
|
256
365
|
listDvWorkflows(requestParameters?: ListDvWorkflowsRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<PaginatedResponseWorkflowSummaryResponse>;
|
|
@@ -21,11 +21,60 @@ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, ge
|
|
|
21
21
|
});
|
|
22
22
|
};
|
|
23
23
|
import * as runtime from '../runtime';
|
|
24
|
-
import { PaginatedResponseWorkflowSummaryResponseFromJSON, TemporalWorkflowStatusResponseFromJSON, WorkflowActionResponseFromJSON, WorkflowCancelResponseFromJSON, WorkflowDetailResponseFromJSON, ZipIngestionStatusResponseFromJSON, } from '../models/index';
|
|
24
|
+
import { BulkOperationResponseFromJSON, BulkRerunRequestToJSON, PaginatedResponseUserInfoFromJSON, PaginatedResponseWorkflowSummaryResponseFromJSON, TemporalWorkflowStatusResponseFromJSON, WorkflowActionResponseFromJSON, WorkflowCancelResponseFromJSON, WorkflowDetailResponseFromJSON, ZipIngestionStatusResponseFromJSON, } from '../models/index';
|
|
25
25
|
/**
|
|
26
26
|
*
|
|
27
27
|
*/
|
|
28
28
|
export class SystemJobsApi extends runtime.BaseAPI {
|
|
29
|
+
/**
|
|
30
|
+
* Creates request options for bulkRerunDvWorkflows without sending the request
|
|
31
|
+
*/
|
|
32
|
+
bulkRerunDvWorkflowsRequestOpts(requestParameters) {
|
|
33
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
34
|
+
if (requestParameters['bulkRerunRequest'] == null) {
|
|
35
|
+
throw new runtime.RequiredError('bulkRerunRequest', 'Required parameter "bulkRerunRequest" was null or undefined when calling bulkRerunDvWorkflows().');
|
|
36
|
+
}
|
|
37
|
+
const queryParameters = {};
|
|
38
|
+
const headerParameters = {};
|
|
39
|
+
headerParameters['Content-Type'] = 'application/json';
|
|
40
|
+
if (this.configuration && this.configuration.accessToken) {
|
|
41
|
+
const token = this.configuration.accessToken;
|
|
42
|
+
const tokenString = yield token("bearerAuth", []);
|
|
43
|
+
if (tokenString) {
|
|
44
|
+
headerParameters["Authorization"] = `Bearer ${tokenString}`;
|
|
45
|
+
}
|
|
46
|
+
}
|
|
47
|
+
let urlPath = `/v1/system-jobs/document_versions/bulk-rerun`;
|
|
48
|
+
return {
|
|
49
|
+
path: urlPath,
|
|
50
|
+
method: 'POST',
|
|
51
|
+
headers: headerParameters,
|
|
52
|
+
query: queryParameters,
|
|
53
|
+
body: BulkRerunRequestToJSON(requestParameters['bulkRerunRequest']),
|
|
54
|
+
};
|
|
55
|
+
});
|
|
56
|
+
}
|
|
57
|
+
/**
|
|
58
|
+
* Re-run ingestion for the selected document versions, reporting per item. ``not_found``: missing, trashed, never ingested or without its stored source; ``forbidden``: no ``can_write``; ``in_progress_workflow``: still pending/processing; ``already_ingested``: completed; ``unsupported_document_type``: a type that is no longer ingested; ``superseded``: a newer version of the document exists. More than 200 ids is a 400 before any re-run.
|
|
59
|
+
* Bulk Rerun Dv Workflows Handler
|
|
60
|
+
*/
|
|
61
|
+
bulkRerunDvWorkflowsRaw(requestParameters, initOverrides) {
|
|
62
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
63
|
+
const requestOptions = yield this.bulkRerunDvWorkflowsRequestOpts(requestParameters);
|
|
64
|
+
const response = yield this.request(requestOptions, initOverrides);
|
|
65
|
+
return new runtime.JSONApiResponse(response, (jsonValue) => BulkOperationResponseFromJSON(jsonValue));
|
|
66
|
+
});
|
|
67
|
+
}
|
|
68
|
+
/**
|
|
69
|
+
* Re-run ingestion for the selected document versions, reporting per item. ``not_found``: missing, trashed, never ingested or without its stored source; ``forbidden``: no ``can_write``; ``in_progress_workflow``: still pending/processing; ``already_ingested``: completed; ``unsupported_document_type``: a type that is no longer ingested; ``superseded``: a newer version of the document exists. More than 200 ids is a 400 before any re-run.
|
|
70
|
+
* Bulk Rerun Dv Workflows Handler
|
|
71
|
+
*/
|
|
72
|
+
bulkRerunDvWorkflows(requestParameters, initOverrides) {
|
|
73
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
74
|
+
const response = yield this.bulkRerunDvWorkflowsRaw(requestParameters, initOverrides);
|
|
75
|
+
return yield response.value();
|
|
76
|
+
});
|
|
77
|
+
}
|
|
29
78
|
/**
|
|
30
79
|
* Creates request options for cancelTemporalWorkflow without sending the request
|
|
31
80
|
*/
|
|
@@ -54,7 +103,7 @@ export class SystemJobsApi extends runtime.BaseAPI {
|
|
|
54
103
|
});
|
|
55
104
|
}
|
|
56
105
|
/**
|
|
57
|
-
* Cancel any Temporal workflow owned by the caller\'s tenant. No status guard — this is a thin Temporal wrapper. Cancelling an already-terminal workflow is a no-op on the Temporal side.
|
|
106
|
+
* Cancel any Temporal workflow owned by the caller\'s tenant. No status guard — this is a thin Temporal wrapper. Cancelling an already-terminal workflow is a no-op on the Temporal side. A run no worker ever picked up is terminated instead, since a cancel request is itself a workflow task nobody would process. When Temporal no longer has the run, or it was terminated here, a document version still showing it running is settled as cancelled (needs ``can_write``) so it can be re-run.
|
|
58
107
|
* Cancel Temporal Workflow Handler
|
|
59
108
|
*/
|
|
60
109
|
cancelTemporalWorkflowRaw(requestParameters, initOverrides) {
|
|
@@ -65,7 +114,7 @@ export class SystemJobsApi extends runtime.BaseAPI {
|
|
|
65
114
|
});
|
|
66
115
|
}
|
|
67
116
|
/**
|
|
68
|
-
* Cancel any Temporal workflow owned by the caller\'s tenant. No status guard — this is a thin Temporal wrapper. Cancelling an already-terminal workflow is a no-op on the Temporal side.
|
|
117
|
+
* Cancel any Temporal workflow owned by the caller\'s tenant. No status guard — this is a thin Temporal wrapper. Cancelling an already-terminal workflow is a no-op on the Temporal side. A run no worker ever picked up is terminated instead, since a cancel request is itself a workflow task nobody would process. When Temporal no longer has the run, or it was terminated here, a document version still showing it running is settled as cancelled (needs ``can_write``) so it can be re-run.
|
|
69
118
|
* Cancel Temporal Workflow Handler
|
|
70
119
|
*/
|
|
71
120
|
cancelTemporalWorkflow(requestParameters, initOverrides) {
|
|
@@ -102,7 +151,7 @@ export class SystemJobsApi extends runtime.BaseAPI {
|
|
|
102
151
|
});
|
|
103
152
|
}
|
|
104
153
|
/**
|
|
105
|
-
* Rerun a workflow. USER role requires ``can_write`` on the document path. ``s3_client`` is injected because ``DocumentIngestionService.__init__`` requires it, even though the re-ingestion path reuses the existing S3 source.
|
|
154
|
+
* Rerun a workflow. USER role requires ``can_write`` on the document path. A version that a newer live version supersedes is refused with 409. ``s3_client`` is injected because ``DocumentIngestionService.__init__`` requires it, even though the re-ingestion path reuses the existing S3 source.
|
|
106
155
|
* Dv Workflow Rerun Handler
|
|
107
156
|
*/
|
|
108
157
|
dvWorkflowRerunRaw(requestParameters, initOverrides) {
|
|
@@ -113,7 +162,7 @@ export class SystemJobsApi extends runtime.BaseAPI {
|
|
|
113
162
|
});
|
|
114
163
|
}
|
|
115
164
|
/**
|
|
116
|
-
* Rerun a workflow. USER role requires ``can_write`` on the document path. ``s3_client`` is injected because ``DocumentIngestionService.__init__`` requires it, even though the re-ingestion path reuses the existing S3 source.
|
|
165
|
+
* Rerun a workflow. USER role requires ``can_write`` on the document path. A version that a newer live version supersedes is refused with 409. ``s3_client`` is injected because ``DocumentIngestionService.__init__`` requires it, even though the re-ingestion path reuses the existing S3 source.
|
|
117
166
|
* Dv Workflow Rerun Handler
|
|
118
167
|
*/
|
|
119
168
|
dvWorkflowRerun(requestParameters, initOverrides) {
|
|
@@ -246,7 +295,7 @@ export class SystemJobsApi extends runtime.BaseAPI {
|
|
|
246
295
|
});
|
|
247
296
|
}
|
|
248
297
|
/**
|
|
249
|
-
* Get a ZIP fan-out\'s live status + per-member outcomes. Tenant-scoped via the TenantId search attribute (no per-path can_read check — intentionally consistent with the sibling generic Temporal endpoints below; the opaque workflow_id is only handed to the uploader, who had can_write on the target). The per-member results come from the workflow\'s ``results`` query (served from retained history), so once Temporal retention expires this 404s.
|
|
298
|
+
* Get a ZIP fan-out\'s live status + per-member outcomes. Tenant-scoped via the TenantId search attribute (no per-path can_read check — intentionally consistent with the sibling generic Temporal endpoints below; the opaque workflow_id is only handed to the uploader, who had can_write on the target). The per-member results come from the workflow\'s ``results`` query (served from retained history), so once Temporal retention expires this 404s. Any other workflow type has no ``results`` query and is a 404, not a 500.
|
|
250
299
|
* Get Zip Ingestion Status Handler
|
|
251
300
|
*/
|
|
252
301
|
getZipIngestionStatusRaw(requestParameters, initOverrides) {
|
|
@@ -257,7 +306,7 @@ export class SystemJobsApi extends runtime.BaseAPI {
|
|
|
257
306
|
});
|
|
258
307
|
}
|
|
259
308
|
/**
|
|
260
|
-
* Get a ZIP fan-out\'s live status + per-member outcomes. Tenant-scoped via the TenantId search attribute (no per-path can_read check — intentionally consistent with the sibling generic Temporal endpoints below; the opaque workflow_id is only handed to the uploader, who had can_write on the target). The per-member results come from the workflow\'s ``results`` query (served from retained history), so once Temporal retention expires this 404s.
|
|
309
|
+
* Get a ZIP fan-out\'s live status + per-member outcomes. Tenant-scoped via the TenantId search attribute (no per-path can_read check — intentionally consistent with the sibling generic Temporal endpoints below; the opaque workflow_id is only handed to the uploader, who had can_write on the target). The per-member results come from the workflow\'s ``results`` query (served from retained history), so once Temporal retention expires this 404s. Any other workflow type has no ``results`` query and is a 404, not a 500.
|
|
261
310
|
* Get Zip Ingestion Status Handler
|
|
262
311
|
*/
|
|
263
312
|
getZipIngestionStatus(requestParameters, initOverrides) {
|
|
@@ -266,6 +315,59 @@ export class SystemJobsApi extends runtime.BaseAPI {
|
|
|
266
315
|
return yield response.value();
|
|
267
316
|
});
|
|
268
317
|
}
|
|
318
|
+
/**
|
|
319
|
+
* Creates request options for listDvWorkflowUploaders without sending the request
|
|
320
|
+
*/
|
|
321
|
+
listDvWorkflowUploadersRequestOpts(requestParameters) {
|
|
322
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
323
|
+
const queryParameters = {};
|
|
324
|
+
if (requestParameters['usernameLike'] != null) {
|
|
325
|
+
queryParameters['username_like'] = requestParameters['usernameLike'];
|
|
326
|
+
}
|
|
327
|
+
if (requestParameters['limit'] != null) {
|
|
328
|
+
queryParameters['limit'] = requestParameters['limit'];
|
|
329
|
+
}
|
|
330
|
+
if (requestParameters['offset'] != null) {
|
|
331
|
+
queryParameters['offset'] = requestParameters['offset'];
|
|
332
|
+
}
|
|
333
|
+
const headerParameters = {};
|
|
334
|
+
if (this.configuration && this.configuration.accessToken) {
|
|
335
|
+
const token = this.configuration.accessToken;
|
|
336
|
+
const tokenString = yield token("bearerAuth", []);
|
|
337
|
+
if (tokenString) {
|
|
338
|
+
headerParameters["Authorization"] = `Bearer ${tokenString}`;
|
|
339
|
+
}
|
|
340
|
+
}
|
|
341
|
+
let urlPath = `/v1/system-jobs/document_versions/uploaders`;
|
|
342
|
+
return {
|
|
343
|
+
path: urlPath,
|
|
344
|
+
method: 'GET',
|
|
345
|
+
headers: headerParameters,
|
|
346
|
+
query: queryParameters,
|
|
347
|
+
};
|
|
348
|
+
});
|
|
349
|
+
}
|
|
350
|
+
/**
|
|
351
|
+
* People who uploaded a version the caller can list, for the uploader filter. Scoped like ``list_dv_workflows``: USER only counts versions under readable paths.
|
|
352
|
+
* List Dv Workflow Uploaders Handler
|
|
353
|
+
*/
|
|
354
|
+
listDvWorkflowUploadersRaw(requestParameters, initOverrides) {
|
|
355
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
356
|
+
const requestOptions = yield this.listDvWorkflowUploadersRequestOpts(requestParameters);
|
|
357
|
+
const response = yield this.request(requestOptions, initOverrides);
|
|
358
|
+
return new runtime.JSONApiResponse(response, (jsonValue) => PaginatedResponseUserInfoFromJSON(jsonValue));
|
|
359
|
+
});
|
|
360
|
+
}
|
|
361
|
+
/**
|
|
362
|
+
* People who uploaded a version the caller can list, for the uploader filter. Scoped like ``list_dv_workflows``: USER only counts versions under readable paths.
|
|
363
|
+
* List Dv Workflow Uploaders Handler
|
|
364
|
+
*/
|
|
365
|
+
listDvWorkflowUploaders() {
|
|
366
|
+
return __awaiter(this, arguments, void 0, function* (requestParameters = {}, initOverrides) {
|
|
367
|
+
const response = yield this.listDvWorkflowUploadersRaw(requestParameters, initOverrides);
|
|
368
|
+
return yield response.value();
|
|
369
|
+
});
|
|
370
|
+
}
|
|
269
371
|
/**
|
|
270
372
|
* Creates request options for listDvWorkflows without sending the request
|
|
271
373
|
*/
|
|
@@ -278,6 +380,33 @@ export class SystemJobsApi extends runtime.BaseAPI {
|
|
|
278
380
|
if (requestParameters['offset'] != null) {
|
|
279
381
|
queryParameters['offset'] = requestParameters['offset'];
|
|
280
382
|
}
|
|
383
|
+
if (requestParameters['sortDir'] != null) {
|
|
384
|
+
queryParameters['sort_dir'] = requestParameters['sortDir'];
|
|
385
|
+
}
|
|
386
|
+
if (requestParameters['status'] != null) {
|
|
387
|
+
queryParameters['status'] = requestParameters['status'];
|
|
388
|
+
}
|
|
389
|
+
if (requestParameters['nameLike'] != null) {
|
|
390
|
+
queryParameters['name_like'] = requestParameters['nameLike'];
|
|
391
|
+
}
|
|
392
|
+
if (requestParameters['latestVersionOnly'] != null) {
|
|
393
|
+
queryParameters['latest_version_only'] = requestParameters['latestVersionOnly'];
|
|
394
|
+
}
|
|
395
|
+
if (requestParameters['uploaderUserId'] != null) {
|
|
396
|
+
queryParameters['uploader_user_id'] = requestParameters['uploaderUserId'];
|
|
397
|
+
}
|
|
398
|
+
if (requestParameters['createdAfter'] != null) {
|
|
399
|
+
queryParameters['created_after'] = requestParameters['createdAfter'].toISOString();
|
|
400
|
+
}
|
|
401
|
+
if (requestParameters['createdBefore'] != null) {
|
|
402
|
+
queryParameters['created_before'] = requestParameters['createdBefore'].toISOString();
|
|
403
|
+
}
|
|
404
|
+
if (requestParameters['updatedAfter'] != null) {
|
|
405
|
+
queryParameters['updated_after'] = requestParameters['updatedAfter'].toISOString();
|
|
406
|
+
}
|
|
407
|
+
if (requestParameters['updatedBefore'] != null) {
|
|
408
|
+
queryParameters['updated_before'] = requestParameters['updatedBefore'].toISOString();
|
|
409
|
+
}
|
|
281
410
|
const headerParameters = {};
|
|
282
411
|
if (this.configuration && this.configuration.accessToken) {
|
|
283
412
|
const token = this.configuration.accessToken;
|
|
@@ -296,7 +425,7 @@ export class SystemJobsApi extends runtime.BaseAPI {
|
|
|
296
425
|
});
|
|
297
426
|
}
|
|
298
427
|
/**
|
|
299
|
-
* List
|
|
428
|
+
* List ingestions of live documents in the current tenant, newest upload first. ADMIN/OWNER see every version; USER only versions under readable paths. ``sort_dir=ASC`` lists the oldest upload first.
|
|
300
429
|
* List Dv Workflows Handler
|
|
301
430
|
*/
|
|
302
431
|
listDvWorkflowsRaw(requestParameters, initOverrides) {
|
|
@@ -307,7 +436,7 @@ export class SystemJobsApi extends runtime.BaseAPI {
|
|
|
307
436
|
});
|
|
308
437
|
}
|
|
309
438
|
/**
|
|
310
|
-
* List
|
|
439
|
+
* List ingestions of live documents in the current tenant, newest upload first. ADMIN/OWNER see every version; USER only versions under readable paths. ``sort_dir=ASC`` lists the oldest upload first.
|
|
311
440
|
* List Dv Workflows Handler
|
|
312
441
|
*/
|
|
313
442
|
listDvWorkflows() {
|
|
@@ -28,6 +28,9 @@ export declare const BulkFailureReason: {
|
|
|
28
28
|
readonly NameConflict: 'name_conflict';
|
|
29
29
|
readonly InProgressWorkflow: 'in_progress_workflow';
|
|
30
30
|
readonly PermissionLimit: 'permission_limit';
|
|
31
|
+
readonly AlreadyIngested: 'already_ingested';
|
|
32
|
+
readonly UnsupportedDocumentType: 'unsupported_document_type';
|
|
33
|
+
readonly Superseded: 'superseded';
|
|
31
34
|
};
|
|
32
35
|
export type BulkFailureReason = typeof BulkFailureReason[keyof typeof BulkFailureReason];
|
|
33
36
|
export declare function instanceOfBulkFailureReason(value: any): boolean;
|
|
@@ -29,7 +29,10 @@ export const BulkFailureReason = {
|
|
|
29
29
|
CheckedOut: 'checked_out',
|
|
30
30
|
NameConflict: 'name_conflict',
|
|
31
31
|
InProgressWorkflow: 'in_progress_workflow',
|
|
32
|
-
PermissionLimit: 'permission_limit'
|
|
32
|
+
PermissionLimit: 'permission_limit',
|
|
33
|
+
AlreadyIngested: 'already_ingested',
|
|
34
|
+
UnsupportedDocumentType: 'unsupported_document_type',
|
|
35
|
+
Superseded: 'superseded'
|
|
33
36
|
};
|
|
34
37
|
export function instanceOfBulkFailureReason(value) {
|
|
35
38
|
for (const key in BulkFailureReason) {
|
|
@@ -0,0 +1,47 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Knowledge Stack API
|
|
3
|
+
* Knowledge Stack backend API for authentication and knowledge management. ## Integrating (RPA / machine clients) **Base URL.** Knowledge Stack is self-hosted — point at your own deployment host (see `servers`). The `localhost` entry is for local development only. **Authentication.** Send `Authorization: Bearer <api-key>` on every request. Mint an API key once via `POST /v1/api-keys` from a signed-in browser session; the raw `sk-user-...` secret is returned **only** at creation, so store it then. A key inherits its owning user\'s live tenant role and path permissions — create RPA keys from a least-privilege user, and set `expires_at` for rotation. The `ks_uat` cookie scheme is browser-only and cannot be used by headless clients. **Async work is polled, not pushed.** There are no outbound webhooks. - `POST /v1/documents/ingest` returns `201` immediately with a `workflow_id`; poll `GET /v1/system-jobs/document_versions/{workflow_id}` until `status` is terminal (anything other than `pending`/`processing`). The `Location` response header points at this poll resource. - `POST /v1/workflow-runs/{run_id}/start` returns `202`; poll `GET /v1/workflow-runs/{run_id}` until `execution_state` is `COMPLETED` or `FAILED`. The `Location` header points at the run resource. - `POST /v1/agent/ask` is **synchronous** — it blocks until the agent finishes and returns the answer inline. Use a generous HTTP timeout. **Pagination.** List endpoints accept `limit`/`offset` and return `{items, total, limit, offset}`. **Errors.** Every non-2xx body is `{detail, code, request_id}`. `code` is a stable value from a closed set (see the `ErrorResponse` schema\'s `code` enum) — branch on it rather than parsing `detail`. Quota rejections return `429` with a `Retry-After` header; transient lock contention returns a retryable `503`. Quote `request_id` (also the `x-request-id` response header) to support. **Idempotency.** `POST /v1/workflow-runs` accepts an `idempotency_key` to dedupe retried run creation. `agent/ask` charges one message *before* running and does not refund a client-cancelled call.
|
|
4
|
+
*
|
|
5
|
+
* The version of the OpenAPI document: 0.1.0
|
|
6
|
+
*
|
|
7
|
+
*
|
|
8
|
+
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
9
|
+
* https://openapi-generator.tech
|
|
10
|
+
* Do not edit the class manually.
|
|
11
|
+
*/
|
|
12
|
+
/**
|
|
13
|
+
* Re-run ingestion for the selected document versions.
|
|
14
|
+
* @export
|
|
15
|
+
* @interface BulkRerunRequest
|
|
16
|
+
*/
|
|
17
|
+
export interface BulkRerunRequest {
|
|
18
|
+
/**
|
|
19
|
+
*
|
|
20
|
+
* @type {Array<string>}
|
|
21
|
+
* @memberof BulkRerunRequest
|
|
22
|
+
*/
|
|
23
|
+
documentVersionIds?: Array<string>;
|
|
24
|
+
}
|
|
25
|
+
export declare const BulkRerunRequestPropertyValidationAttributesMap: {
|
|
26
|
+
[property: string]: {
|
|
27
|
+
maxLength?: number;
|
|
28
|
+
minLength?: number;
|
|
29
|
+
pattern?: string;
|
|
30
|
+
maximum?: number;
|
|
31
|
+
exclusiveMaximum?: boolean;
|
|
32
|
+
minimum?: number;
|
|
33
|
+
exclusiveMinimum?: boolean;
|
|
34
|
+
multipleOf?: number;
|
|
35
|
+
maxItems?: number;
|
|
36
|
+
minItems?: number;
|
|
37
|
+
uniqueItems?: boolean;
|
|
38
|
+
};
|
|
39
|
+
};
|
|
40
|
+
/**
|
|
41
|
+
* Check if a given object implements the BulkRerunRequest interface.
|
|
42
|
+
*/
|
|
43
|
+
export declare function instanceOfBulkRerunRequest(value: object): value is BulkRerunRequest;
|
|
44
|
+
export declare function BulkRerunRequestFromJSON(json: any): BulkRerunRequest;
|
|
45
|
+
export declare function BulkRerunRequestFromJSONTyped(json: any, ignoreDiscriminator: boolean): BulkRerunRequest;
|
|
46
|
+
export declare function BulkRerunRequestToJSON(json: any): BulkRerunRequest;
|
|
47
|
+
export declare function BulkRerunRequestToJSONTyped(value?: BulkRerunRequest | null, ignoreDiscriminator?: boolean): any;
|
|
@@ -0,0 +1,42 @@
|
|
|
1
|
+
/* tslint:disable */
|
|
2
|
+
/* eslint-disable */
|
|
3
|
+
/**
|
|
4
|
+
* Knowledge Stack API
|
|
5
|
+
* Knowledge Stack backend API for authentication and knowledge management. ## Integrating (RPA / machine clients) **Base URL.** Knowledge Stack is self-hosted — point at your own deployment host (see `servers`). The `localhost` entry is for local development only. **Authentication.** Send `Authorization: Bearer <api-key>` on every request. Mint an API key once via `POST /v1/api-keys` from a signed-in browser session; the raw `sk-user-...` secret is returned **only** at creation, so store it then. A key inherits its owning user\'s live tenant role and path permissions — create RPA keys from a least-privilege user, and set `expires_at` for rotation. The `ks_uat` cookie scheme is browser-only and cannot be used by headless clients. **Async work is polled, not pushed.** There are no outbound webhooks. - `POST /v1/documents/ingest` returns `201` immediately with a `workflow_id`; poll `GET /v1/system-jobs/document_versions/{workflow_id}` until `status` is terminal (anything other than `pending`/`processing`). The `Location` response header points at this poll resource. - `POST /v1/workflow-runs/{run_id}/start` returns `202`; poll `GET /v1/workflow-runs/{run_id}` until `execution_state` is `COMPLETED` or `FAILED`. The `Location` header points at the run resource. - `POST /v1/agent/ask` is **synchronous** — it blocks until the agent finishes and returns the answer inline. Use a generous HTTP timeout. **Pagination.** List endpoints accept `limit`/`offset` and return `{items, total, limit, offset}`. **Errors.** Every non-2xx body is `{detail, code, request_id}`. `code` is a stable value from a closed set (see the `ErrorResponse` schema\'s `code` enum) — branch on it rather than parsing `detail`. Quota rejections return `429` with a `Retry-After` header; transient lock contention returns a retryable `503`. Quote `request_id` (also the `x-request-id` response header) to support. **Idempotency.** `POST /v1/workflow-runs` accepts an `idempotency_key` to dedupe retried run creation. `agent/ask` charges one message *before* running and does not refund a client-cancelled call.
|
|
6
|
+
*
|
|
7
|
+
* The version of the OpenAPI document: 0.1.0
|
|
8
|
+
*
|
|
9
|
+
*
|
|
10
|
+
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
11
|
+
* https://openapi-generator.tech
|
|
12
|
+
* Do not edit the class manually.
|
|
13
|
+
*/
|
|
14
|
+
export const BulkRerunRequestPropertyValidationAttributesMap = {};
|
|
15
|
+
/**
|
|
16
|
+
* Check if a given object implements the BulkRerunRequest interface.
|
|
17
|
+
*/
|
|
18
|
+
export function instanceOfBulkRerunRequest(value) {
|
|
19
|
+
return true;
|
|
20
|
+
}
|
|
21
|
+
export function BulkRerunRequestFromJSON(json) {
|
|
22
|
+
return BulkRerunRequestFromJSONTyped(json, false);
|
|
23
|
+
}
|
|
24
|
+
export function BulkRerunRequestFromJSONTyped(json, ignoreDiscriminator) {
|
|
25
|
+
if (json == null) {
|
|
26
|
+
return json;
|
|
27
|
+
}
|
|
28
|
+
return {
|
|
29
|
+
'documentVersionIds': json['document_version_ids'] == null ? undefined : json['document_version_ids'],
|
|
30
|
+
};
|
|
31
|
+
}
|
|
32
|
+
export function BulkRerunRequestToJSON(json) {
|
|
33
|
+
return BulkRerunRequestToJSONTyped(json, false);
|
|
34
|
+
}
|
|
35
|
+
export function BulkRerunRequestToJSONTyped(value, ignoreDiscriminator = false) {
|
|
36
|
+
if (value == null) {
|
|
37
|
+
return value;
|
|
38
|
+
}
|
|
39
|
+
return {
|
|
40
|
+
'document_version_ids': value['documentVersionIds'],
|
|
41
|
+
};
|
|
42
|
+
}
|