@knowledge-stack/ksapi 1.63.0 → 1.64.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.openapi-generator/FILES +34 -0
- package/README.md +27 -2
- package/dist/apis/WorkflowDefinitionsApi.d.ts +328 -0
- package/dist/apis/WorkflowDefinitionsApi.js +345 -0
- package/dist/apis/WorkflowRunsApi.d.ts +146 -0
- package/dist/apis/WorkflowRunsApi.js +160 -0
- package/dist/apis/index.d.ts +2 -0
- package/dist/apis/index.js +2 -0
- package/dist/esm/apis/WorkflowDefinitionsApi.d.ts +328 -0
- package/dist/esm/apis/WorkflowDefinitionsApi.js +341 -0
- package/dist/esm/apis/WorkflowRunsApi.d.ts +146 -0
- package/dist/esm/apis/WorkflowRunsApi.js +156 -0
- package/dist/esm/apis/index.d.ts +2 -0
- package/dist/esm/apis/index.js +2 -0
- package/dist/esm/models/ABCDPathSnapshot.d.ts +60 -0
- package/dist/esm/models/ABCDPathSnapshot.js +53 -0
- package/dist/esm/models/CreateWorkflowDefinitionRequest.d.ts +97 -0
- package/dist/esm/models/CreateWorkflowDefinitionRequest.js +95 -0
- package/dist/esm/models/InvokeWorkflowRequest.d.ts +47 -0
- package/dist/esm/models/InvokeWorkflowRequest.js +46 -0
- package/dist/esm/models/PaginatedResponseWorkflowDefinitionResponse.d.ts +66 -0
- package/dist/esm/models/PaginatedResponseWorkflowDefinitionResponse.js +70 -0
- package/dist/esm/models/PaginatedResponseWorkflowRunResponse.d.ts +66 -0
- package/dist/esm/models/PaginatedResponseWorkflowRunResponse.js +70 -0
- package/dist/esm/models/PartType.d.ts +2 -0
- package/dist/esm/models/PartType.js +3 -1
- package/dist/esm/models/ReferenceType.d.ts +2 -0
- package/dist/esm/models/ReferenceType.js +2 -0
- package/dist/esm/models/SelfHostedRunnerConfig.d.ts +53 -0
- package/dist/esm/models/SelfHostedRunnerConfig.js +53 -0
- package/dist/esm/models/SelfHostedRunnerConfigResponse.d.ts +47 -0
- package/dist/esm/models/SelfHostedRunnerConfigResponse.js +49 -0
- package/dist/esm/models/UpdateWorkflowDefinitionRequest.d.ts +103 -0
- package/dist/esm/models/UpdateWorkflowDefinitionRequest.js +97 -0
- package/dist/esm/models/WorkflowCallbackResponse.d.ts +47 -0
- package/dist/esm/models/WorkflowCallbackResponse.js +44 -0
- package/dist/esm/models/WorkflowDefinitionResponse.d.ts +121 -0
- package/dist/esm/models/WorkflowDefinitionResponse.js +94 -0
- package/dist/esm/models/WorkflowRunCallbackRequest.d.ts +61 -0
- package/dist/esm/models/WorkflowRunCallbackRequest.js +57 -0
- package/dist/esm/models/WorkflowRunResponse.d.ts +110 -0
- package/dist/esm/models/WorkflowRunResponse.js +87 -0
- package/dist/esm/models/WorkflowRunSnapshot.d.ts +97 -0
- package/dist/esm/models/WorkflowRunSnapshot.js +78 -0
- package/dist/esm/models/WorkflowRunStatus.d.ts +27 -0
- package/dist/esm/models/WorkflowRunStatus.js +45 -0
- package/dist/esm/models/WorkflowRunnerType.d.ts +24 -0
- package/dist/esm/models/WorkflowRunnerType.js +42 -0
- package/dist/esm/models/index.d.ts +15 -0
- package/dist/esm/models/index.js +15 -0
- package/dist/models/ABCDPathSnapshot.d.ts +60 -0
- package/dist/models/ABCDPathSnapshot.js +61 -0
- package/dist/models/CreateWorkflowDefinitionRequest.d.ts +97 -0
- package/dist/models/CreateWorkflowDefinitionRequest.js +103 -0
- package/dist/models/InvokeWorkflowRequest.d.ts +47 -0
- package/dist/models/InvokeWorkflowRequest.js +54 -0
- package/dist/models/PaginatedResponseWorkflowDefinitionResponse.d.ts +66 -0
- package/dist/models/PaginatedResponseWorkflowDefinitionResponse.js +78 -0
- package/dist/models/PaginatedResponseWorkflowRunResponse.d.ts +66 -0
- package/dist/models/PaginatedResponseWorkflowRunResponse.js +78 -0
- package/dist/models/PartType.d.ts +2 -0
- package/dist/models/PartType.js +3 -1
- package/dist/models/ReferenceType.d.ts +2 -0
- package/dist/models/ReferenceType.js +2 -0
- package/dist/models/SelfHostedRunnerConfig.d.ts +53 -0
- package/dist/models/SelfHostedRunnerConfig.js +61 -0
- package/dist/models/SelfHostedRunnerConfigResponse.d.ts +47 -0
- package/dist/models/SelfHostedRunnerConfigResponse.js +57 -0
- package/dist/models/UpdateWorkflowDefinitionRequest.d.ts +103 -0
- package/dist/models/UpdateWorkflowDefinitionRequest.js +105 -0
- package/dist/models/WorkflowCallbackResponse.d.ts +47 -0
- package/dist/models/WorkflowCallbackResponse.js +52 -0
- package/dist/models/WorkflowDefinitionResponse.d.ts +121 -0
- package/dist/models/WorkflowDefinitionResponse.js +102 -0
- package/dist/models/WorkflowRunCallbackRequest.d.ts +61 -0
- package/dist/models/WorkflowRunCallbackRequest.js +65 -0
- package/dist/models/WorkflowRunResponse.d.ts +110 -0
- package/dist/models/WorkflowRunResponse.js +95 -0
- package/dist/models/WorkflowRunSnapshot.d.ts +97 -0
- package/dist/models/WorkflowRunSnapshot.js +86 -0
- package/dist/models/WorkflowRunStatus.d.ts +27 -0
- package/dist/models/WorkflowRunStatus.js +53 -0
- package/dist/models/WorkflowRunnerType.d.ts +24 -0
- package/dist/models/WorkflowRunnerType.js +50 -0
- package/dist/models/index.d.ts +15 -0
- package/dist/models/index.js +15 -0
- package/docs/ABCDPathSnapshot.md +39 -0
- package/docs/CreateWorkflowDefinitionRequest.md +51 -0
- package/docs/InvokeWorkflowRequest.md +35 -0
- package/docs/PaginatedResponseWorkflowDefinitionResponse.md +40 -0
- package/docs/PaginatedResponseWorkflowRunResponse.md +40 -0
- package/docs/SelfHostedRunnerConfig.md +37 -0
- package/docs/SelfHostedRunnerConfigResponse.md +35 -0
- package/docs/UpdateWorkflowDefinitionRequest.md +53 -0
- package/docs/WorkflowCallbackResponse.md +35 -0
- package/docs/WorkflowDefinitionResponse.md +59 -0
- package/docs/WorkflowDefinitionsApi.md +534 -0
- package/docs/WorkflowRunCallbackRequest.md +37 -0
- package/docs/WorkflowRunResponse.md +55 -0
- package/docs/WorkflowRunSnapshot.md +51 -0
- package/docs/WorkflowRunStatus.md +33 -0
- package/docs/WorkflowRunnerType.md +33 -0
- package/docs/WorkflowRunsApi.md +224 -0
- package/package.json +1 -1
- package/src/apis/WorkflowDefinitionsApi.ts +678 -0
- package/src/apis/WorkflowRunsApi.ts +296 -0
- package/src/apis/index.ts +2 -0
- package/src/models/ABCDPathSnapshot.ts +111 -0
- package/src/models/CreateWorkflowDefinitionRequest.ts +192 -0
- package/src/models/InvokeWorkflowRequest.ts +85 -0
- package/src/models/PaginatedResponseWorkflowDefinitionResponse.ts +130 -0
- package/src/models/PaginatedResponseWorkflowRunResponse.ts +130 -0
- package/src/models/PartType.ts +3 -1
- package/src/models/ReferenceType.ts +2 -0
- package/src/models/SelfHostedRunnerConfig.ts +96 -0
- package/src/models/SelfHostedRunnerConfigResponse.ts +87 -0
- package/src/models/UpdateWorkflowDefinitionRequest.ts +200 -0
- package/src/models/WorkflowCallbackResponse.ts +83 -0
- package/src/models/WorkflowDefinitionResponse.ts +208 -0
- package/src/models/WorkflowRunCallbackRequest.ts +105 -0
- package/src/models/WorkflowRunResponse.ts +197 -0
- package/src/models/WorkflowRunSnapshot.ts +172 -0
- package/src/models/WorkflowRunStatus.ts +55 -0
- package/src/models/WorkflowRunnerType.ts +52 -0
- package/src/models/index.ts +15 -0
|
@@ -0,0 +1,83 @@
|
|
|
1
|
+
/* tslint:disable */
|
|
2
|
+
/* eslint-disable */
|
|
3
|
+
/**
|
|
4
|
+
* Knowledge Stack API
|
|
5
|
+
* Knowledge Stack backend API for authentication and knowledge management
|
|
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
|
+
|
|
15
|
+
import { mapValues } from '../runtime';
|
|
16
|
+
/**
|
|
17
|
+
* Response from the runner callback endpoint.
|
|
18
|
+
* @export
|
|
19
|
+
* @interface WorkflowCallbackResponse
|
|
20
|
+
*/
|
|
21
|
+
export interface WorkflowCallbackResponse {
|
|
22
|
+
/**
|
|
23
|
+
*
|
|
24
|
+
* @type {string}
|
|
25
|
+
* @memberof WorkflowCallbackResponse
|
|
26
|
+
*/
|
|
27
|
+
status: string;
|
|
28
|
+
}
|
|
29
|
+
|
|
30
|
+
/**
|
|
31
|
+
* Check if a given object implements the WorkflowCallbackResponse interface.
|
|
32
|
+
*/
|
|
33
|
+
export function instanceOfWorkflowCallbackResponse(value: object): value is WorkflowCallbackResponse {
|
|
34
|
+
if (!('status' in value) || value['status'] === undefined) return false;
|
|
35
|
+
return true;
|
|
36
|
+
}
|
|
37
|
+
|
|
38
|
+
export function WorkflowCallbackResponseFromJSON(json: any): WorkflowCallbackResponse {
|
|
39
|
+
return WorkflowCallbackResponseFromJSONTyped(json, false);
|
|
40
|
+
}
|
|
41
|
+
|
|
42
|
+
export function WorkflowCallbackResponseFromJSONTyped(json: any, ignoreDiscriminator: boolean): WorkflowCallbackResponse {
|
|
43
|
+
if (json == null) {
|
|
44
|
+
return json;
|
|
45
|
+
}
|
|
46
|
+
return {
|
|
47
|
+
|
|
48
|
+
'status': json['status'],
|
|
49
|
+
};
|
|
50
|
+
}
|
|
51
|
+
|
|
52
|
+
export function WorkflowCallbackResponseToJSON(json: any): WorkflowCallbackResponse {
|
|
53
|
+
return WorkflowCallbackResponseToJSONTyped(json, false);
|
|
54
|
+
}
|
|
55
|
+
|
|
56
|
+
export function WorkflowCallbackResponseToJSONTyped(value?: WorkflowCallbackResponse | null, ignoreDiscriminator: boolean = false): any {
|
|
57
|
+
if (value == null) {
|
|
58
|
+
return value;
|
|
59
|
+
}
|
|
60
|
+
|
|
61
|
+
return {
|
|
62
|
+
|
|
63
|
+
'status': value['status'],
|
|
64
|
+
};
|
|
65
|
+
}
|
|
66
|
+
|
|
67
|
+
export const WorkflowCallbackResponsePropertyValidationAttributesMap: {
|
|
68
|
+
[property: string]: {
|
|
69
|
+
maxLength?: number,
|
|
70
|
+
minLength?: number,
|
|
71
|
+
pattern?: string,
|
|
72
|
+
maximum?: number,
|
|
73
|
+
exclusiveMaximum?: boolean,
|
|
74
|
+
minimum?: number,
|
|
75
|
+
exclusiveMinimum?: boolean,
|
|
76
|
+
multipleOf?: number,
|
|
77
|
+
maxItems?: number,
|
|
78
|
+
minItems?: number,
|
|
79
|
+
uniqueItems?: boolean
|
|
80
|
+
}
|
|
81
|
+
} = {
|
|
82
|
+
}
|
|
83
|
+
|
|
@@ -0,0 +1,208 @@
|
|
|
1
|
+
/* tslint:disable */
|
|
2
|
+
/* eslint-disable */
|
|
3
|
+
/**
|
|
4
|
+
* Knowledge Stack API
|
|
5
|
+
* Knowledge Stack backend API for authentication and knowledge management
|
|
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
|
+
|
|
15
|
+
import { mapValues } from '../runtime';
|
|
16
|
+
import type { WorkflowRunnerType } from './WorkflowRunnerType';
|
|
17
|
+
import {
|
|
18
|
+
WorkflowRunnerTypeFromJSON,
|
|
19
|
+
WorkflowRunnerTypeFromJSONTyped,
|
|
20
|
+
WorkflowRunnerTypeToJSON,
|
|
21
|
+
WorkflowRunnerTypeToJSONTyped,
|
|
22
|
+
} from './WorkflowRunnerType';
|
|
23
|
+
import type { SelfHostedRunnerConfigResponse } from './SelfHostedRunnerConfigResponse';
|
|
24
|
+
import {
|
|
25
|
+
SelfHostedRunnerConfigResponseFromJSON,
|
|
26
|
+
SelfHostedRunnerConfigResponseFromJSONTyped,
|
|
27
|
+
SelfHostedRunnerConfigResponseToJSON,
|
|
28
|
+
SelfHostedRunnerConfigResponseToJSONTyped,
|
|
29
|
+
} from './SelfHostedRunnerConfigResponse';
|
|
30
|
+
|
|
31
|
+
/**
|
|
32
|
+
* Workflow definition response.
|
|
33
|
+
* @export
|
|
34
|
+
* @interface WorkflowDefinitionResponse
|
|
35
|
+
*/
|
|
36
|
+
export interface WorkflowDefinitionResponse {
|
|
37
|
+
/**
|
|
38
|
+
*
|
|
39
|
+
* @type {string}
|
|
40
|
+
* @memberof WorkflowDefinitionResponse
|
|
41
|
+
*/
|
|
42
|
+
id: string;
|
|
43
|
+
/**
|
|
44
|
+
*
|
|
45
|
+
* @type {string}
|
|
46
|
+
* @memberof WorkflowDefinitionResponse
|
|
47
|
+
*/
|
|
48
|
+
name: string;
|
|
49
|
+
/**
|
|
50
|
+
*
|
|
51
|
+
* @type {string}
|
|
52
|
+
* @memberof WorkflowDefinitionResponse
|
|
53
|
+
*/
|
|
54
|
+
description: string | null;
|
|
55
|
+
/**
|
|
56
|
+
*
|
|
57
|
+
* @type {WorkflowRunnerType}
|
|
58
|
+
* @memberof WorkflowDefinitionResponse
|
|
59
|
+
*/
|
|
60
|
+
runnerType: WorkflowRunnerType;
|
|
61
|
+
/**
|
|
62
|
+
*
|
|
63
|
+
* @type {SelfHostedRunnerConfigResponse}
|
|
64
|
+
* @memberof WorkflowDefinitionResponse
|
|
65
|
+
*/
|
|
66
|
+
runnerConfig: SelfHostedRunnerConfigResponse;
|
|
67
|
+
/**
|
|
68
|
+
*
|
|
69
|
+
* @type {number}
|
|
70
|
+
* @memberof WorkflowDefinitionResponse
|
|
71
|
+
*/
|
|
72
|
+
maxRunDurationSeconds: number;
|
|
73
|
+
/**
|
|
74
|
+
*
|
|
75
|
+
* @type {Array<string>}
|
|
76
|
+
* @memberof WorkflowDefinitionResponse
|
|
77
|
+
*/
|
|
78
|
+
sourcePathPartIds: Array<string>;
|
|
79
|
+
/**
|
|
80
|
+
*
|
|
81
|
+
* @type {Array<string>}
|
|
82
|
+
* @memberof WorkflowDefinitionResponse
|
|
83
|
+
*/
|
|
84
|
+
instructionPathPartIds: Array<string>;
|
|
85
|
+
/**
|
|
86
|
+
*
|
|
87
|
+
* @type {Array<string>}
|
|
88
|
+
* @memberof WorkflowDefinitionResponse
|
|
89
|
+
*/
|
|
90
|
+
outputPathPartIds: Array<string>;
|
|
91
|
+
/**
|
|
92
|
+
*
|
|
93
|
+
* @type {string}
|
|
94
|
+
* @memberof WorkflowDefinitionResponse
|
|
95
|
+
*/
|
|
96
|
+
templatePathPartId: string | null;
|
|
97
|
+
/**
|
|
98
|
+
*
|
|
99
|
+
* @type {boolean}
|
|
100
|
+
* @memberof WorkflowDefinitionResponse
|
|
101
|
+
*/
|
|
102
|
+
isActive: boolean;
|
|
103
|
+
/**
|
|
104
|
+
*
|
|
105
|
+
* @type {Date}
|
|
106
|
+
* @memberof WorkflowDefinitionResponse
|
|
107
|
+
*/
|
|
108
|
+
createdAt: Date;
|
|
109
|
+
/**
|
|
110
|
+
*
|
|
111
|
+
* @type {Date}
|
|
112
|
+
* @memberof WorkflowDefinitionResponse
|
|
113
|
+
*/
|
|
114
|
+
updatedAt: Date;
|
|
115
|
+
}
|
|
116
|
+
|
|
117
|
+
|
|
118
|
+
|
|
119
|
+
/**
|
|
120
|
+
* Check if a given object implements the WorkflowDefinitionResponse interface.
|
|
121
|
+
*/
|
|
122
|
+
export function instanceOfWorkflowDefinitionResponse(value: object): value is WorkflowDefinitionResponse {
|
|
123
|
+
if (!('id' in value) || value['id'] === undefined) return false;
|
|
124
|
+
if (!('name' in value) || value['name'] === undefined) return false;
|
|
125
|
+
if (!('description' in value) || value['description'] === undefined) return false;
|
|
126
|
+
if (!('runnerType' in value) || value['runnerType'] === undefined) return false;
|
|
127
|
+
if (!('runnerConfig' in value) || value['runnerConfig'] === undefined) return false;
|
|
128
|
+
if (!('maxRunDurationSeconds' in value) || value['maxRunDurationSeconds'] === undefined) return false;
|
|
129
|
+
if (!('sourcePathPartIds' in value) || value['sourcePathPartIds'] === undefined) return false;
|
|
130
|
+
if (!('instructionPathPartIds' in value) || value['instructionPathPartIds'] === undefined) return false;
|
|
131
|
+
if (!('outputPathPartIds' in value) || value['outputPathPartIds'] === undefined) return false;
|
|
132
|
+
if (!('templatePathPartId' in value) || value['templatePathPartId'] === undefined) return false;
|
|
133
|
+
if (!('isActive' in value) || value['isActive'] === undefined) return false;
|
|
134
|
+
if (!('createdAt' in value) || value['createdAt'] === undefined) return false;
|
|
135
|
+
if (!('updatedAt' in value) || value['updatedAt'] === undefined) return false;
|
|
136
|
+
return true;
|
|
137
|
+
}
|
|
138
|
+
|
|
139
|
+
export function WorkflowDefinitionResponseFromJSON(json: any): WorkflowDefinitionResponse {
|
|
140
|
+
return WorkflowDefinitionResponseFromJSONTyped(json, false);
|
|
141
|
+
}
|
|
142
|
+
|
|
143
|
+
export function WorkflowDefinitionResponseFromJSONTyped(json: any, ignoreDiscriminator: boolean): WorkflowDefinitionResponse {
|
|
144
|
+
if (json == null) {
|
|
145
|
+
return json;
|
|
146
|
+
}
|
|
147
|
+
return {
|
|
148
|
+
|
|
149
|
+
'id': json['id'],
|
|
150
|
+
'name': json['name'],
|
|
151
|
+
'description': json['description'],
|
|
152
|
+
'runnerType': WorkflowRunnerTypeFromJSON(json['runner_type']),
|
|
153
|
+
'runnerConfig': SelfHostedRunnerConfigResponseFromJSON(json['runner_config']),
|
|
154
|
+
'maxRunDurationSeconds': json['max_run_duration_seconds'],
|
|
155
|
+
'sourcePathPartIds': json['source_path_part_ids'],
|
|
156
|
+
'instructionPathPartIds': json['instruction_path_part_ids'],
|
|
157
|
+
'outputPathPartIds': json['output_path_part_ids'],
|
|
158
|
+
'templatePathPartId': json['template_path_part_id'],
|
|
159
|
+
'isActive': json['is_active'],
|
|
160
|
+
'createdAt': (new Date(json['created_at'])),
|
|
161
|
+
'updatedAt': (new Date(json['updated_at'])),
|
|
162
|
+
};
|
|
163
|
+
}
|
|
164
|
+
|
|
165
|
+
export function WorkflowDefinitionResponseToJSON(json: any): WorkflowDefinitionResponse {
|
|
166
|
+
return WorkflowDefinitionResponseToJSONTyped(json, false);
|
|
167
|
+
}
|
|
168
|
+
|
|
169
|
+
export function WorkflowDefinitionResponseToJSONTyped(value?: WorkflowDefinitionResponse | null, ignoreDiscriminator: boolean = false): any {
|
|
170
|
+
if (value == null) {
|
|
171
|
+
return value;
|
|
172
|
+
}
|
|
173
|
+
|
|
174
|
+
return {
|
|
175
|
+
|
|
176
|
+
'id': value['id'],
|
|
177
|
+
'name': value['name'],
|
|
178
|
+
'description': value['description'],
|
|
179
|
+
'runner_type': WorkflowRunnerTypeToJSON(value['runnerType']),
|
|
180
|
+
'runner_config': SelfHostedRunnerConfigResponseToJSON(value['runnerConfig']),
|
|
181
|
+
'max_run_duration_seconds': value['maxRunDurationSeconds'],
|
|
182
|
+
'source_path_part_ids': value['sourcePathPartIds'],
|
|
183
|
+
'instruction_path_part_ids': value['instructionPathPartIds'],
|
|
184
|
+
'output_path_part_ids': value['outputPathPartIds'],
|
|
185
|
+
'template_path_part_id': value['templatePathPartId'],
|
|
186
|
+
'is_active': value['isActive'],
|
|
187
|
+
'created_at': value['createdAt'].toISOString(),
|
|
188
|
+
'updated_at': value['updatedAt'].toISOString(),
|
|
189
|
+
};
|
|
190
|
+
}
|
|
191
|
+
|
|
192
|
+
export const WorkflowDefinitionResponsePropertyValidationAttributesMap: {
|
|
193
|
+
[property: string]: {
|
|
194
|
+
maxLength?: number,
|
|
195
|
+
minLength?: number,
|
|
196
|
+
pattern?: string,
|
|
197
|
+
maximum?: number,
|
|
198
|
+
exclusiveMaximum?: boolean,
|
|
199
|
+
minimum?: number,
|
|
200
|
+
exclusiveMinimum?: boolean,
|
|
201
|
+
multipleOf?: number,
|
|
202
|
+
maxItems?: number,
|
|
203
|
+
minItems?: number,
|
|
204
|
+
uniqueItems?: boolean
|
|
205
|
+
}
|
|
206
|
+
} = {
|
|
207
|
+
}
|
|
208
|
+
|
|
@@ -0,0 +1,105 @@
|
|
|
1
|
+
/* tslint:disable */
|
|
2
|
+
/* eslint-disable */
|
|
3
|
+
/**
|
|
4
|
+
* Knowledge Stack API
|
|
5
|
+
* Knowledge Stack backend API for authentication and knowledge management
|
|
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
|
+
|
|
15
|
+
import { mapValues } from '../runtime';
|
|
16
|
+
/**
|
|
17
|
+
* Request body for the runner callback endpoint.
|
|
18
|
+
* @export
|
|
19
|
+
* @interface WorkflowRunCallbackRequest
|
|
20
|
+
*/
|
|
21
|
+
export interface WorkflowRunCallbackRequest {
|
|
22
|
+
/**
|
|
23
|
+
*
|
|
24
|
+
* @type {WorkflowRunCallbackRequestStatusEnum}
|
|
25
|
+
* @memberof WorkflowRunCallbackRequest
|
|
26
|
+
*/
|
|
27
|
+
status: WorkflowRunCallbackRequestStatusEnum;
|
|
28
|
+
/**
|
|
29
|
+
*
|
|
30
|
+
* @type {string}
|
|
31
|
+
* @memberof WorkflowRunCallbackRequest
|
|
32
|
+
*/
|
|
33
|
+
error?: string | null;
|
|
34
|
+
}
|
|
35
|
+
|
|
36
|
+
|
|
37
|
+
/**
|
|
38
|
+
* @export
|
|
39
|
+
*/
|
|
40
|
+
export const WorkflowRunCallbackRequestStatusEnum = {
|
|
41
|
+
Completed: 'COMPLETED',
|
|
42
|
+
Failed: 'FAILED'
|
|
43
|
+
} as const;
|
|
44
|
+
export type WorkflowRunCallbackRequestStatusEnum = typeof WorkflowRunCallbackRequestStatusEnum[keyof typeof WorkflowRunCallbackRequestStatusEnum];
|
|
45
|
+
|
|
46
|
+
|
|
47
|
+
/**
|
|
48
|
+
* Check if a given object implements the WorkflowRunCallbackRequest interface.
|
|
49
|
+
*/
|
|
50
|
+
export function instanceOfWorkflowRunCallbackRequest(value: object): value is WorkflowRunCallbackRequest {
|
|
51
|
+
if (!('status' in value) || value['status'] === undefined) return false;
|
|
52
|
+
return true;
|
|
53
|
+
}
|
|
54
|
+
|
|
55
|
+
export function WorkflowRunCallbackRequestFromJSON(json: any): WorkflowRunCallbackRequest {
|
|
56
|
+
return WorkflowRunCallbackRequestFromJSONTyped(json, false);
|
|
57
|
+
}
|
|
58
|
+
|
|
59
|
+
export function WorkflowRunCallbackRequestFromJSONTyped(json: any, ignoreDiscriminator: boolean): WorkflowRunCallbackRequest {
|
|
60
|
+
if (json == null) {
|
|
61
|
+
return json;
|
|
62
|
+
}
|
|
63
|
+
return {
|
|
64
|
+
|
|
65
|
+
'status': json['status'],
|
|
66
|
+
'error': json['error'] == null ? undefined : json['error'],
|
|
67
|
+
};
|
|
68
|
+
}
|
|
69
|
+
|
|
70
|
+
export function WorkflowRunCallbackRequestToJSON(json: any): WorkflowRunCallbackRequest {
|
|
71
|
+
return WorkflowRunCallbackRequestToJSONTyped(json, false);
|
|
72
|
+
}
|
|
73
|
+
|
|
74
|
+
export function WorkflowRunCallbackRequestToJSONTyped(value?: WorkflowRunCallbackRequest | null, ignoreDiscriminator: boolean = false): any {
|
|
75
|
+
if (value == null) {
|
|
76
|
+
return value;
|
|
77
|
+
}
|
|
78
|
+
|
|
79
|
+
return {
|
|
80
|
+
|
|
81
|
+
'status': value['status'],
|
|
82
|
+
'error': value['error'],
|
|
83
|
+
};
|
|
84
|
+
}
|
|
85
|
+
|
|
86
|
+
export const WorkflowRunCallbackRequestPropertyValidationAttributesMap: {
|
|
87
|
+
[property: string]: {
|
|
88
|
+
maxLength?: number,
|
|
89
|
+
minLength?: number,
|
|
90
|
+
pattern?: string,
|
|
91
|
+
maximum?: number,
|
|
92
|
+
exclusiveMaximum?: boolean,
|
|
93
|
+
minimum?: number,
|
|
94
|
+
exclusiveMinimum?: boolean,
|
|
95
|
+
multipleOf?: number,
|
|
96
|
+
maxItems?: number,
|
|
97
|
+
minItems?: number,
|
|
98
|
+
uniqueItems?: boolean
|
|
99
|
+
}
|
|
100
|
+
} = {
|
|
101
|
+
error: {
|
|
102
|
+
maxLength: 8192,
|
|
103
|
+
},
|
|
104
|
+
}
|
|
105
|
+
|
|
@@ -0,0 +1,197 @@
|
|
|
1
|
+
/* tslint:disable */
|
|
2
|
+
/* eslint-disable */
|
|
3
|
+
/**
|
|
4
|
+
* Knowledge Stack API
|
|
5
|
+
* Knowledge Stack backend API for authentication and knowledge management
|
|
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
|
+
|
|
15
|
+
import { mapValues } from '../runtime';
|
|
16
|
+
import type { WorkflowRunSnapshot } from './WorkflowRunSnapshot';
|
|
17
|
+
import {
|
|
18
|
+
WorkflowRunSnapshotFromJSON,
|
|
19
|
+
WorkflowRunSnapshotFromJSONTyped,
|
|
20
|
+
WorkflowRunSnapshotToJSON,
|
|
21
|
+
WorkflowRunSnapshotToJSONTyped,
|
|
22
|
+
} from './WorkflowRunSnapshot';
|
|
23
|
+
import type { WorkflowRunStatus } from './WorkflowRunStatus';
|
|
24
|
+
import {
|
|
25
|
+
WorkflowRunStatusFromJSON,
|
|
26
|
+
WorkflowRunStatusFromJSONTyped,
|
|
27
|
+
WorkflowRunStatusToJSON,
|
|
28
|
+
WorkflowRunStatusToJSONTyped,
|
|
29
|
+
} from './WorkflowRunStatus';
|
|
30
|
+
import type { WorkflowRunnerType } from './WorkflowRunnerType';
|
|
31
|
+
import {
|
|
32
|
+
WorkflowRunnerTypeFromJSON,
|
|
33
|
+
WorkflowRunnerTypeFromJSONTyped,
|
|
34
|
+
WorkflowRunnerTypeToJSON,
|
|
35
|
+
WorkflowRunnerTypeToJSONTyped,
|
|
36
|
+
} from './WorkflowRunnerType';
|
|
37
|
+
|
|
38
|
+
/**
|
|
39
|
+
* Workflow run response.
|
|
40
|
+
* @export
|
|
41
|
+
* @interface WorkflowRunResponse
|
|
42
|
+
*/
|
|
43
|
+
export interface WorkflowRunResponse {
|
|
44
|
+
/**
|
|
45
|
+
*
|
|
46
|
+
* @type {string}
|
|
47
|
+
* @memberof WorkflowRunResponse
|
|
48
|
+
*/
|
|
49
|
+
id: string;
|
|
50
|
+
/**
|
|
51
|
+
*
|
|
52
|
+
* @type {string}
|
|
53
|
+
* @memberof WorkflowRunResponse
|
|
54
|
+
*/
|
|
55
|
+
workflowDefinitionId: string;
|
|
56
|
+
/**
|
|
57
|
+
*
|
|
58
|
+
* @type {string}
|
|
59
|
+
* @memberof WorkflowRunResponse
|
|
60
|
+
*/
|
|
61
|
+
userId: string;
|
|
62
|
+
/**
|
|
63
|
+
*
|
|
64
|
+
* @type {WorkflowRunnerType}
|
|
65
|
+
* @memberof WorkflowRunResponse
|
|
66
|
+
*/
|
|
67
|
+
runnerType: WorkflowRunnerType;
|
|
68
|
+
/**
|
|
69
|
+
*
|
|
70
|
+
* @type {WorkflowRunStatus}
|
|
71
|
+
* @memberof WorkflowRunResponse
|
|
72
|
+
*/
|
|
73
|
+
status: WorkflowRunStatus;
|
|
74
|
+
/**
|
|
75
|
+
*
|
|
76
|
+
* @type {Date}
|
|
77
|
+
* @memberof WorkflowRunResponse
|
|
78
|
+
*/
|
|
79
|
+
startedAt: Date;
|
|
80
|
+
/**
|
|
81
|
+
*
|
|
82
|
+
* @type {Date}
|
|
83
|
+
* @memberof WorkflowRunResponse
|
|
84
|
+
*/
|
|
85
|
+
completedAt: Date | null;
|
|
86
|
+
/**
|
|
87
|
+
*
|
|
88
|
+
* @type {WorkflowRunSnapshot}
|
|
89
|
+
* @memberof WorkflowRunResponse
|
|
90
|
+
*/
|
|
91
|
+
runSnapshot: WorkflowRunSnapshot;
|
|
92
|
+
/**
|
|
93
|
+
*
|
|
94
|
+
* @type {string}
|
|
95
|
+
* @memberof WorkflowRunResponse
|
|
96
|
+
*/
|
|
97
|
+
error: string | null;
|
|
98
|
+
/**
|
|
99
|
+
*
|
|
100
|
+
* @type {Date}
|
|
101
|
+
* @memberof WorkflowRunResponse
|
|
102
|
+
*/
|
|
103
|
+
createdAt: Date;
|
|
104
|
+
/**
|
|
105
|
+
*
|
|
106
|
+
* @type {Date}
|
|
107
|
+
* @memberof WorkflowRunResponse
|
|
108
|
+
*/
|
|
109
|
+
updatedAt: Date;
|
|
110
|
+
}
|
|
111
|
+
|
|
112
|
+
|
|
113
|
+
|
|
114
|
+
/**
|
|
115
|
+
* Check if a given object implements the WorkflowRunResponse interface.
|
|
116
|
+
*/
|
|
117
|
+
export function instanceOfWorkflowRunResponse(value: object): value is WorkflowRunResponse {
|
|
118
|
+
if (!('id' in value) || value['id'] === undefined) return false;
|
|
119
|
+
if (!('workflowDefinitionId' in value) || value['workflowDefinitionId'] === undefined) return false;
|
|
120
|
+
if (!('userId' in value) || value['userId'] === undefined) return false;
|
|
121
|
+
if (!('runnerType' in value) || value['runnerType'] === undefined) return false;
|
|
122
|
+
if (!('status' in value) || value['status'] === undefined) return false;
|
|
123
|
+
if (!('startedAt' in value) || value['startedAt'] === undefined) return false;
|
|
124
|
+
if (!('completedAt' in value) || value['completedAt'] === undefined) return false;
|
|
125
|
+
if (!('runSnapshot' in value) || value['runSnapshot'] === undefined) return false;
|
|
126
|
+
if (!('error' in value) || value['error'] === undefined) return false;
|
|
127
|
+
if (!('createdAt' in value) || value['createdAt'] === undefined) return false;
|
|
128
|
+
if (!('updatedAt' in value) || value['updatedAt'] === undefined) return false;
|
|
129
|
+
return true;
|
|
130
|
+
}
|
|
131
|
+
|
|
132
|
+
export function WorkflowRunResponseFromJSON(json: any): WorkflowRunResponse {
|
|
133
|
+
return WorkflowRunResponseFromJSONTyped(json, false);
|
|
134
|
+
}
|
|
135
|
+
|
|
136
|
+
export function WorkflowRunResponseFromJSONTyped(json: any, ignoreDiscriminator: boolean): WorkflowRunResponse {
|
|
137
|
+
if (json == null) {
|
|
138
|
+
return json;
|
|
139
|
+
}
|
|
140
|
+
return {
|
|
141
|
+
|
|
142
|
+
'id': json['id'],
|
|
143
|
+
'workflowDefinitionId': json['workflow_definition_id'],
|
|
144
|
+
'userId': json['user_id'],
|
|
145
|
+
'runnerType': WorkflowRunnerTypeFromJSON(json['runner_type']),
|
|
146
|
+
'status': WorkflowRunStatusFromJSON(json['status']),
|
|
147
|
+
'startedAt': (new Date(json['started_at'])),
|
|
148
|
+
'completedAt': (json['completed_at'] == null ? null : new Date(json['completed_at'])),
|
|
149
|
+
'runSnapshot': WorkflowRunSnapshotFromJSON(json['run_snapshot']),
|
|
150
|
+
'error': json['error'],
|
|
151
|
+
'createdAt': (new Date(json['created_at'])),
|
|
152
|
+
'updatedAt': (new Date(json['updated_at'])),
|
|
153
|
+
};
|
|
154
|
+
}
|
|
155
|
+
|
|
156
|
+
export function WorkflowRunResponseToJSON(json: any): WorkflowRunResponse {
|
|
157
|
+
return WorkflowRunResponseToJSONTyped(json, false);
|
|
158
|
+
}
|
|
159
|
+
|
|
160
|
+
export function WorkflowRunResponseToJSONTyped(value?: WorkflowRunResponse | null, ignoreDiscriminator: boolean = false): any {
|
|
161
|
+
if (value == null) {
|
|
162
|
+
return value;
|
|
163
|
+
}
|
|
164
|
+
|
|
165
|
+
return {
|
|
166
|
+
|
|
167
|
+
'id': value['id'],
|
|
168
|
+
'workflow_definition_id': value['workflowDefinitionId'],
|
|
169
|
+
'user_id': value['userId'],
|
|
170
|
+
'runner_type': WorkflowRunnerTypeToJSON(value['runnerType']),
|
|
171
|
+
'status': WorkflowRunStatusToJSON(value['status']),
|
|
172
|
+
'started_at': value['startedAt'].toISOString(),
|
|
173
|
+
'completed_at': value['completedAt'] == null ? value['completedAt'] : value['completedAt'].toISOString(),
|
|
174
|
+
'run_snapshot': WorkflowRunSnapshotToJSON(value['runSnapshot']),
|
|
175
|
+
'error': value['error'],
|
|
176
|
+
'created_at': value['createdAt'].toISOString(),
|
|
177
|
+
'updated_at': value['updatedAt'].toISOString(),
|
|
178
|
+
};
|
|
179
|
+
}
|
|
180
|
+
|
|
181
|
+
export const WorkflowRunResponsePropertyValidationAttributesMap: {
|
|
182
|
+
[property: string]: {
|
|
183
|
+
maxLength?: number,
|
|
184
|
+
minLength?: number,
|
|
185
|
+
pattern?: string,
|
|
186
|
+
maximum?: number,
|
|
187
|
+
exclusiveMaximum?: boolean,
|
|
188
|
+
minimum?: number,
|
|
189
|
+
exclusiveMinimum?: boolean,
|
|
190
|
+
multipleOf?: number,
|
|
191
|
+
maxItems?: number,
|
|
192
|
+
minItems?: number,
|
|
193
|
+
uniqueItems?: boolean
|
|
194
|
+
}
|
|
195
|
+
} = {
|
|
196
|
+
}
|
|
197
|
+
|