@knowledge-stack/ksapi 1.15.0 → 1.16.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (68) hide show
  1. package/.openapi-generator/FILES +7 -0
  2. package/README.md +2 -2
  3. package/dist/apis/AuthApi.d.ts +30 -1
  4. package/dist/apis/AuthApi.js +39 -0
  5. package/dist/apis/DocumentVersionsApi.d.ts +32 -1
  6. package/dist/apis/DocumentVersionsApi.js +37 -0
  7. package/dist/apis/DocumentsApi.d.ts +34 -1
  8. package/dist/apis/DocumentsApi.js +59 -0
  9. package/dist/apis/TenantsApi.d.ts +4 -4
  10. package/dist/apis/TenantsApi.js +2 -2
  11. package/dist/esm/apis/AuthApi.d.ts +30 -1
  12. package/dist/esm/apis/AuthApi.js +40 -1
  13. package/dist/esm/apis/DocumentVersionsApi.d.ts +32 -1
  14. package/dist/esm/apis/DocumentVersionsApi.js +38 -1
  15. package/dist/esm/apis/DocumentsApi.d.ts +34 -1
  16. package/dist/esm/apis/DocumentsApi.js +60 -1
  17. package/dist/esm/apis/TenantsApi.d.ts +4 -4
  18. package/dist/esm/apis/TenantsApi.js +2 -2
  19. package/dist/esm/models/AssumeUserRequest.d.ts +53 -0
  20. package/dist/esm/models/AssumeUserRequest.js +48 -0
  21. package/dist/esm/models/AssumeUserResponse.d.ts +47 -0
  22. package/dist/esm/models/AssumeUserResponse.js +44 -0
  23. package/dist/esm/models/DocumentVersionMetadata.d.ts +89 -0
  24. package/dist/esm/models/DocumentVersionMetadata.js +55 -0
  25. package/dist/esm/models/DocumentVersionMetadataUpdate.d.ts +87 -0
  26. package/dist/esm/models/DocumentVersionMetadataUpdate.js +55 -0
  27. package/dist/esm/models/DocumentVersionResponse.d.ts +13 -0
  28. package/dist/esm/models/DocumentVersionResponse.js +5 -0
  29. package/dist/esm/models/IngestDocumentResponse.d.ts +59 -0
  30. package/dist/esm/models/IngestDocumentResponse.js +52 -0
  31. package/dist/esm/models/PipelineState.d.ts +78 -0
  32. package/dist/esm/models/PipelineState.js +57 -0
  33. package/dist/esm/models/PipelineStatus.d.ts +27 -0
  34. package/dist/esm/models/PipelineStatus.js +45 -0
  35. package/dist/esm/models/index.d.ts +7 -0
  36. package/dist/esm/models/index.js +7 -0
  37. package/dist/models/AssumeUserRequest.d.ts +53 -0
  38. package/dist/models/AssumeUserRequest.js +56 -0
  39. package/dist/models/AssumeUserResponse.d.ts +47 -0
  40. package/dist/models/AssumeUserResponse.js +52 -0
  41. package/dist/models/DocumentVersionMetadata.d.ts +89 -0
  42. package/dist/models/DocumentVersionMetadata.js +63 -0
  43. package/dist/models/DocumentVersionMetadataUpdate.d.ts +87 -0
  44. package/dist/models/DocumentVersionMetadataUpdate.js +63 -0
  45. package/dist/models/DocumentVersionResponse.d.ts +13 -0
  46. package/dist/models/DocumentVersionResponse.js +5 -0
  47. package/dist/models/IngestDocumentResponse.d.ts +59 -0
  48. package/dist/models/IngestDocumentResponse.js +60 -0
  49. package/dist/models/PipelineState.d.ts +78 -0
  50. package/dist/models/PipelineState.js +65 -0
  51. package/dist/models/PipelineStatus.d.ts +27 -0
  52. package/dist/models/PipelineStatus.js +53 -0
  53. package/dist/models/index.d.ts +7 -0
  54. package/dist/models/index.js +7 -0
  55. package/package.json +1 -1
  56. package/src/apis/AuthApi.ts +80 -0
  57. package/src/apis/DocumentVersionsApi.ts +76 -0
  58. package/src/apis/DocumentsApi.ts +103 -0
  59. package/src/apis/TenantsApi.ts +4 -4
  60. package/src/models/AssumeUserRequest.ts +92 -0
  61. package/src/models/AssumeUserResponse.ts +83 -0
  62. package/src/models/DocumentVersionMetadata.ts +143 -0
  63. package/src/models/DocumentVersionMetadataUpdate.ts +141 -0
  64. package/src/models/DocumentVersionResponse.ts +24 -0
  65. package/src/models/IngestDocumentResponse.ts +101 -0
  66. package/src/models/PipelineState.ts +134 -0
  67. package/src/models/PipelineStatus.ts +55 -0
  68. package/src/models/index.ts +7 -0
@@ -0,0 +1,89 @@
1
+ /**
2
+ * Knowledge Stack API
3
+ * Knowledge Stack backend API for authentication and knowledge management
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
+ import type { PipelineState } from './PipelineState';
13
+ /**
14
+ * Schema for document_version.metadata JSONB field.
15
+ *
16
+ * Tracks S3 URLs for generated artifacts, pipeline execution state,
17
+ * and document statistics. Convention-based paths (images, page screenshots)
18
+ * are derived from document_id/document_version_id via s3_paths helpers,
19
+ * using a flat S3 layout: documents/{document_id}/{document_version_id}/...
20
+ * @export
21
+ * @interface DocumentVersionMetadata
22
+ */
23
+ export interface DocumentVersionMetadata {
24
+ /**
25
+ * S3 URL to the source document (set by API on upload)
26
+ * @type {string}
27
+ * @memberof DocumentVersionMetadata
28
+ */
29
+ sourceS3?: string;
30
+ /**
31
+ * S3 URL to watermark-removed source document
32
+ * @type {string}
33
+ * @memberof DocumentVersionMetadata
34
+ */
35
+ cleanedSourceS3?: string;
36
+ /**
37
+ * S3 URL to the Docling JSON conversion output
38
+ * @type {string}
39
+ * @memberof DocumentVersionMetadata
40
+ */
41
+ doclingJsonS3?: string;
42
+ /**
43
+ * Current state of the ingestion pipeline workflow
44
+ * @type {PipelineState}
45
+ * @memberof DocumentVersionMetadata
46
+ */
47
+ pipelineState?: PipelineState;
48
+ /**
49
+ * Total number of pages in the document
50
+ * @type {number}
51
+ * @memberof DocumentVersionMetadata
52
+ */
53
+ totalPages?: number;
54
+ /**
55
+ * Total number of sections created
56
+ * @type {number}
57
+ * @memberof DocumentVersionMetadata
58
+ */
59
+ totalSections?: number;
60
+ /**
61
+ * Total number of chunks created
62
+ * @type {number}
63
+ * @memberof DocumentVersionMetadata
64
+ */
65
+ totalChunks?: number;
66
+ }
67
+ /**
68
+ * Check if a given object implements the DocumentVersionMetadata interface.
69
+ */
70
+ export declare function instanceOfDocumentVersionMetadata(value: object): value is DocumentVersionMetadata;
71
+ export declare function DocumentVersionMetadataFromJSON(json: any): DocumentVersionMetadata;
72
+ export declare function DocumentVersionMetadataFromJSONTyped(json: any, ignoreDiscriminator: boolean): DocumentVersionMetadata;
73
+ export declare function DocumentVersionMetadataToJSON(json: any): DocumentVersionMetadata;
74
+ export declare function DocumentVersionMetadataToJSONTyped(value?: DocumentVersionMetadata | null, ignoreDiscriminator?: boolean): any;
75
+ export declare const DocumentVersionMetadataPropertyValidationAttributesMap: {
76
+ [property: string]: {
77
+ maxLength?: number;
78
+ minLength?: number;
79
+ pattern?: string;
80
+ maximum?: number;
81
+ exclusiveMaximum?: boolean;
82
+ minimum?: number;
83
+ exclusiveMinimum?: boolean;
84
+ multipleOf?: number;
85
+ maxItems?: number;
86
+ minItems?: number;
87
+ uniqueItems?: boolean;
88
+ };
89
+ };
@@ -0,0 +1,63 @@
1
+ "use strict";
2
+ /* tslint:disable */
3
+ /* eslint-disable */
4
+ /**
5
+ * Knowledge Stack API
6
+ * Knowledge Stack backend API for authentication and knowledge management
7
+ *
8
+ * The version of the OpenAPI document: 0.1.0
9
+ *
10
+ *
11
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
12
+ * https://openapi-generator.tech
13
+ * Do not edit the class manually.
14
+ */
15
+ Object.defineProperty(exports, "__esModule", { value: true });
16
+ exports.DocumentVersionMetadataPropertyValidationAttributesMap = void 0;
17
+ exports.instanceOfDocumentVersionMetadata = instanceOfDocumentVersionMetadata;
18
+ exports.DocumentVersionMetadataFromJSON = DocumentVersionMetadataFromJSON;
19
+ exports.DocumentVersionMetadataFromJSONTyped = DocumentVersionMetadataFromJSONTyped;
20
+ exports.DocumentVersionMetadataToJSON = DocumentVersionMetadataToJSON;
21
+ exports.DocumentVersionMetadataToJSONTyped = DocumentVersionMetadataToJSONTyped;
22
+ const PipelineState_1 = require("./PipelineState");
23
+ /**
24
+ * Check if a given object implements the DocumentVersionMetadata interface.
25
+ */
26
+ function instanceOfDocumentVersionMetadata(value) {
27
+ return true;
28
+ }
29
+ function DocumentVersionMetadataFromJSON(json) {
30
+ return DocumentVersionMetadataFromJSONTyped(json, false);
31
+ }
32
+ function DocumentVersionMetadataFromJSONTyped(json, ignoreDiscriminator) {
33
+ if (json == null) {
34
+ return json;
35
+ }
36
+ return {
37
+ 'sourceS3': json['source_s3'] == null ? undefined : json['source_s3'],
38
+ 'cleanedSourceS3': json['cleaned_source_s3'] == null ? undefined : json['cleaned_source_s3'],
39
+ 'doclingJsonS3': json['docling_json_s3'] == null ? undefined : json['docling_json_s3'],
40
+ 'pipelineState': json['pipeline_state'] == null ? undefined : (0, PipelineState_1.PipelineStateFromJSON)(json['pipeline_state']),
41
+ 'totalPages': json['total_pages'] == null ? undefined : json['total_pages'],
42
+ 'totalSections': json['total_sections'] == null ? undefined : json['total_sections'],
43
+ 'totalChunks': json['total_chunks'] == null ? undefined : json['total_chunks'],
44
+ };
45
+ }
46
+ function DocumentVersionMetadataToJSON(json) {
47
+ return DocumentVersionMetadataToJSONTyped(json, false);
48
+ }
49
+ function DocumentVersionMetadataToJSONTyped(value, ignoreDiscriminator = false) {
50
+ if (value == null) {
51
+ return value;
52
+ }
53
+ return {
54
+ 'source_s3': value['sourceS3'],
55
+ 'cleaned_source_s3': value['cleanedSourceS3'],
56
+ 'docling_json_s3': value['doclingJsonS3'],
57
+ 'pipeline_state': (0, PipelineState_1.PipelineStateToJSON)(value['pipelineState']),
58
+ 'total_pages': value['totalPages'],
59
+ 'total_sections': value['totalSections'],
60
+ 'total_chunks': value['totalChunks'],
61
+ };
62
+ }
63
+ exports.DocumentVersionMetadataPropertyValidationAttributesMap = {};
@@ -0,0 +1,87 @@
1
+ /**
2
+ * Knowledge Stack API
3
+ * Knowledge Stack backend API for authentication and knowledge management
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
+ import type { PipelineState } from './PipelineState';
13
+ /**
14
+ * Partial update schema for document version metadata.
15
+ *
16
+ * All fields are optional. Only non-``None`` fields are merged into
17
+ * the existing metadata dict.
18
+ * @export
19
+ * @interface DocumentVersionMetadataUpdate
20
+ */
21
+ export interface DocumentVersionMetadataUpdate {
22
+ /**
23
+ *
24
+ * @type {string}
25
+ * @memberof DocumentVersionMetadataUpdate
26
+ */
27
+ sourceS3?: string;
28
+ /**
29
+ *
30
+ * @type {string}
31
+ * @memberof DocumentVersionMetadataUpdate
32
+ */
33
+ cleanedSourceS3?: string;
34
+ /**
35
+ *
36
+ * @type {string}
37
+ * @memberof DocumentVersionMetadataUpdate
38
+ */
39
+ doclingJsonS3?: string;
40
+ /**
41
+ *
42
+ * @type {PipelineState}
43
+ * @memberof DocumentVersionMetadataUpdate
44
+ */
45
+ pipelineState?: PipelineState;
46
+ /**
47
+ *
48
+ * @type {number}
49
+ * @memberof DocumentVersionMetadataUpdate
50
+ */
51
+ totalPages?: number;
52
+ /**
53
+ *
54
+ * @type {number}
55
+ * @memberof DocumentVersionMetadataUpdate
56
+ */
57
+ totalSections?: number;
58
+ /**
59
+ *
60
+ * @type {number}
61
+ * @memberof DocumentVersionMetadataUpdate
62
+ */
63
+ totalChunks?: number;
64
+ }
65
+ /**
66
+ * Check if a given object implements the DocumentVersionMetadataUpdate interface.
67
+ */
68
+ export declare function instanceOfDocumentVersionMetadataUpdate(value: object): value is DocumentVersionMetadataUpdate;
69
+ export declare function DocumentVersionMetadataUpdateFromJSON(json: any): DocumentVersionMetadataUpdate;
70
+ export declare function DocumentVersionMetadataUpdateFromJSONTyped(json: any, ignoreDiscriminator: boolean): DocumentVersionMetadataUpdate;
71
+ export declare function DocumentVersionMetadataUpdateToJSON(json: any): DocumentVersionMetadataUpdate;
72
+ export declare function DocumentVersionMetadataUpdateToJSONTyped(value?: DocumentVersionMetadataUpdate | null, ignoreDiscriminator?: boolean): any;
73
+ export declare const DocumentVersionMetadataUpdatePropertyValidationAttributesMap: {
74
+ [property: string]: {
75
+ maxLength?: number;
76
+ minLength?: number;
77
+ pattern?: string;
78
+ maximum?: number;
79
+ exclusiveMaximum?: boolean;
80
+ minimum?: number;
81
+ exclusiveMinimum?: boolean;
82
+ multipleOf?: number;
83
+ maxItems?: number;
84
+ minItems?: number;
85
+ uniqueItems?: boolean;
86
+ };
87
+ };
@@ -0,0 +1,63 @@
1
+ "use strict";
2
+ /* tslint:disable */
3
+ /* eslint-disable */
4
+ /**
5
+ * Knowledge Stack API
6
+ * Knowledge Stack backend API for authentication and knowledge management
7
+ *
8
+ * The version of the OpenAPI document: 0.1.0
9
+ *
10
+ *
11
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
12
+ * https://openapi-generator.tech
13
+ * Do not edit the class manually.
14
+ */
15
+ Object.defineProperty(exports, "__esModule", { value: true });
16
+ exports.DocumentVersionMetadataUpdatePropertyValidationAttributesMap = void 0;
17
+ exports.instanceOfDocumentVersionMetadataUpdate = instanceOfDocumentVersionMetadataUpdate;
18
+ exports.DocumentVersionMetadataUpdateFromJSON = DocumentVersionMetadataUpdateFromJSON;
19
+ exports.DocumentVersionMetadataUpdateFromJSONTyped = DocumentVersionMetadataUpdateFromJSONTyped;
20
+ exports.DocumentVersionMetadataUpdateToJSON = DocumentVersionMetadataUpdateToJSON;
21
+ exports.DocumentVersionMetadataUpdateToJSONTyped = DocumentVersionMetadataUpdateToJSONTyped;
22
+ const PipelineState_1 = require("./PipelineState");
23
+ /**
24
+ * Check if a given object implements the DocumentVersionMetadataUpdate interface.
25
+ */
26
+ function instanceOfDocumentVersionMetadataUpdate(value) {
27
+ return true;
28
+ }
29
+ function DocumentVersionMetadataUpdateFromJSON(json) {
30
+ return DocumentVersionMetadataUpdateFromJSONTyped(json, false);
31
+ }
32
+ function DocumentVersionMetadataUpdateFromJSONTyped(json, ignoreDiscriminator) {
33
+ if (json == null) {
34
+ return json;
35
+ }
36
+ return {
37
+ 'sourceS3': json['source_s3'] == null ? undefined : json['source_s3'],
38
+ 'cleanedSourceS3': json['cleaned_source_s3'] == null ? undefined : json['cleaned_source_s3'],
39
+ 'doclingJsonS3': json['docling_json_s3'] == null ? undefined : json['docling_json_s3'],
40
+ 'pipelineState': json['pipeline_state'] == null ? undefined : (0, PipelineState_1.PipelineStateFromJSON)(json['pipeline_state']),
41
+ 'totalPages': json['total_pages'] == null ? undefined : json['total_pages'],
42
+ 'totalSections': json['total_sections'] == null ? undefined : json['total_sections'],
43
+ 'totalChunks': json['total_chunks'] == null ? undefined : json['total_chunks'],
44
+ };
45
+ }
46
+ function DocumentVersionMetadataUpdateToJSON(json) {
47
+ return DocumentVersionMetadataUpdateToJSONTyped(json, false);
48
+ }
49
+ function DocumentVersionMetadataUpdateToJSONTyped(value, ignoreDiscriminator = false) {
50
+ if (value == null) {
51
+ return value;
52
+ }
53
+ return {
54
+ 'source_s3': value['sourceS3'],
55
+ 'cleaned_source_s3': value['cleanedSourceS3'],
56
+ 'docling_json_s3': value['doclingJsonS3'],
57
+ 'pipeline_state': (0, PipelineState_1.PipelineStateToJSON)(value['pipelineState']),
58
+ 'total_pages': value['totalPages'],
59
+ 'total_sections': value['totalSections'],
60
+ 'total_chunks': value['totalChunks'],
61
+ };
62
+ }
63
+ exports.DocumentVersionMetadataUpdatePropertyValidationAttributesMap = {};
@@ -9,6 +9,7 @@
9
9
  * https://openapi-generator.tech
10
10
  * Do not edit the class manually.
11
11
  */
12
+ import type { DocumentVersionMetadata } from './DocumentVersionMetadata';
12
13
  /**
13
14
  * DocumentVersion response model.
14
15
  *
@@ -72,6 +73,18 @@ export interface DocumentVersionResponse {
72
73
  * @memberof DocumentVersionResponse
73
74
  */
74
75
  updatedAt: Date;
76
+ /**
77
+ * Presigned URL to download the source document (6-hour validity)
78
+ * @type {string}
79
+ * @memberof DocumentVersionResponse
80
+ */
81
+ assetS3Url?: string;
82
+ /**
83
+ * Version metadata (S3 artifacts, pipeline state, statistics)
84
+ * @type {DocumentVersionMetadata}
85
+ * @memberof DocumentVersionResponse
86
+ */
87
+ metadata?: DocumentVersionMetadata;
75
88
  }
76
89
  /**
77
90
  * Check if a given object implements the DocumentVersionResponse interface.
@@ -19,6 +19,7 @@ exports.DocumentVersionResponseFromJSON = DocumentVersionResponseFromJSON;
19
19
  exports.DocumentVersionResponseFromJSONTyped = DocumentVersionResponseFromJSONTyped;
20
20
  exports.DocumentVersionResponseToJSON = DocumentVersionResponseToJSON;
21
21
  exports.DocumentVersionResponseToJSONTyped = DocumentVersionResponseToJSONTyped;
22
+ const DocumentVersionMetadata_1 = require("./DocumentVersionMetadata");
22
23
  /**
23
24
  * Check if a given object implements the DocumentVersionResponse interface.
24
25
  */
@@ -60,6 +61,8 @@ function DocumentVersionResponseFromJSONTyped(json, ignoreDiscriminator) {
60
61
  'tenantId': json['tenant_id'],
61
62
  'createdAt': (new Date(json['created_at'])),
62
63
  'updatedAt': (new Date(json['updated_at'])),
64
+ 'assetS3Url': json['asset_s3_url'] == null ? undefined : json['asset_s3_url'],
65
+ 'metadata': json['metadata'] == null ? undefined : (0, DocumentVersionMetadata_1.DocumentVersionMetadataFromJSON)(json['metadata']),
63
66
  };
64
67
  }
65
68
  function DocumentVersionResponseToJSON(json) {
@@ -79,6 +82,8 @@ function DocumentVersionResponseToJSONTyped(value, ignoreDiscriminator = false)
79
82
  'tenant_id': value['tenantId'],
80
83
  'created_at': value['createdAt'].toISOString(),
81
84
  'updated_at': value['updatedAt'].toISOString(),
85
+ 'asset_s3_url': value['assetS3Url'],
86
+ 'metadata': (0, DocumentVersionMetadata_1.DocumentVersionMetadataToJSON)(value['metadata']),
82
87
  };
83
88
  }
84
89
  exports.DocumentVersionResponsePropertyValidationAttributesMap = {};
@@ -0,0 +1,59 @@
1
+ /**
2
+ * Knowledge Stack API
3
+ * Knowledge Stack backend API for authentication and knowledge management
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
+ * Response with workflow execution details.
14
+ * @export
15
+ * @interface IngestDocumentResponse
16
+ */
17
+ export interface IngestDocumentResponse {
18
+ /**
19
+ * Temporal workflow ID
20
+ * @type {string}
21
+ * @memberof IngestDocumentResponse
22
+ */
23
+ workflowId: string;
24
+ /**
25
+ *
26
+ * @type {string}
27
+ * @memberof IngestDocumentResponse
28
+ */
29
+ documentId: string;
30
+ /**
31
+ *
32
+ * @type {string}
33
+ * @memberof IngestDocumentResponse
34
+ */
35
+ documentVersionId: string;
36
+ }
37
+ /**
38
+ * Check if a given object implements the IngestDocumentResponse interface.
39
+ */
40
+ export declare function instanceOfIngestDocumentResponse(value: object): value is IngestDocumentResponse;
41
+ export declare function IngestDocumentResponseFromJSON(json: any): IngestDocumentResponse;
42
+ export declare function IngestDocumentResponseFromJSONTyped(json: any, ignoreDiscriminator: boolean): IngestDocumentResponse;
43
+ export declare function IngestDocumentResponseToJSON(json: any): IngestDocumentResponse;
44
+ export declare function IngestDocumentResponseToJSONTyped(value?: IngestDocumentResponse | null, ignoreDiscriminator?: boolean): any;
45
+ export declare const IngestDocumentResponsePropertyValidationAttributesMap: {
46
+ [property: string]: {
47
+ maxLength?: number;
48
+ minLength?: number;
49
+ pattern?: string;
50
+ maximum?: number;
51
+ exclusiveMaximum?: boolean;
52
+ minimum?: number;
53
+ exclusiveMinimum?: boolean;
54
+ multipleOf?: number;
55
+ maxItems?: number;
56
+ minItems?: number;
57
+ uniqueItems?: boolean;
58
+ };
59
+ };
@@ -0,0 +1,60 @@
1
+ "use strict";
2
+ /* tslint:disable */
3
+ /* eslint-disable */
4
+ /**
5
+ * Knowledge Stack API
6
+ * Knowledge Stack backend API for authentication and knowledge management
7
+ *
8
+ * The version of the OpenAPI document: 0.1.0
9
+ *
10
+ *
11
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
12
+ * https://openapi-generator.tech
13
+ * Do not edit the class manually.
14
+ */
15
+ Object.defineProperty(exports, "__esModule", { value: true });
16
+ exports.IngestDocumentResponsePropertyValidationAttributesMap = void 0;
17
+ exports.instanceOfIngestDocumentResponse = instanceOfIngestDocumentResponse;
18
+ exports.IngestDocumentResponseFromJSON = IngestDocumentResponseFromJSON;
19
+ exports.IngestDocumentResponseFromJSONTyped = IngestDocumentResponseFromJSONTyped;
20
+ exports.IngestDocumentResponseToJSON = IngestDocumentResponseToJSON;
21
+ exports.IngestDocumentResponseToJSONTyped = IngestDocumentResponseToJSONTyped;
22
+ /**
23
+ * Check if a given object implements the IngestDocumentResponse interface.
24
+ */
25
+ function instanceOfIngestDocumentResponse(value) {
26
+ if (!('workflowId' in value) || value['workflowId'] === undefined)
27
+ return false;
28
+ if (!('documentId' in value) || value['documentId'] === undefined)
29
+ return false;
30
+ if (!('documentVersionId' in value) || value['documentVersionId'] === undefined)
31
+ return false;
32
+ return true;
33
+ }
34
+ function IngestDocumentResponseFromJSON(json) {
35
+ return IngestDocumentResponseFromJSONTyped(json, false);
36
+ }
37
+ function IngestDocumentResponseFromJSONTyped(json, ignoreDiscriminator) {
38
+ if (json == null) {
39
+ return json;
40
+ }
41
+ return {
42
+ 'workflowId': json['workflow_id'],
43
+ 'documentId': json['document_id'],
44
+ 'documentVersionId': json['document_version_id'],
45
+ };
46
+ }
47
+ function IngestDocumentResponseToJSON(json) {
48
+ return IngestDocumentResponseToJSONTyped(json, false);
49
+ }
50
+ function IngestDocumentResponseToJSONTyped(value, ignoreDiscriminator = false) {
51
+ if (value == null) {
52
+ return value;
53
+ }
54
+ return {
55
+ 'workflow_id': value['workflowId'],
56
+ 'document_id': value['documentId'],
57
+ 'document_version_id': value['documentVersionId'],
58
+ };
59
+ }
60
+ exports.IngestDocumentResponsePropertyValidationAttributesMap = {};
@@ -0,0 +1,78 @@
1
+ /**
2
+ * Knowledge Stack API
3
+ * Knowledge Stack backend API for authentication and knowledge management
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
+ import type { PipelineStatus } from './PipelineStatus';
13
+ /**
14
+ * Pipeline execution state tracking.
15
+ * @export
16
+ * @interface PipelineState
17
+ */
18
+ export interface PipelineState {
19
+ /**
20
+ * Current status of the ingestion pipeline
21
+ * @type {PipelineStatus}
22
+ * @memberof PipelineState
23
+ */
24
+ status: PipelineStatus;
25
+ /**
26
+ * Timestamp of the last pipeline execution attempt
27
+ * @type {Date}
28
+ * @memberof PipelineState
29
+ */
30
+ lastRunTimestamp: Date;
31
+ /**
32
+ * Name of the last activity that executed (e.g., 'docling_conversion')
33
+ * @type {string}
34
+ * @memberof PipelineState
35
+ */
36
+ lastActivity?: string;
37
+ /**
38
+ * Error message if pipeline failed
39
+ * @type {string}
40
+ * @memberof PipelineState
41
+ */
42
+ error?: string;
43
+ /**
44
+ * Temporal workflow ID for tracking the ingestion run
45
+ * @type {string}
46
+ * @memberof PipelineState
47
+ */
48
+ temporalWorkflowId?: string;
49
+ /**
50
+ * Number of chunks processed (for progress tracking)
51
+ * @type {number}
52
+ * @memberof PipelineState
53
+ */
54
+ chunksProcessed?: number;
55
+ }
56
+ /**
57
+ * Check if a given object implements the PipelineState interface.
58
+ */
59
+ export declare function instanceOfPipelineState(value: object): value is PipelineState;
60
+ export declare function PipelineStateFromJSON(json: any): PipelineState;
61
+ export declare function PipelineStateFromJSONTyped(json: any, ignoreDiscriminator: boolean): PipelineState;
62
+ export declare function PipelineStateToJSON(json: any): PipelineState;
63
+ export declare function PipelineStateToJSONTyped(value?: PipelineState | null, ignoreDiscriminator?: boolean): any;
64
+ export declare const PipelineStatePropertyValidationAttributesMap: {
65
+ [property: string]: {
66
+ maxLength?: number;
67
+ minLength?: number;
68
+ pattern?: string;
69
+ maximum?: number;
70
+ exclusiveMaximum?: boolean;
71
+ minimum?: number;
72
+ exclusiveMinimum?: boolean;
73
+ multipleOf?: number;
74
+ maxItems?: number;
75
+ minItems?: number;
76
+ uniqueItems?: boolean;
77
+ };
78
+ };
@@ -0,0 +1,65 @@
1
+ "use strict";
2
+ /* tslint:disable */
3
+ /* eslint-disable */
4
+ /**
5
+ * Knowledge Stack API
6
+ * Knowledge Stack backend API for authentication and knowledge management
7
+ *
8
+ * The version of the OpenAPI document: 0.1.0
9
+ *
10
+ *
11
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
12
+ * https://openapi-generator.tech
13
+ * Do not edit the class manually.
14
+ */
15
+ Object.defineProperty(exports, "__esModule", { value: true });
16
+ exports.PipelineStatePropertyValidationAttributesMap = void 0;
17
+ exports.instanceOfPipelineState = instanceOfPipelineState;
18
+ exports.PipelineStateFromJSON = PipelineStateFromJSON;
19
+ exports.PipelineStateFromJSONTyped = PipelineStateFromJSONTyped;
20
+ exports.PipelineStateToJSON = PipelineStateToJSON;
21
+ exports.PipelineStateToJSONTyped = PipelineStateToJSONTyped;
22
+ const PipelineStatus_1 = require("./PipelineStatus");
23
+ /**
24
+ * Check if a given object implements the PipelineState interface.
25
+ */
26
+ function instanceOfPipelineState(value) {
27
+ if (!('status' in value) || value['status'] === undefined)
28
+ return false;
29
+ if (!('lastRunTimestamp' in value) || value['lastRunTimestamp'] === undefined)
30
+ return false;
31
+ return true;
32
+ }
33
+ function PipelineStateFromJSON(json) {
34
+ return PipelineStateFromJSONTyped(json, false);
35
+ }
36
+ function PipelineStateFromJSONTyped(json, ignoreDiscriminator) {
37
+ if (json == null) {
38
+ return json;
39
+ }
40
+ return {
41
+ 'status': (0, PipelineStatus_1.PipelineStatusFromJSON)(json['status']),
42
+ 'lastRunTimestamp': (new Date(json['last_run_timestamp'])),
43
+ 'lastActivity': json['last_activity'] == null ? undefined : json['last_activity'],
44
+ 'error': json['error'] == null ? undefined : json['error'],
45
+ 'temporalWorkflowId': json['temporal_workflow_id'] == null ? undefined : json['temporal_workflow_id'],
46
+ 'chunksProcessed': json['chunks_processed'] == null ? undefined : json['chunks_processed'],
47
+ };
48
+ }
49
+ function PipelineStateToJSON(json) {
50
+ return PipelineStateToJSONTyped(json, false);
51
+ }
52
+ function PipelineStateToJSONTyped(value, ignoreDiscriminator = false) {
53
+ if (value == null) {
54
+ return value;
55
+ }
56
+ return {
57
+ 'status': (0, PipelineStatus_1.PipelineStatusToJSON)(value['status']),
58
+ 'last_run_timestamp': value['lastRunTimestamp'].toISOString(),
59
+ 'last_activity': value['lastActivity'],
60
+ 'error': value['error'],
61
+ 'temporal_workflow_id': value['temporalWorkflowId'],
62
+ 'chunks_processed': value['chunksProcessed'],
63
+ };
64
+ }
65
+ exports.PipelineStatePropertyValidationAttributesMap = {};
@@ -0,0 +1,27 @@
1
+ /**
2
+ * Knowledge Stack API
3
+ * Knowledge Stack backend API for authentication and knowledge management
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
+ * Status of the ingestion pipeline workflow.
14
+ * @export
15
+ */
16
+ export declare const PipelineStatus: {
17
+ readonly Pending: "pending";
18
+ readonly Processing: "processing";
19
+ readonly Completed: "completed";
20
+ readonly Failed: "failed";
21
+ };
22
+ export type PipelineStatus = typeof PipelineStatus[keyof typeof PipelineStatus];
23
+ export declare function instanceOfPipelineStatus(value: any): boolean;
24
+ export declare function PipelineStatusFromJSON(json: any): PipelineStatus;
25
+ export declare function PipelineStatusFromJSONTyped(json: any, ignoreDiscriminator: boolean): PipelineStatus;
26
+ export declare function PipelineStatusToJSON(value?: PipelineStatus | null): any;
27
+ export declare function PipelineStatusToJSONTyped(value: any, ignoreDiscriminator: boolean): PipelineStatus;