@knowledge-stack/ksapi 1.18.0 → 1.18.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/README.md +2 -2
- package/dist/apis/DocumentsApi.d.ts +10 -10
- package/dist/apis/DocumentsApi.js +6 -6
- package/dist/apis/FoldersApi.d.ts +10 -10
- package/dist/apis/FoldersApi.js +6 -6
- package/dist/apis/PathPartsApi.d.ts +6 -6
- package/dist/apis/PathPartsApi.js +4 -4
- package/dist/esm/apis/DocumentsApi.d.ts +10 -10
- package/dist/esm/apis/DocumentsApi.js +6 -6
- package/dist/esm/apis/FoldersApi.d.ts +10 -10
- package/dist/esm/apis/FoldersApi.js +6 -6
- package/dist/esm/apis/PathPartsApi.d.ts +6 -6
- package/dist/esm/apis/PathPartsApi.js +4 -4
- package/dist/esm/models/ChunkResponse.d.ts +2 -2
- package/dist/esm/models/ChunkResponse.js +5 -5
- package/dist/esm/models/CreateDocumentRequest.d.ts +2 -2
- package/dist/esm/models/CreateDocumentRequest.js +3 -3
- package/dist/esm/models/CreateFolderRequest.d.ts +2 -2
- package/dist/esm/models/CreateFolderRequest.js +3 -3
- package/dist/esm/models/DocumentContentPathPart.d.ts +1 -1
- package/dist/esm/models/DocumentContentPathPart.js +3 -3
- package/dist/esm/models/DocumentResponse.d.ts +2 -2
- package/dist/esm/models/DocumentResponse.js +3 -3
- package/dist/esm/models/DocumentVersionResponse.d.ts +1 -1
- package/dist/esm/models/DocumentVersionResponse.js +3 -3
- package/dist/esm/models/FolderDocumentResponse.d.ts +2 -2
- package/dist/esm/models/FolderDocumentResponse.js +3 -3
- package/dist/esm/models/FolderResponse.d.ts +2 -2
- package/dist/esm/models/FolderResponse.js +3 -3
- package/dist/esm/models/PathPartResponse.d.ts +1 -1
- package/dist/esm/models/PathPartResponse.js +3 -3
- package/dist/esm/models/ScoredChunkResponse.d.ts +2 -2
- package/dist/esm/models/ScoredChunkResponse.js +5 -5
- package/dist/esm/models/SectionResponse.d.ts +2 -2
- package/dist/esm/models/SectionResponse.js +5 -5
- package/dist/esm/models/ThreadMessageResponse.d.ts +1 -1
- package/dist/esm/models/ThreadMessageResponse.js +3 -3
- package/dist/esm/models/UpdateDocumentRequest.d.ts +2 -2
- package/dist/esm/models/UpdateDocumentRequest.js +2 -2
- package/dist/esm/models/UpdateFolderRequest.d.ts +2 -2
- package/dist/esm/models/UpdateFolderRequest.js +2 -2
- package/dist/models/ChunkResponse.d.ts +2 -2
- package/dist/models/ChunkResponse.js +5 -5
- package/dist/models/CreateDocumentRequest.d.ts +2 -2
- package/dist/models/CreateDocumentRequest.js +3 -3
- package/dist/models/CreateFolderRequest.d.ts +2 -2
- package/dist/models/CreateFolderRequest.js +3 -3
- package/dist/models/DocumentContentPathPart.d.ts +1 -1
- package/dist/models/DocumentContentPathPart.js +3 -3
- package/dist/models/DocumentResponse.d.ts +2 -2
- package/dist/models/DocumentResponse.js +3 -3
- package/dist/models/DocumentVersionResponse.d.ts +1 -1
- package/dist/models/DocumentVersionResponse.js +3 -3
- package/dist/models/FolderDocumentResponse.d.ts +2 -2
- package/dist/models/FolderDocumentResponse.js +3 -3
- package/dist/models/FolderResponse.d.ts +2 -2
- package/dist/models/FolderResponse.js +3 -3
- package/dist/models/PathPartResponse.d.ts +1 -1
- package/dist/models/PathPartResponse.js +3 -3
- package/dist/models/ScoredChunkResponse.d.ts +2 -2
- package/dist/models/ScoredChunkResponse.js +5 -5
- package/dist/models/SectionResponse.d.ts +2 -2
- package/dist/models/SectionResponse.js +5 -5
- package/dist/models/ThreadMessageResponse.d.ts +1 -1
- package/dist/models/ThreadMessageResponse.js +3 -3
- package/dist/models/UpdateDocumentRequest.d.ts +2 -2
- package/dist/models/UpdateDocumentRequest.js +2 -2
- package/dist/models/UpdateFolderRequest.d.ts +2 -2
- package/dist/models/UpdateFolderRequest.js +2 -2
- package/package.json +1 -1
- package/src/apis/DocumentsApi.ts +12 -12
- package/src/apis/FoldersApi.ts +12 -12
- package/src/apis/PathPartsApi.ts +8 -8
- package/src/models/ChunkResponse.ts +7 -7
- package/src/models/CreateDocumentRequest.ts +5 -5
- package/src/models/CreateFolderRequest.ts +5 -5
- package/src/models/DocumentContentPathPart.ts +4 -4
- package/src/models/DocumentResponse.ts +5 -5
- package/src/models/DocumentVersionResponse.ts +4 -4
- package/src/models/FolderDocumentResponse.ts +5 -5
- package/src/models/FolderResponse.ts +5 -5
- package/src/models/PathPartResponse.ts +4 -4
- package/src/models/ScoredChunkResponse.ts +7 -7
- package/src/models/SectionResponse.ts +7 -7
- package/src/models/ThreadMessageResponse.ts +4 -4
- package/src/models/UpdateDocumentRequest.ts +4 -4
- package/src/models/UpdateFolderRequest.ts +4 -4
|
@@ -34,7 +34,7 @@ function UpdateFolderRequestFromJSONTyped(json, ignoreDiscriminator) {
|
|
|
34
34
|
}
|
|
35
35
|
return {
|
|
36
36
|
'name': json['name'] == null ? undefined : json['name'],
|
|
37
|
-
'
|
|
37
|
+
'parentPathPartId': json['parent_path_part_id'] == null ? undefined : json['parent_path_part_id'],
|
|
38
38
|
};
|
|
39
39
|
}
|
|
40
40
|
function UpdateFolderRequestToJSON(json) {
|
|
@@ -46,7 +46,7 @@ function UpdateFolderRequestToJSONTyped(value, ignoreDiscriminator = false) {
|
|
|
46
46
|
}
|
|
47
47
|
return {
|
|
48
48
|
'name': value['name'],
|
|
49
|
-
'
|
|
49
|
+
'parent_path_part_id': value['parentPathPartId'],
|
|
50
50
|
};
|
|
51
51
|
}
|
|
52
52
|
exports.UpdateFolderRequestPropertyValidationAttributesMap = {
|
package/package.json
CHANGED
package/src/apis/DocumentsApi.ts
CHANGED
|
@@ -63,7 +63,7 @@ export interface IngestDocumentRequest {
|
|
|
63
63
|
}
|
|
64
64
|
|
|
65
65
|
export interface ListDocumentsRequest {
|
|
66
|
-
|
|
66
|
+
parentPathPartId?: string;
|
|
67
67
|
sortOrder?: PathOrder;
|
|
68
68
|
limit?: number;
|
|
69
69
|
offset?: number;
|
|
@@ -154,9 +154,9 @@ export interface DocumentsApiInterface {
|
|
|
154
154
|
ingestDocument(requestParameters: IngestDocumentRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<IngestDocumentResponse>;
|
|
155
155
|
|
|
156
156
|
/**
|
|
157
|
-
* List documents in a folder. Returns only direct child documents (depth=1) of the specified parent folder. If
|
|
157
|
+
* List documents in a folder. Returns only direct child documents (depth=1) of the specified parent folder. If parent_path_part_id is not provided, lists documents in the root folder.
|
|
158
158
|
* @summary List Documents Handler
|
|
159
|
-
* @param {string} [
|
|
159
|
+
* @param {string} [parentPathPartId] Parent PathPart ID (defaults to root)
|
|
160
160
|
* @param {PathOrder} [sortOrder] Sort order for results (default: LOGICAL)
|
|
161
161
|
* @param {number} [limit] Number of items per page
|
|
162
162
|
* @param {number} [offset] Number of items to skip
|
|
@@ -168,13 +168,13 @@ export interface DocumentsApiInterface {
|
|
|
168
168
|
listDocumentsRaw(requestParameters: ListDocumentsRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<PaginatedResponseDocumentResponse>>;
|
|
169
169
|
|
|
170
170
|
/**
|
|
171
|
-
* List documents in a folder. Returns only direct child documents (depth=1) of the specified parent folder. If
|
|
171
|
+
* List documents in a folder. Returns only direct child documents (depth=1) of the specified parent folder. If parent_path_part_id is not provided, lists documents in the root folder.
|
|
172
172
|
* List Documents Handler
|
|
173
173
|
*/
|
|
174
174
|
listDocuments(requestParameters: ListDocumentsRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<PaginatedResponseDocumentResponse>;
|
|
175
175
|
|
|
176
176
|
/**
|
|
177
|
-
* Update a document (rename, move, and/or change active version). To rename: provide `name` field. To move: provide `
|
|
177
|
+
* Update a document (rename, move, and/or change active version). To rename: provide `name` field. To move: provide `parent_path_part_id` field. To change active version: provide `active_version_id` field. All can be done in a single request.
|
|
178
178
|
* @summary Update Document Handler
|
|
179
179
|
* @param {string} documentId
|
|
180
180
|
* @param {UpdateDocumentRequest} updateDocumentRequest
|
|
@@ -186,7 +186,7 @@ export interface DocumentsApiInterface {
|
|
|
186
186
|
updateDocumentRaw(requestParameters: UpdateDocumentOperationRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<DocumentResponse>>;
|
|
187
187
|
|
|
188
188
|
/**
|
|
189
|
-
* Update a document (rename, move, and/or change active version). To rename: provide `name` field. To move: provide `
|
|
189
|
+
* Update a document (rename, move, and/or change active version). To rename: provide `name` field. To move: provide `parent_path_part_id` field. To change active version: provide `active_version_id` field. All can be done in a single request.
|
|
190
190
|
* Update Document Handler
|
|
191
191
|
*/
|
|
192
192
|
updateDocument(requestParameters: UpdateDocumentOperationRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<DocumentResponse>;
|
|
@@ -391,14 +391,14 @@ export class DocumentsApi extends runtime.BaseAPI implements DocumentsApiInterfa
|
|
|
391
391
|
}
|
|
392
392
|
|
|
393
393
|
/**
|
|
394
|
-
* List documents in a folder. Returns only direct child documents (depth=1) of the specified parent folder. If
|
|
394
|
+
* List documents in a folder. Returns only direct child documents (depth=1) of the specified parent folder. If parent_path_part_id is not provided, lists documents in the root folder.
|
|
395
395
|
* List Documents Handler
|
|
396
396
|
*/
|
|
397
397
|
async listDocumentsRaw(requestParameters: ListDocumentsRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<PaginatedResponseDocumentResponse>> {
|
|
398
398
|
const queryParameters: any = {};
|
|
399
399
|
|
|
400
|
-
if (requestParameters['
|
|
401
|
-
queryParameters['
|
|
400
|
+
if (requestParameters['parentPathPartId'] != null) {
|
|
401
|
+
queryParameters['parent_path_part_id'] = requestParameters['parentPathPartId'];
|
|
402
402
|
}
|
|
403
403
|
|
|
404
404
|
if (requestParameters['sortOrder'] != null) {
|
|
@@ -429,7 +429,7 @@ export class DocumentsApi extends runtime.BaseAPI implements DocumentsApiInterfa
|
|
|
429
429
|
}
|
|
430
430
|
|
|
431
431
|
/**
|
|
432
|
-
* List documents in a folder. Returns only direct child documents (depth=1) of the specified parent folder. If
|
|
432
|
+
* List documents in a folder. Returns only direct child documents (depth=1) of the specified parent folder. If parent_path_part_id is not provided, lists documents in the root folder.
|
|
433
433
|
* List Documents Handler
|
|
434
434
|
*/
|
|
435
435
|
async listDocuments(requestParameters: ListDocumentsRequest = {}, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<PaginatedResponseDocumentResponse> {
|
|
@@ -438,7 +438,7 @@ export class DocumentsApi extends runtime.BaseAPI implements DocumentsApiInterfa
|
|
|
438
438
|
}
|
|
439
439
|
|
|
440
440
|
/**
|
|
441
|
-
* Update a document (rename, move, and/or change active version). To rename: provide `name` field. To move: provide `
|
|
441
|
+
* Update a document (rename, move, and/or change active version). To rename: provide `name` field. To move: provide `parent_path_part_id` field. To change active version: provide `active_version_id` field. All can be done in a single request.
|
|
442
442
|
* Update Document Handler
|
|
443
443
|
*/
|
|
444
444
|
async updateDocumentRaw(requestParameters: UpdateDocumentOperationRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<DocumentResponse>> {
|
|
@@ -478,7 +478,7 @@ export class DocumentsApi extends runtime.BaseAPI implements DocumentsApiInterfa
|
|
|
478
478
|
}
|
|
479
479
|
|
|
480
480
|
/**
|
|
481
|
-
* Update a document (rename, move, and/or change active version). To rename: provide `name` field. To move: provide `
|
|
481
|
+
* Update a document (rename, move, and/or change active version). To rename: provide `name` field. To move: provide `parent_path_part_id` field. To change active version: provide `active_version_id` field. All can be done in a single request.
|
|
482
482
|
* Update Document Handler
|
|
483
483
|
*/
|
|
484
484
|
async updateDocument(requestParameters: UpdateDocumentOperationRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<DocumentResponse> {
|
package/src/apis/FoldersApi.ts
CHANGED
|
@@ -65,7 +65,7 @@ export interface ListFolderContentsRequest {
|
|
|
65
65
|
}
|
|
66
66
|
|
|
67
67
|
export interface ListFoldersRequest {
|
|
68
|
-
|
|
68
|
+
parentPathPartId?: string;
|
|
69
69
|
sortOrder?: PathOrder;
|
|
70
70
|
limit?: number;
|
|
71
71
|
offset?: number;
|
|
@@ -158,9 +158,9 @@ export interface FoldersApiInterface {
|
|
|
158
158
|
listFolderContents(requestParameters: ListFolderContentsRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<PaginatedResponseFolderDocumentResponse>;
|
|
159
159
|
|
|
160
160
|
/**
|
|
161
|
-
* List child folders of a parent folder. Returns only direct child folders (depth=1) of the specified parent. If
|
|
161
|
+
* List child folders of a parent folder. Returns only direct child folders (depth=1) of the specified parent. If parent_path_part_id is not provided, lists folders in the root folder.
|
|
162
162
|
* @summary List Folders Handler
|
|
163
|
-
* @param {string} [
|
|
163
|
+
* @param {string} [parentPathPartId] Parent PathPart ID (defaults to root)
|
|
164
164
|
* @param {PathOrder} [sortOrder] Sort order for results (default: LOGICAL)
|
|
165
165
|
* @param {number} [limit] Number of items per page
|
|
166
166
|
* @param {number} [offset] Number of items to skip
|
|
@@ -172,13 +172,13 @@ export interface FoldersApiInterface {
|
|
|
172
172
|
listFoldersRaw(requestParameters: ListFoldersRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<PaginatedResponseFolderResponse>>;
|
|
173
173
|
|
|
174
174
|
/**
|
|
175
|
-
* List child folders of a parent folder. Returns only direct child folders (depth=1) of the specified parent. If
|
|
175
|
+
* List child folders of a parent folder. Returns only direct child folders (depth=1) of the specified parent. If parent_path_part_id is not provided, lists folders in the root folder.
|
|
176
176
|
* List Folders Handler
|
|
177
177
|
*/
|
|
178
178
|
listFolders(requestParameters: ListFoldersRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<PaginatedResponseFolderResponse>;
|
|
179
179
|
|
|
180
180
|
/**
|
|
181
|
-
* Update a folder (rename and/or move). To rename: provide `name` field. To move: provide `
|
|
181
|
+
* Update a folder (rename and/or move). To rename: provide `name` field. To move: provide `parent_path_part_id` field. Both can be done in a single request.
|
|
182
182
|
* @summary Update Folder Handler
|
|
183
183
|
* @param {string} folderId
|
|
184
184
|
* @param {UpdateFolderRequest} updateFolderRequest
|
|
@@ -190,7 +190,7 @@ export interface FoldersApiInterface {
|
|
|
190
190
|
updateFolderRaw(requestParameters: UpdateFolderOperationRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<FolderResponse>>;
|
|
191
191
|
|
|
192
192
|
/**
|
|
193
|
-
* Update a folder (rename and/or move). To rename: provide `name` field. To move: provide `
|
|
193
|
+
* Update a folder (rename and/or move). To rename: provide `name` field. To move: provide `parent_path_part_id` field. Both can be done in a single request.
|
|
194
194
|
* Update Folder Handler
|
|
195
195
|
*/
|
|
196
196
|
updateFolder(requestParameters: UpdateFolderOperationRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<FolderResponse>;
|
|
@@ -376,14 +376,14 @@ export class FoldersApi extends runtime.BaseAPI implements FoldersApiInterface {
|
|
|
376
376
|
}
|
|
377
377
|
|
|
378
378
|
/**
|
|
379
|
-
* List child folders of a parent folder. Returns only direct child folders (depth=1) of the specified parent. If
|
|
379
|
+
* List child folders of a parent folder. Returns only direct child folders (depth=1) of the specified parent. If parent_path_part_id is not provided, lists folders in the root folder.
|
|
380
380
|
* List Folders Handler
|
|
381
381
|
*/
|
|
382
382
|
async listFoldersRaw(requestParameters: ListFoldersRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<PaginatedResponseFolderResponse>> {
|
|
383
383
|
const queryParameters: any = {};
|
|
384
384
|
|
|
385
|
-
if (requestParameters['
|
|
386
|
-
queryParameters['
|
|
385
|
+
if (requestParameters['parentPathPartId'] != null) {
|
|
386
|
+
queryParameters['parent_path_part_id'] = requestParameters['parentPathPartId'];
|
|
387
387
|
}
|
|
388
388
|
|
|
389
389
|
if (requestParameters['sortOrder'] != null) {
|
|
@@ -414,7 +414,7 @@ export class FoldersApi extends runtime.BaseAPI implements FoldersApiInterface {
|
|
|
414
414
|
}
|
|
415
415
|
|
|
416
416
|
/**
|
|
417
|
-
* List child folders of a parent folder. Returns only direct child folders (depth=1) of the specified parent. If
|
|
417
|
+
* List child folders of a parent folder. Returns only direct child folders (depth=1) of the specified parent. If parent_path_part_id is not provided, lists folders in the root folder.
|
|
418
418
|
* List Folders Handler
|
|
419
419
|
*/
|
|
420
420
|
async listFolders(requestParameters: ListFoldersRequest = {}, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<PaginatedResponseFolderResponse> {
|
|
@@ -423,7 +423,7 @@ export class FoldersApi extends runtime.BaseAPI implements FoldersApiInterface {
|
|
|
423
423
|
}
|
|
424
424
|
|
|
425
425
|
/**
|
|
426
|
-
* Update a folder (rename and/or move). To rename: provide `name` field. To move: provide `
|
|
426
|
+
* Update a folder (rename and/or move). To rename: provide `name` field. To move: provide `parent_path_part_id` field. Both can be done in a single request.
|
|
427
427
|
* Update Folder Handler
|
|
428
428
|
*/
|
|
429
429
|
async updateFolderRaw(requestParameters: UpdateFolderOperationRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<FolderResponse>> {
|
|
@@ -463,7 +463,7 @@ export class FoldersApi extends runtime.BaseAPI implements FoldersApiInterface {
|
|
|
463
463
|
}
|
|
464
464
|
|
|
465
465
|
/**
|
|
466
|
-
* Update a folder (rename and/or move). To rename: provide `name` field. To move: provide `
|
|
466
|
+
* Update a folder (rename and/or move). To rename: provide `name` field. To move: provide `parent_path_part_id` field. Both can be done in a single request.
|
|
467
467
|
* Update Folder Handler
|
|
468
468
|
*/
|
|
469
469
|
async updateFolder(requestParameters: UpdateFolderOperationRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<FolderResponse> {
|
package/src/apis/PathPartsApi.ts
CHANGED
|
@@ -37,7 +37,7 @@ export interface GetPathPartRequest {
|
|
|
37
37
|
}
|
|
38
38
|
|
|
39
39
|
export interface ListPathPartsRequest {
|
|
40
|
-
|
|
40
|
+
parentPathId?: string;
|
|
41
41
|
maxDepth?: number;
|
|
42
42
|
sortOrder?: PathOrder;
|
|
43
43
|
limit?: number;
|
|
@@ -70,9 +70,9 @@ export interface PathPartsApiInterface {
|
|
|
70
70
|
getPathPart(requestParameters: GetPathPartRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<PathPartResponse>;
|
|
71
71
|
|
|
72
72
|
/**
|
|
73
|
-
* List path parts (folders) under a parent with traversal. This is a generic endpoint for traversing the folder hierarchy. It returns only FOLDER type path parts. - If
|
|
73
|
+
* List path parts (folders) under a parent with traversal. This is a generic endpoint for traversing the folder hierarchy. It returns only FOLDER type path parts. - If parent_path_id is not provided, lists contents of the root folder. - max_depth controls how deep to traverse (1 = direct children only). - sort_order controls the ordering: LOGICAL (linked-list), NAME, UPDATED_AT, CREATED_AT. For listing folder contents that includes documents with enriched metadata, use GET /folders/{folder_id}/contents instead.
|
|
74
74
|
* @summary List Path Parts Handler
|
|
75
|
-
* @param {string} [
|
|
75
|
+
* @param {string} [parentPathId] Parent PathPart ID (defaults to root)
|
|
76
76
|
* @param {number} [maxDepth] Maximum depth to traverse (1 = direct children, default: 1)
|
|
77
77
|
* @param {PathOrder} [sortOrder] Sort order for results (default: LOGICAL)
|
|
78
78
|
* @param {number} [limit] Number of items per page
|
|
@@ -85,7 +85,7 @@ export interface PathPartsApiInterface {
|
|
|
85
85
|
listPathPartsRaw(requestParameters: ListPathPartsRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<PaginatedResponsePathPartResponse>>;
|
|
86
86
|
|
|
87
87
|
/**
|
|
88
|
-
* List path parts (folders) under a parent with traversal. This is a generic endpoint for traversing the folder hierarchy. It returns only FOLDER type path parts. - If
|
|
88
|
+
* List path parts (folders) under a parent with traversal. This is a generic endpoint for traversing the folder hierarchy. It returns only FOLDER type path parts. - If parent_path_id is not provided, lists contents of the root folder. - max_depth controls how deep to traverse (1 = direct children only). - sort_order controls the ordering: LOGICAL (linked-list), NAME, UPDATED_AT, CREATED_AT. For listing folder contents that includes documents with enriched metadata, use GET /folders/{folder_id}/contents instead.
|
|
89
89
|
* List Path Parts Handler
|
|
90
90
|
*/
|
|
91
91
|
listPathParts(requestParameters: ListPathPartsRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<PaginatedResponsePathPartResponse>;
|
|
@@ -137,14 +137,14 @@ export class PathPartsApi extends runtime.BaseAPI implements PathPartsApiInterfa
|
|
|
137
137
|
}
|
|
138
138
|
|
|
139
139
|
/**
|
|
140
|
-
* List path parts (folders) under a parent with traversal. This is a generic endpoint for traversing the folder hierarchy. It returns only FOLDER type path parts. - If
|
|
140
|
+
* List path parts (folders) under a parent with traversal. This is a generic endpoint for traversing the folder hierarchy. It returns only FOLDER type path parts. - If parent_path_id is not provided, lists contents of the root folder. - max_depth controls how deep to traverse (1 = direct children only). - sort_order controls the ordering: LOGICAL (linked-list), NAME, UPDATED_AT, CREATED_AT. For listing folder contents that includes documents with enriched metadata, use GET /folders/{folder_id}/contents instead.
|
|
141
141
|
* List Path Parts Handler
|
|
142
142
|
*/
|
|
143
143
|
async listPathPartsRaw(requestParameters: ListPathPartsRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<PaginatedResponsePathPartResponse>> {
|
|
144
144
|
const queryParameters: any = {};
|
|
145
145
|
|
|
146
|
-
if (requestParameters['
|
|
147
|
-
queryParameters['
|
|
146
|
+
if (requestParameters['parentPathId'] != null) {
|
|
147
|
+
queryParameters['parent_path_id'] = requestParameters['parentPathId'];
|
|
148
148
|
}
|
|
149
149
|
|
|
150
150
|
if (requestParameters['maxDepth'] != null) {
|
|
@@ -179,7 +179,7 @@ export class PathPartsApi extends runtime.BaseAPI implements PathPartsApiInterfa
|
|
|
179
179
|
}
|
|
180
180
|
|
|
181
181
|
/**
|
|
182
|
-
* List path parts (folders) under a parent with traversal. This is a generic endpoint for traversing the folder hierarchy. It returns only FOLDER type path parts. - If
|
|
182
|
+
* List path parts (folders) under a parent with traversal. This is a generic endpoint for traversing the folder hierarchy. It returns only FOLDER type path parts. - If parent_path_id is not provided, lists contents of the root folder. - max_depth controls how deep to traverse (1 = direct children only). - sort_order controls the ordering: LOGICAL (linked-list), NAME, UPDATED_AT, CREATED_AT. For listing folder contents that includes documents with enriched metadata, use GET /folders/{folder_id}/contents instead.
|
|
183
183
|
* List Path Parts Handler
|
|
184
184
|
*/
|
|
185
185
|
async listPathParts(requestParameters: ListPathPartsRequest = {}, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<PaginatedResponsePathPartResponse> {
|
|
@@ -75,7 +75,7 @@ export interface ChunkResponse {
|
|
|
75
75
|
* @type {string}
|
|
76
76
|
* @memberof ChunkResponse
|
|
77
77
|
*/
|
|
78
|
-
|
|
78
|
+
parentPathId: string;
|
|
79
79
|
/**
|
|
80
80
|
* Previous sibling PathPart ID
|
|
81
81
|
* @type {string}
|
|
@@ -87,7 +87,7 @@ export interface ChunkResponse {
|
|
|
87
87
|
* @type {string}
|
|
88
88
|
* @memberof ChunkResponse
|
|
89
89
|
*/
|
|
90
|
-
|
|
90
|
+
nextSiblingPathId?: string;
|
|
91
91
|
/**
|
|
92
92
|
* Full materialized path from root
|
|
93
93
|
* @type {string}
|
|
@@ -126,7 +126,7 @@ export function instanceOfChunkResponse(value: object): value is ChunkResponse {
|
|
|
126
126
|
if (!('content' in value) || value['content'] === undefined) return false;
|
|
127
127
|
if (!('chunkType' in value) || value['chunkType'] === undefined) return false;
|
|
128
128
|
if (!('chunkMetadata' in value) || value['chunkMetadata'] === undefined) return false;
|
|
129
|
-
if (!('
|
|
129
|
+
if (!('parentPathId' in value) || value['parentPathId'] === undefined) return false;
|
|
130
130
|
if (!('materializedPath' in value) || value['materializedPath'] === undefined) return false;
|
|
131
131
|
if (!('tenantId' in value) || value['tenantId'] === undefined) return false;
|
|
132
132
|
if (!('createdAt' in value) || value['createdAt'] === undefined) return false;
|
|
@@ -150,9 +150,9 @@ export function ChunkResponseFromJSONTyped(json: any, ignoreDiscriminator: boole
|
|
|
150
150
|
'content': json['content'],
|
|
151
151
|
'chunkType': ChunkTypeFromJSON(json['chunk_type']),
|
|
152
152
|
'chunkMetadata': ChunkMetadataOutputFromJSON(json['chunk_metadata']),
|
|
153
|
-
'
|
|
153
|
+
'parentPathId': json['parent_path_id'],
|
|
154
154
|
'prevSiblingPathId': json['prev_sibling_path_id'] == null ? undefined : json['prev_sibling_path_id'],
|
|
155
|
-
'
|
|
155
|
+
'nextSiblingPathId': json['next_sibling_path_id'] == null ? undefined : json['next_sibling_path_id'],
|
|
156
156
|
'materializedPath': json['materialized_path'],
|
|
157
157
|
'tenantId': json['tenant_id'],
|
|
158
158
|
'createdAt': (new Date(json['created_at'])),
|
|
@@ -177,9 +177,9 @@ export function ChunkResponseToJSONTyped(value?: ChunkResponse | null, ignoreDis
|
|
|
177
177
|
'content': value['content'],
|
|
178
178
|
'chunk_type': ChunkTypeToJSON(value['chunkType']),
|
|
179
179
|
'chunk_metadata': ChunkMetadataOutputToJSON(value['chunkMetadata']),
|
|
180
|
-
'
|
|
180
|
+
'parent_path_id': value['parentPathId'],
|
|
181
181
|
'prev_sibling_path_id': value['prevSiblingPathId'],
|
|
182
|
-
'
|
|
182
|
+
'next_sibling_path_id': value['nextSiblingPathId'],
|
|
183
183
|
'materialized_path': value['materializedPath'],
|
|
184
184
|
'tenant_id': value['tenantId'],
|
|
185
185
|
'created_at': value['createdAt'].toISOString(),
|
|
@@ -41,11 +41,11 @@ export interface CreateDocumentRequest {
|
|
|
41
41
|
*/
|
|
42
42
|
name: string;
|
|
43
43
|
/**
|
|
44
|
-
* Parent
|
|
44
|
+
* Parent PathPart ID (must be a FOLDER type)
|
|
45
45
|
* @type {string}
|
|
46
46
|
* @memberof CreateDocumentRequest
|
|
47
47
|
*/
|
|
48
|
-
|
|
48
|
+
parentPathPartId: string;
|
|
49
49
|
/**
|
|
50
50
|
* Type of document (PDF, UNKNOWN, etc.)
|
|
51
51
|
* @type {DocumentType}
|
|
@@ -67,7 +67,7 @@ export interface CreateDocumentRequest {
|
|
|
67
67
|
*/
|
|
68
68
|
export function instanceOfCreateDocumentRequest(value: object): value is CreateDocumentRequest {
|
|
69
69
|
if (!('name' in value) || value['name'] === undefined) return false;
|
|
70
|
-
if (!('
|
|
70
|
+
if (!('parentPathPartId' in value) || value['parentPathPartId'] === undefined) return false;
|
|
71
71
|
if (!('documentType' in value) || value['documentType'] === undefined) return false;
|
|
72
72
|
if (!('documentOrigin' in value) || value['documentOrigin'] === undefined) return false;
|
|
73
73
|
return true;
|
|
@@ -84,7 +84,7 @@ export function CreateDocumentRequestFromJSONTyped(json: any, ignoreDiscriminato
|
|
|
84
84
|
return {
|
|
85
85
|
|
|
86
86
|
'name': json['name'],
|
|
87
|
-
'
|
|
87
|
+
'parentPathPartId': json['parent_path_part_id'],
|
|
88
88
|
'documentType': DocumentTypeFromJSON(json['document_type']),
|
|
89
89
|
'documentOrigin': DocumentOriginFromJSON(json['document_origin']),
|
|
90
90
|
};
|
|
@@ -102,7 +102,7 @@ export function CreateDocumentRequestToJSONTyped(value?: CreateDocumentRequest |
|
|
|
102
102
|
return {
|
|
103
103
|
|
|
104
104
|
'name': value['name'],
|
|
105
|
-
'
|
|
105
|
+
'parent_path_part_id': value['parentPathPartId'],
|
|
106
106
|
'document_type': DocumentTypeToJSON(value['documentType']),
|
|
107
107
|
'document_origin': DocumentOriginToJSON(value['documentOrigin']),
|
|
108
108
|
};
|
|
@@ -26,11 +26,11 @@ export interface CreateFolderRequest {
|
|
|
26
26
|
*/
|
|
27
27
|
name: string;
|
|
28
28
|
/**
|
|
29
|
-
* Parent
|
|
29
|
+
* Parent PathPart ID (must be a FOLDER type)
|
|
30
30
|
* @type {string}
|
|
31
31
|
* @memberof CreateFolderRequest
|
|
32
32
|
*/
|
|
33
|
-
|
|
33
|
+
parentPathPartId: string;
|
|
34
34
|
}
|
|
35
35
|
|
|
36
36
|
/**
|
|
@@ -38,7 +38,7 @@ export interface CreateFolderRequest {
|
|
|
38
38
|
*/
|
|
39
39
|
export function instanceOfCreateFolderRequest(value: object): value is CreateFolderRequest {
|
|
40
40
|
if (!('name' in value) || value['name'] === undefined) return false;
|
|
41
|
-
if (!('
|
|
41
|
+
if (!('parentPathPartId' in value) || value['parentPathPartId'] === undefined) return false;
|
|
42
42
|
return true;
|
|
43
43
|
}
|
|
44
44
|
|
|
@@ -53,7 +53,7 @@ export function CreateFolderRequestFromJSONTyped(json: any, ignoreDiscriminator:
|
|
|
53
53
|
return {
|
|
54
54
|
|
|
55
55
|
'name': json['name'],
|
|
56
|
-
'
|
|
56
|
+
'parentPathPartId': json['parent_path_part_id'],
|
|
57
57
|
};
|
|
58
58
|
}
|
|
59
59
|
|
|
@@ -69,7 +69,7 @@ export function CreateFolderRequestToJSONTyped(value?: CreateFolderRequest | nul
|
|
|
69
69
|
return {
|
|
70
70
|
|
|
71
71
|
'name': value['name'],
|
|
72
|
-
'
|
|
72
|
+
'parent_path_part_id': value['parentPathPartId'],
|
|
73
73
|
};
|
|
74
74
|
}
|
|
75
75
|
|
|
@@ -67,7 +67,7 @@ export interface DocumentContentPathPart {
|
|
|
67
67
|
* @type {string}
|
|
68
68
|
* @memberof DocumentContentPathPart
|
|
69
69
|
*/
|
|
70
|
-
|
|
70
|
+
parentPathId: string;
|
|
71
71
|
/**
|
|
72
72
|
* Section ID or Chunk ID
|
|
73
73
|
* @type {string}
|
|
@@ -133,7 +133,7 @@ export function instanceOfDocumentContentPathPart(value: object): value is Docum
|
|
|
133
133
|
if (!('pathPartId' in value) || value['pathPartId'] === undefined) return false;
|
|
134
134
|
if (!('name' in value) || value['name'] === undefined) return false;
|
|
135
135
|
if (!('partType' in value) || value['partType'] === undefined) return false;
|
|
136
|
-
if (!('
|
|
136
|
+
if (!('parentPathId' in value) || value['parentPathId'] === undefined) return false;
|
|
137
137
|
if (!('metadataObjId' in value) || value['metadataObjId'] === undefined) return false;
|
|
138
138
|
if (!('depth' in value) || value['depth'] === undefined) return false;
|
|
139
139
|
if (!('materializedPath' in value) || value['materializedPath'] === undefined) return false;
|
|
@@ -155,7 +155,7 @@ export function DocumentContentPathPartFromJSONTyped(json: any, ignoreDiscrimina
|
|
|
155
155
|
'pathPartId': json['path_part_id'],
|
|
156
156
|
'name': json['name'],
|
|
157
157
|
'partType': PartTypeFromJSON(json['part_type']),
|
|
158
|
-
'
|
|
158
|
+
'parentPathId': json['parent_path_id'],
|
|
159
159
|
'metadataObjId': json['metadata_obj_id'],
|
|
160
160
|
'depth': json['depth'],
|
|
161
161
|
'content': json['content'] == null ? undefined : json['content'],
|
|
@@ -182,7 +182,7 @@ export function DocumentContentPathPartToJSONTyped(value?: DocumentContentPathPa
|
|
|
182
182
|
'path_part_id': value['pathPartId'],
|
|
183
183
|
'name': value['name'],
|
|
184
184
|
'part_type': PartTypeToJSON(value['partType']),
|
|
185
|
-
'
|
|
185
|
+
'parent_path_id': value['parentPathId'],
|
|
186
186
|
'metadata_obj_id': value['metadataObjId'],
|
|
187
187
|
'depth': value['depth'],
|
|
188
188
|
'content': value['content'],
|
|
@@ -60,11 +60,11 @@ export interface DocumentResponse {
|
|
|
60
60
|
*/
|
|
61
61
|
name: string;
|
|
62
62
|
/**
|
|
63
|
-
* Parent
|
|
63
|
+
* Parent PathPart ID
|
|
64
64
|
* @type {string}
|
|
65
65
|
* @memberof DocumentResponse
|
|
66
66
|
*/
|
|
67
|
-
|
|
67
|
+
parentPathPartId: string;
|
|
68
68
|
/**
|
|
69
69
|
* Type of document
|
|
70
70
|
* @type {DocumentType}
|
|
@@ -124,7 +124,7 @@ export function instanceOfDocumentResponse(value: object): value is DocumentResp
|
|
|
124
124
|
if (!('id' in value) || value['id'] === undefined) return false;
|
|
125
125
|
if (!('pathPartId' in value) || value['pathPartId'] === undefined) return false;
|
|
126
126
|
if (!('name' in value) || value['name'] === undefined) return false;
|
|
127
|
-
if (!('
|
|
127
|
+
if (!('parentPathPartId' in value) || value['parentPathPartId'] === undefined) return false;
|
|
128
128
|
if (!('documentType' in value) || value['documentType'] === undefined) return false;
|
|
129
129
|
if (!('documentOrigin' in value) || value['documentOrigin'] === undefined) return false;
|
|
130
130
|
if (!('activeVersionId' in value) || value['activeVersionId'] === undefined) return false;
|
|
@@ -149,7 +149,7 @@ export function DocumentResponseFromJSONTyped(json: any, ignoreDiscriminator: bo
|
|
|
149
149
|
'id': json['id'],
|
|
150
150
|
'pathPartId': json['path_part_id'],
|
|
151
151
|
'name': json['name'],
|
|
152
|
-
'
|
|
152
|
+
'parentPathPartId': json['parent_path_part_id'],
|
|
153
153
|
'documentType': DocumentTypeFromJSON(json['document_type']),
|
|
154
154
|
'documentOrigin': DocumentOriginFromJSON(json['document_origin']),
|
|
155
155
|
'activeVersionId': json['active_version_id'],
|
|
@@ -175,7 +175,7 @@ export function DocumentResponseToJSONTyped(value?: DocumentResponse | null, ign
|
|
|
175
175
|
'id': value['id'],
|
|
176
176
|
'path_part_id': value['pathPartId'],
|
|
177
177
|
'name': value['name'],
|
|
178
|
-
'
|
|
178
|
+
'parent_path_part_id': value['parentPathPartId'],
|
|
179
179
|
'document_type': DocumentTypeToJSON(value['documentType']),
|
|
180
180
|
'document_origin': DocumentOriginToJSON(value['documentOrigin']),
|
|
181
181
|
'active_version_id': value['activeVersionId'],
|
|
@@ -59,7 +59,7 @@ export interface DocumentVersionResponse {
|
|
|
59
59
|
* @type {string}
|
|
60
60
|
* @memberof DocumentVersionResponse
|
|
61
61
|
*/
|
|
62
|
-
|
|
62
|
+
parentPathId: string;
|
|
63
63
|
/**
|
|
64
64
|
* Full materialized path from root
|
|
65
65
|
* @type {string}
|
|
@@ -106,7 +106,7 @@ export function instanceOfDocumentVersionResponse(value: object): value is Docum
|
|
|
106
106
|
if (!('pathPartId' in value) || value['pathPartId'] === undefined) return false;
|
|
107
107
|
if (!('version' in value) || value['version'] === undefined) return false;
|
|
108
108
|
if (!('name' in value) || value['name'] === undefined) return false;
|
|
109
|
-
if (!('
|
|
109
|
+
if (!('parentPathId' in value) || value['parentPathId'] === undefined) return false;
|
|
110
110
|
if (!('materializedPath' in value) || value['materializedPath'] === undefined) return false;
|
|
111
111
|
if (!('tenantId' in value) || value['tenantId'] === undefined) return false;
|
|
112
112
|
if (!('createdAt' in value) || value['createdAt'] === undefined) return false;
|
|
@@ -128,7 +128,7 @@ export function DocumentVersionResponseFromJSONTyped(json: any, ignoreDiscrimina
|
|
|
128
128
|
'pathPartId': json['path_part_id'],
|
|
129
129
|
'version': json['version'],
|
|
130
130
|
'name': json['name'],
|
|
131
|
-
'
|
|
131
|
+
'parentPathId': json['parent_path_id'],
|
|
132
132
|
'materializedPath': json['materialized_path'],
|
|
133
133
|
'tenantId': json['tenant_id'],
|
|
134
134
|
'createdAt': (new Date(json['created_at'])),
|
|
@@ -153,7 +153,7 @@ export function DocumentVersionResponseToJSONTyped(value?: DocumentVersionRespon
|
|
|
153
153
|
'path_part_id': value['pathPartId'],
|
|
154
154
|
'version': value['version'],
|
|
155
155
|
'name': value['name'],
|
|
156
|
-
'
|
|
156
|
+
'parent_path_id': value['parentPathId'],
|
|
157
157
|
'materialized_path': value['materializedPath'],
|
|
158
158
|
'tenant_id': value['tenantId'],
|
|
159
159
|
'created_at': value['createdAt'].toISOString(),
|
|
@@ -52,7 +52,7 @@ import {
|
|
|
52
52
|
* - DOCUMENT: document_id and document fields are set, folder_id is None
|
|
53
53
|
*
|
|
54
54
|
* Inherited fields from PathPartResponse:
|
|
55
|
-
* - path_part_id, name, part_type,
|
|
55
|
+
* - path_part_id, name, part_type, parent_path_id, metadata_obj_id, created_at, updated_at
|
|
56
56
|
* @export
|
|
57
57
|
* @interface FolderDocumentResponse
|
|
58
58
|
*/
|
|
@@ -80,7 +80,7 @@ export interface FolderDocumentResponse {
|
|
|
80
80
|
* @type {string}
|
|
81
81
|
* @memberof FolderDocumentResponse
|
|
82
82
|
*/
|
|
83
|
-
|
|
83
|
+
parentPathId: string;
|
|
84
84
|
/**
|
|
85
85
|
* ID of the underlying object
|
|
86
86
|
* @type {string}
|
|
@@ -158,7 +158,7 @@ export function instanceOfFolderDocumentResponse(value: object): value is Folder
|
|
|
158
158
|
if (!('pathPartId' in value) || value['pathPartId'] === undefined) return false;
|
|
159
159
|
if (!('name' in value) || value['name'] === undefined) return false;
|
|
160
160
|
if (!('partType' in value) || value['partType'] === undefined) return false;
|
|
161
|
-
if (!('
|
|
161
|
+
if (!('parentPathId' in value) || value['parentPathId'] === undefined) return false;
|
|
162
162
|
if (!('metadataObjId' in value) || value['metadataObjId'] === undefined) return false;
|
|
163
163
|
if (!('materializedPath' in value) || value['materializedPath'] === undefined) return false;
|
|
164
164
|
if (!('createdAt' in value) || value['createdAt'] === undefined) return false;
|
|
@@ -180,7 +180,7 @@ export function FolderDocumentResponseFromJSONTyped(json: any, ignoreDiscriminat
|
|
|
180
180
|
'pathPartId': json['path_part_id'],
|
|
181
181
|
'name': json['name'],
|
|
182
182
|
'partType': PartTypeFromJSON(json['part_type']),
|
|
183
|
-
'
|
|
183
|
+
'parentPathId': json['parent_path_id'],
|
|
184
184
|
'metadataObjId': json['metadata_obj_id'],
|
|
185
185
|
'materializedPath': json['materialized_path'],
|
|
186
186
|
'createdAt': (new Date(json['created_at'])),
|
|
@@ -209,7 +209,7 @@ export function FolderDocumentResponseToJSONTyped(value?: FolderDocumentResponse
|
|
|
209
209
|
'path_part_id': value['pathPartId'],
|
|
210
210
|
'name': value['name'],
|
|
211
211
|
'part_type': PartTypeToJSON(value['partType']),
|
|
212
|
-
'
|
|
212
|
+
'parent_path_id': value['parentPathId'],
|
|
213
213
|
'metadata_obj_id': value['metadataObjId'],
|
|
214
214
|
'materialized_path': value['materializedPath'],
|
|
215
215
|
'created_at': value['createdAt'].toISOString(),
|
|
@@ -38,11 +38,11 @@ export interface FolderResponse {
|
|
|
38
38
|
*/
|
|
39
39
|
name: string;
|
|
40
40
|
/**
|
|
41
|
-
* Parent
|
|
41
|
+
* Parent PathPart ID
|
|
42
42
|
* @type {string}
|
|
43
43
|
* @memberof FolderResponse
|
|
44
44
|
*/
|
|
45
|
-
|
|
45
|
+
parentPathPartId: string;
|
|
46
46
|
/**
|
|
47
47
|
* Full materialized path from root
|
|
48
48
|
* @type {string}
|
|
@@ -76,7 +76,7 @@ export function instanceOfFolderResponse(value: object): value is FolderResponse
|
|
|
76
76
|
if (!('id' in value) || value['id'] === undefined) return false;
|
|
77
77
|
if (!('pathPartId' in value) || value['pathPartId'] === undefined) return false;
|
|
78
78
|
if (!('name' in value) || value['name'] === undefined) return false;
|
|
79
|
-
if (!('
|
|
79
|
+
if (!('parentPathPartId' in value) || value['parentPathPartId'] === undefined) return false;
|
|
80
80
|
if (!('materializedPath' in value) || value['materializedPath'] === undefined) return false;
|
|
81
81
|
if (!('tenantId' in value) || value['tenantId'] === undefined) return false;
|
|
82
82
|
if (!('createdAt' in value) || value['createdAt'] === undefined) return false;
|
|
@@ -97,7 +97,7 @@ export function FolderResponseFromJSONTyped(json: any, ignoreDiscriminator: bool
|
|
|
97
97
|
'id': json['id'],
|
|
98
98
|
'pathPartId': json['path_part_id'],
|
|
99
99
|
'name': json['name'],
|
|
100
|
-
'
|
|
100
|
+
'parentPathPartId': json['parent_path_part_id'],
|
|
101
101
|
'materializedPath': json['materialized_path'],
|
|
102
102
|
'tenantId': json['tenant_id'],
|
|
103
103
|
'createdAt': (new Date(json['created_at'])),
|
|
@@ -119,7 +119,7 @@ export function FolderResponseToJSONTyped(value?: FolderResponse | null, ignoreD
|
|
|
119
119
|
'id': value['id'],
|
|
120
120
|
'path_part_id': value['pathPartId'],
|
|
121
121
|
'name': value['name'],
|
|
122
|
-
'
|
|
122
|
+
'parent_path_part_id': value['parentPathPartId'],
|
|
123
123
|
'materialized_path': value['materializedPath'],
|
|
124
124
|
'tenant_id': value['tenantId'],
|
|
125
125
|
'created_at': value['createdAt'].toISOString(),
|