@cirrobio/api-client 0.1.22 → 0.1.24
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 +5 -0
- package/README.md +1 -1
- package/dist/apis/GovernanceApi.d.ts +81 -0
- package/dist/apis/GovernanceApi.js +357 -0
- package/dist/apis/ProjectRequestsApi.d.ts +31 -0
- package/dist/apis/ProjectRequestsApi.js +137 -0
- package/dist/apis/ProjectsApi.d.ts +13 -3
- package/dist/apis/ProjectsApi.js +58 -6
- package/dist/apis/index.d.ts +2 -0
- package/dist/apis/index.js +2 -0
- package/dist/models/ClassificationInput.d.ts +37 -0
- package/dist/models/ClassificationInput.js +53 -0
- package/dist/models/GovernanceClassification.d.ts +61 -0
- package/dist/models/GovernanceClassification.js +65 -0
- package/dist/models/ProjectDetail.d.ts +6 -0
- package/dist/models/ProjectDetail.js +3 -0
- package/dist/models/ProjectInput.d.ts +77 -0
- package/dist/models/ProjectInput.js +73 -0
- package/dist/models/ProjectRequest.d.ts +8 -18
- package/dist/models/ProjectRequest.js +12 -18
- package/dist/models/Status.d.ts +2 -1
- package/dist/models/Status.js +1 -0
- package/dist/models/index.d.ts +3 -0
- package/dist/models/index.js +3 -0
- package/package.json +1 -1
- package/src/apis/GovernanceApi.ts +255 -0
- package/src/apis/ProjectRequestsApi.ts +80 -0
- package/src/apis/ProjectsApi.ts +50 -11
- package/src/apis/index.ts +2 -0
- package/src/models/ClassificationInput.ts +75 -0
- package/src/models/GovernanceClassification.ts +111 -0
- package/src/models/ProjectDetail.ts +9 -0
- package/src/models/ProjectInput.ts +151 -0
- package/src/models/ProjectRequest.ts +20 -52
- package/src/models/Status.ts +2 -1
- package/src/models/index.ts +3 -0
|
@@ -14,11 +14,6 @@
|
|
|
14
14
|
*/
|
|
15
15
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
16
16
|
exports.ProjectRequestToJSON = exports.ProjectRequestFromJSONTyped = exports.ProjectRequestFromJSON = exports.instanceOfProjectRequest = void 0;
|
|
17
|
-
var runtime_1 = require("../runtime");
|
|
18
|
-
var CloudAccount_1 = require("./CloudAccount");
|
|
19
|
-
var Contact_1 = require("./Contact");
|
|
20
|
-
var ProjectSettings_1 = require("./ProjectSettings");
|
|
21
|
-
var Tag_1 = require("./Tag");
|
|
22
17
|
/**
|
|
23
18
|
* Check if a given object implements the ProjectRequest interface.
|
|
24
19
|
*/
|
|
@@ -26,9 +21,10 @@ function instanceOfProjectRequest(value) {
|
|
|
26
21
|
var isInstance = true;
|
|
27
22
|
isInstance = isInstance && "name" in value;
|
|
28
23
|
isInstance = isInstance && "description" in value;
|
|
29
|
-
isInstance = isInstance && "
|
|
30
|
-
isInstance = isInstance && "
|
|
31
|
-
isInstance = isInstance && "
|
|
24
|
+
isInstance = isInstance && "classificationIds" in value;
|
|
25
|
+
isInstance = isInstance && "billingInfo" in value;
|
|
26
|
+
isInstance = isInstance && "adminUsername" in value;
|
|
27
|
+
isInstance = isInstance && "message" in value;
|
|
32
28
|
return isInstance;
|
|
33
29
|
}
|
|
34
30
|
exports.instanceOfProjectRequest = instanceOfProjectRequest;
|
|
@@ -43,11 +39,10 @@ function ProjectRequestFromJSONTyped(json, ignoreDiscriminator) {
|
|
|
43
39
|
return {
|
|
44
40
|
'name': json['name'],
|
|
45
41
|
'description': json['description'],
|
|
46
|
-
'
|
|
47
|
-
'
|
|
48
|
-
'
|
|
49
|
-
'
|
|
50
|
-
'tags': !(0, runtime_1.exists)(json, 'tags') ? undefined : (json['tags'] === null ? null : json['tags'].map(Tag_1.TagFromJSON)),
|
|
42
|
+
'classificationIds': json['classificationIds'],
|
|
43
|
+
'billingInfo': json['billingInfo'],
|
|
44
|
+
'adminUsername': json['adminUsername'],
|
|
45
|
+
'message': json['message'],
|
|
51
46
|
};
|
|
52
47
|
}
|
|
53
48
|
exports.ProjectRequestFromJSONTyped = ProjectRequestFromJSONTyped;
|
|
@@ -61,11 +56,10 @@ function ProjectRequestToJSON(value) {
|
|
|
61
56
|
return {
|
|
62
57
|
'name': value.name,
|
|
63
58
|
'description': value.description,
|
|
64
|
-
'
|
|
65
|
-
'
|
|
66
|
-
'
|
|
67
|
-
'
|
|
68
|
-
'tags': value.tags === undefined ? undefined : (value.tags === null ? null : value.tags.map(Tag_1.TagToJSON)),
|
|
59
|
+
'classificationIds': value.classificationIds,
|
|
60
|
+
'billingInfo': value.billingInfo,
|
|
61
|
+
'adminUsername': value.adminUsername,
|
|
62
|
+
'message': value.message,
|
|
69
63
|
};
|
|
70
64
|
}
|
|
71
65
|
exports.ProjectRequestToJSON = ProjectRequestToJSON;
|
package/dist/models/Status.d.ts
CHANGED
|
@@ -23,7 +23,8 @@ export declare enum Status {
|
|
|
23
23
|
Deleting = "DELETING",
|
|
24
24
|
Suspended = "SUSPENDED",
|
|
25
25
|
Delete = "DELETE",
|
|
26
|
-
Failed = "FAILED"
|
|
26
|
+
Failed = "FAILED",
|
|
27
|
+
Unknown = "UNKNOWN"
|
|
27
28
|
}
|
|
28
29
|
export declare function StatusFromJSON(json: any): Status;
|
|
29
30
|
export declare function StatusFromJSONTyped(json: any, ignoreDiscriminator: boolean): Status;
|
package/dist/models/Status.js
CHANGED
|
@@ -30,6 +30,7 @@ var Status;
|
|
|
30
30
|
Status["Suspended"] = "SUSPENDED";
|
|
31
31
|
Status["Delete"] = "DELETE";
|
|
32
32
|
Status["Failed"] = "FAILED";
|
|
33
|
+
Status["Unknown"] = "UNKNOWN";
|
|
33
34
|
})(Status = exports.Status || (exports.Status = {}));
|
|
34
35
|
function StatusFromJSON(json) {
|
|
35
36
|
return StatusFromJSONTyped(json, false);
|
package/dist/models/index.d.ts
CHANGED
|
@@ -10,6 +10,7 @@ export * from './BillingAccount';
|
|
|
10
10
|
export * from './BillingAccountRequest';
|
|
11
11
|
export * from './BillingMethod';
|
|
12
12
|
export * from './BudgetPeriod';
|
|
13
|
+
export * from './ClassificationInput';
|
|
13
14
|
export * from './CloudAccount';
|
|
14
15
|
export * from './CloudAccountType';
|
|
15
16
|
export * from './ColumnDefinition';
|
|
@@ -39,6 +40,7 @@ export * from './FileRequirements';
|
|
|
39
40
|
export * from './FormSchema';
|
|
40
41
|
export * from './GenerateSftpCredentialsRequest';
|
|
41
42
|
export * from './GetExecutionLogsResponse';
|
|
43
|
+
export * from './GovernanceClassification';
|
|
42
44
|
export * from './ImportDataRequest';
|
|
43
45
|
export * from './InviteUserRequest';
|
|
44
46
|
export * from './InviteUserResponse';
|
|
@@ -59,6 +61,7 @@ export * from './Project';
|
|
|
59
61
|
export * from './ProjectAccessRequest';
|
|
60
62
|
export * from './ProjectCreateOptions';
|
|
61
63
|
export * from './ProjectDetail';
|
|
64
|
+
export * from './ProjectInput';
|
|
62
65
|
export * from './ProjectMetrics';
|
|
63
66
|
export * from './ProjectRequest';
|
|
64
67
|
export * from './ProjectRole';
|
package/dist/models/index.js
CHANGED
|
@@ -28,6 +28,7 @@ __exportStar(require("./BillingAccount"), exports);
|
|
|
28
28
|
__exportStar(require("./BillingAccountRequest"), exports);
|
|
29
29
|
__exportStar(require("./BillingMethod"), exports);
|
|
30
30
|
__exportStar(require("./BudgetPeriod"), exports);
|
|
31
|
+
__exportStar(require("./ClassificationInput"), exports);
|
|
31
32
|
__exportStar(require("./CloudAccount"), exports);
|
|
32
33
|
__exportStar(require("./CloudAccountType"), exports);
|
|
33
34
|
__exportStar(require("./ColumnDefinition"), exports);
|
|
@@ -57,6 +58,7 @@ __exportStar(require("./FileRequirements"), exports);
|
|
|
57
58
|
__exportStar(require("./FormSchema"), exports);
|
|
58
59
|
__exportStar(require("./GenerateSftpCredentialsRequest"), exports);
|
|
59
60
|
__exportStar(require("./GetExecutionLogsResponse"), exports);
|
|
61
|
+
__exportStar(require("./GovernanceClassification"), exports);
|
|
60
62
|
__exportStar(require("./ImportDataRequest"), exports);
|
|
61
63
|
__exportStar(require("./InviteUserRequest"), exports);
|
|
62
64
|
__exportStar(require("./InviteUserResponse"), exports);
|
|
@@ -77,6 +79,7 @@ __exportStar(require("./Project"), exports);
|
|
|
77
79
|
__exportStar(require("./ProjectAccessRequest"), exports);
|
|
78
80
|
__exportStar(require("./ProjectCreateOptions"), exports);
|
|
79
81
|
__exportStar(require("./ProjectDetail"), exports);
|
|
82
|
+
__exportStar(require("./ProjectInput"), exports);
|
|
80
83
|
__exportStar(require("./ProjectMetrics"), exports);
|
|
81
84
|
__exportStar(require("./ProjectRequest"), exports);
|
|
82
85
|
__exportStar(require("./ProjectRole"), exports);
|
package/package.json
CHANGED
|
@@ -0,0 +1,255 @@
|
|
|
1
|
+
/* tslint:disable */
|
|
2
|
+
/* eslint-disable */
|
|
3
|
+
/**
|
|
4
|
+
* Cirro Data
|
|
5
|
+
* Cirro Data Platform service API
|
|
6
|
+
*
|
|
7
|
+
* The version of the OpenAPI document: latest
|
|
8
|
+
* Contact: support@cirro.bio
|
|
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
|
+
|
|
16
|
+
import * as runtime from '../runtime';
|
|
17
|
+
import type {
|
|
18
|
+
ClassificationInput,
|
|
19
|
+
GovernanceClassification,
|
|
20
|
+
} from '../models/index';
|
|
21
|
+
import {
|
|
22
|
+
ClassificationInputFromJSON,
|
|
23
|
+
ClassificationInputToJSON,
|
|
24
|
+
GovernanceClassificationFromJSON,
|
|
25
|
+
GovernanceClassificationToJSON,
|
|
26
|
+
} from '../models/index';
|
|
27
|
+
|
|
28
|
+
export interface CreateClassificationRequest {
|
|
29
|
+
classificationInput: ClassificationInput;
|
|
30
|
+
}
|
|
31
|
+
|
|
32
|
+
export interface DeleteClassificationRequest {
|
|
33
|
+
classificationId: string;
|
|
34
|
+
}
|
|
35
|
+
|
|
36
|
+
export interface GetClassificationRequest {
|
|
37
|
+
classificationId: string;
|
|
38
|
+
}
|
|
39
|
+
|
|
40
|
+
export interface UpdateClassificationRequest {
|
|
41
|
+
classificationId: string;
|
|
42
|
+
classificationInput: ClassificationInput;
|
|
43
|
+
}
|
|
44
|
+
|
|
45
|
+
/**
|
|
46
|
+
*
|
|
47
|
+
*/
|
|
48
|
+
export class GovernanceApi extends runtime.BaseAPI {
|
|
49
|
+
|
|
50
|
+
/**
|
|
51
|
+
* Creates a classification
|
|
52
|
+
* Create classification
|
|
53
|
+
*/
|
|
54
|
+
async createClassificationRaw(requestParameters: CreateClassificationRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<GovernanceClassification>> {
|
|
55
|
+
if (requestParameters.classificationInput === null || requestParameters.classificationInput === undefined) {
|
|
56
|
+
throw new runtime.RequiredError('classificationInput','Required parameter requestParameters.classificationInput was null or undefined when calling createClassification.');
|
|
57
|
+
}
|
|
58
|
+
|
|
59
|
+
const queryParameters: any = {};
|
|
60
|
+
|
|
61
|
+
const headerParameters: runtime.HTTPHeaders = {};
|
|
62
|
+
|
|
63
|
+
headerParameters['Content-Type'] = 'application/json';
|
|
64
|
+
|
|
65
|
+
if (this.configuration && this.configuration.accessToken) {
|
|
66
|
+
const token = this.configuration.accessToken;
|
|
67
|
+
const tokenString = await token("accessToken", []);
|
|
68
|
+
|
|
69
|
+
if (tokenString) {
|
|
70
|
+
headerParameters["Authorization"] = `Bearer ${tokenString}`;
|
|
71
|
+
}
|
|
72
|
+
}
|
|
73
|
+
const response = await this.request({
|
|
74
|
+
path: `/governance/classifications`,
|
|
75
|
+
method: 'PUT',
|
|
76
|
+
headers: headerParameters,
|
|
77
|
+
query: queryParameters,
|
|
78
|
+
body: ClassificationInputToJSON(requestParameters.classificationInput),
|
|
79
|
+
}, initOverrides);
|
|
80
|
+
|
|
81
|
+
return new runtime.JSONApiResponse(response, (jsonValue) => GovernanceClassificationFromJSON(jsonValue));
|
|
82
|
+
}
|
|
83
|
+
|
|
84
|
+
/**
|
|
85
|
+
* Creates a classification
|
|
86
|
+
* Create classification
|
|
87
|
+
*/
|
|
88
|
+
async createClassification(requestParameters: CreateClassificationRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<GovernanceClassification> {
|
|
89
|
+
const response = await this.createClassificationRaw(requestParameters, initOverrides);
|
|
90
|
+
return await response.value();
|
|
91
|
+
}
|
|
92
|
+
|
|
93
|
+
/**
|
|
94
|
+
* Deletes the classification, and removes it from all projects.
|
|
95
|
+
* Delete a classification
|
|
96
|
+
*/
|
|
97
|
+
async deleteClassificationRaw(requestParameters: DeleteClassificationRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<void>> {
|
|
98
|
+
if (requestParameters.classificationId === null || requestParameters.classificationId === undefined) {
|
|
99
|
+
throw new runtime.RequiredError('classificationId','Required parameter requestParameters.classificationId was null or undefined when calling deleteClassification.');
|
|
100
|
+
}
|
|
101
|
+
|
|
102
|
+
const queryParameters: any = {};
|
|
103
|
+
|
|
104
|
+
const headerParameters: runtime.HTTPHeaders = {};
|
|
105
|
+
|
|
106
|
+
if (this.configuration && this.configuration.accessToken) {
|
|
107
|
+
const token = this.configuration.accessToken;
|
|
108
|
+
const tokenString = await token("accessToken", []);
|
|
109
|
+
|
|
110
|
+
if (tokenString) {
|
|
111
|
+
headerParameters["Authorization"] = `Bearer ${tokenString}`;
|
|
112
|
+
}
|
|
113
|
+
}
|
|
114
|
+
const response = await this.request({
|
|
115
|
+
path: `/governance/classifications/{classificationId}`.replace(`{${"classificationId"}}`, encodeURIComponent(String(requestParameters.classificationId))),
|
|
116
|
+
method: 'DELETE',
|
|
117
|
+
headers: headerParameters,
|
|
118
|
+
query: queryParameters,
|
|
119
|
+
}, initOverrides);
|
|
120
|
+
|
|
121
|
+
return new runtime.VoidApiResponse(response);
|
|
122
|
+
}
|
|
123
|
+
|
|
124
|
+
/**
|
|
125
|
+
* Deletes the classification, and removes it from all projects.
|
|
126
|
+
* Delete a classification
|
|
127
|
+
*/
|
|
128
|
+
async deleteClassification(requestParameters: DeleteClassificationRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<void> {
|
|
129
|
+
await this.deleteClassificationRaw(requestParameters, initOverrides);
|
|
130
|
+
}
|
|
131
|
+
|
|
132
|
+
/**
|
|
133
|
+
* Retrieve a data classification
|
|
134
|
+
* Get a classification
|
|
135
|
+
*/
|
|
136
|
+
async getClassificationRaw(requestParameters: GetClassificationRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<GovernanceClassification>> {
|
|
137
|
+
if (requestParameters.classificationId === null || requestParameters.classificationId === undefined) {
|
|
138
|
+
throw new runtime.RequiredError('classificationId','Required parameter requestParameters.classificationId was null or undefined when calling getClassification.');
|
|
139
|
+
}
|
|
140
|
+
|
|
141
|
+
const queryParameters: any = {};
|
|
142
|
+
|
|
143
|
+
const headerParameters: runtime.HTTPHeaders = {};
|
|
144
|
+
|
|
145
|
+
if (this.configuration && this.configuration.accessToken) {
|
|
146
|
+
const token = this.configuration.accessToken;
|
|
147
|
+
const tokenString = await token("accessToken", []);
|
|
148
|
+
|
|
149
|
+
if (tokenString) {
|
|
150
|
+
headerParameters["Authorization"] = `Bearer ${tokenString}`;
|
|
151
|
+
}
|
|
152
|
+
}
|
|
153
|
+
const response = await this.request({
|
|
154
|
+
path: `/governance/classifications/{classificationId}`.replace(`{${"classificationId"}}`, encodeURIComponent(String(requestParameters.classificationId))),
|
|
155
|
+
method: 'GET',
|
|
156
|
+
headers: headerParameters,
|
|
157
|
+
query: queryParameters,
|
|
158
|
+
}, initOverrides);
|
|
159
|
+
|
|
160
|
+
return new runtime.JSONApiResponse(response, (jsonValue) => GovernanceClassificationFromJSON(jsonValue));
|
|
161
|
+
}
|
|
162
|
+
|
|
163
|
+
/**
|
|
164
|
+
* Retrieve a data classification
|
|
165
|
+
* Get a classification
|
|
166
|
+
*/
|
|
167
|
+
async getClassification(requestParameters: GetClassificationRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<GovernanceClassification> {
|
|
168
|
+
const response = await this.getClassificationRaw(requestParameters, initOverrides);
|
|
169
|
+
return await response.value();
|
|
170
|
+
}
|
|
171
|
+
|
|
172
|
+
/**
|
|
173
|
+
* Retrieve a list of data classifications
|
|
174
|
+
* Get classifications
|
|
175
|
+
*/
|
|
176
|
+
async getClassificationsRaw(initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<Array<GovernanceClassification>>> {
|
|
177
|
+
const queryParameters: any = {};
|
|
178
|
+
|
|
179
|
+
const headerParameters: runtime.HTTPHeaders = {};
|
|
180
|
+
|
|
181
|
+
if (this.configuration && this.configuration.accessToken) {
|
|
182
|
+
const token = this.configuration.accessToken;
|
|
183
|
+
const tokenString = await token("accessToken", []);
|
|
184
|
+
|
|
185
|
+
if (tokenString) {
|
|
186
|
+
headerParameters["Authorization"] = `Bearer ${tokenString}`;
|
|
187
|
+
}
|
|
188
|
+
}
|
|
189
|
+
const response = await this.request({
|
|
190
|
+
path: `/governance/classifications`,
|
|
191
|
+
method: 'GET',
|
|
192
|
+
headers: headerParameters,
|
|
193
|
+
query: queryParameters,
|
|
194
|
+
}, initOverrides);
|
|
195
|
+
|
|
196
|
+
return new runtime.JSONApiResponse(response, (jsonValue) => jsonValue.map(GovernanceClassificationFromJSON));
|
|
197
|
+
}
|
|
198
|
+
|
|
199
|
+
/**
|
|
200
|
+
* Retrieve a list of data classifications
|
|
201
|
+
* Get classifications
|
|
202
|
+
*/
|
|
203
|
+
async getClassifications(initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<Array<GovernanceClassification>> {
|
|
204
|
+
const response = await this.getClassificationsRaw(initOverrides);
|
|
205
|
+
return await response.value();
|
|
206
|
+
}
|
|
207
|
+
|
|
208
|
+
/**
|
|
209
|
+
* Updates a classification
|
|
210
|
+
* Update classification
|
|
211
|
+
*/
|
|
212
|
+
async updateClassificationRaw(requestParameters: UpdateClassificationRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<GovernanceClassification>> {
|
|
213
|
+
if (requestParameters.classificationId === null || requestParameters.classificationId === undefined) {
|
|
214
|
+
throw new runtime.RequiredError('classificationId','Required parameter requestParameters.classificationId was null or undefined when calling updateClassification.');
|
|
215
|
+
}
|
|
216
|
+
|
|
217
|
+
if (requestParameters.classificationInput === null || requestParameters.classificationInput === undefined) {
|
|
218
|
+
throw new runtime.RequiredError('classificationInput','Required parameter requestParameters.classificationInput was null or undefined when calling updateClassification.');
|
|
219
|
+
}
|
|
220
|
+
|
|
221
|
+
const queryParameters: any = {};
|
|
222
|
+
|
|
223
|
+
const headerParameters: runtime.HTTPHeaders = {};
|
|
224
|
+
|
|
225
|
+
headerParameters['Content-Type'] = 'application/json';
|
|
226
|
+
|
|
227
|
+
if (this.configuration && this.configuration.accessToken) {
|
|
228
|
+
const token = this.configuration.accessToken;
|
|
229
|
+
const tokenString = await token("accessToken", []);
|
|
230
|
+
|
|
231
|
+
if (tokenString) {
|
|
232
|
+
headerParameters["Authorization"] = `Bearer ${tokenString}`;
|
|
233
|
+
}
|
|
234
|
+
}
|
|
235
|
+
const response = await this.request({
|
|
236
|
+
path: `/governance/classifications/{classificationId}`.replace(`{${"classificationId"}}`, encodeURIComponent(String(requestParameters.classificationId))),
|
|
237
|
+
method: 'PUT',
|
|
238
|
+
headers: headerParameters,
|
|
239
|
+
query: queryParameters,
|
|
240
|
+
body: ClassificationInputToJSON(requestParameters.classificationInput),
|
|
241
|
+
}, initOverrides);
|
|
242
|
+
|
|
243
|
+
return new runtime.JSONApiResponse(response, (jsonValue) => GovernanceClassificationFromJSON(jsonValue));
|
|
244
|
+
}
|
|
245
|
+
|
|
246
|
+
/**
|
|
247
|
+
* Updates a classification
|
|
248
|
+
* Update classification
|
|
249
|
+
*/
|
|
250
|
+
async updateClassification(requestParameters: UpdateClassificationRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<GovernanceClassification> {
|
|
251
|
+
const response = await this.updateClassificationRaw(requestParameters, initOverrides);
|
|
252
|
+
return await response.value();
|
|
253
|
+
}
|
|
254
|
+
|
|
255
|
+
}
|
|
@@ -0,0 +1,80 @@
|
|
|
1
|
+
/* tslint:disable */
|
|
2
|
+
/* eslint-disable */
|
|
3
|
+
/**
|
|
4
|
+
* Cirro Data
|
|
5
|
+
* Cirro Data Platform service API
|
|
6
|
+
*
|
|
7
|
+
* The version of the OpenAPI document: latest
|
|
8
|
+
* Contact: support@cirro.bio
|
|
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
|
+
|
|
16
|
+
import * as runtime from '../runtime';
|
|
17
|
+
import type {
|
|
18
|
+
CreateResponse,
|
|
19
|
+
ProjectRequest,
|
|
20
|
+
} from '../models/index';
|
|
21
|
+
import {
|
|
22
|
+
CreateResponseFromJSON,
|
|
23
|
+
CreateResponseToJSON,
|
|
24
|
+
ProjectRequestFromJSON,
|
|
25
|
+
ProjectRequestToJSON,
|
|
26
|
+
} from '../models/index';
|
|
27
|
+
|
|
28
|
+
export interface CreateProjectRequestRequest {
|
|
29
|
+
projectRequest: ProjectRequest;
|
|
30
|
+
}
|
|
31
|
+
|
|
32
|
+
/**
|
|
33
|
+
*
|
|
34
|
+
*/
|
|
35
|
+
export class ProjectRequestsApi extends runtime.BaseAPI {
|
|
36
|
+
|
|
37
|
+
/**
|
|
38
|
+
* Request a new project to be created
|
|
39
|
+
* Create project request
|
|
40
|
+
*/
|
|
41
|
+
async createProjectRequestRaw(requestParameters: CreateProjectRequestRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<CreateResponse>> {
|
|
42
|
+
if (requestParameters.projectRequest === null || requestParameters.projectRequest === undefined) {
|
|
43
|
+
throw new runtime.RequiredError('projectRequest','Required parameter requestParameters.projectRequest was null or undefined when calling createProjectRequest.');
|
|
44
|
+
}
|
|
45
|
+
|
|
46
|
+
const queryParameters: any = {};
|
|
47
|
+
|
|
48
|
+
const headerParameters: runtime.HTTPHeaders = {};
|
|
49
|
+
|
|
50
|
+
headerParameters['Content-Type'] = 'application/json';
|
|
51
|
+
|
|
52
|
+
if (this.configuration && this.configuration.accessToken) {
|
|
53
|
+
const token = this.configuration.accessToken;
|
|
54
|
+
const tokenString = await token("accessToken", []);
|
|
55
|
+
|
|
56
|
+
if (tokenString) {
|
|
57
|
+
headerParameters["Authorization"] = `Bearer ${tokenString}`;
|
|
58
|
+
}
|
|
59
|
+
}
|
|
60
|
+
const response = await this.request({
|
|
61
|
+
path: `/project-requests`,
|
|
62
|
+
method: 'POST',
|
|
63
|
+
headers: headerParameters,
|
|
64
|
+
query: queryParameters,
|
|
65
|
+
body: ProjectRequestToJSON(requestParameters.projectRequest),
|
|
66
|
+
}, initOverrides);
|
|
67
|
+
|
|
68
|
+
return new runtime.JSONApiResponse(response, (jsonValue) => CreateResponseFromJSON(jsonValue));
|
|
69
|
+
}
|
|
70
|
+
|
|
71
|
+
/**
|
|
72
|
+
* Request a new project to be created
|
|
73
|
+
* Create project request
|
|
74
|
+
*/
|
|
75
|
+
async createProjectRequest(requestParameters: CreateProjectRequestRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<CreateResponse> {
|
|
76
|
+
const response = await this.createProjectRequestRaw(requestParameters, initOverrides);
|
|
77
|
+
return await response.value();
|
|
78
|
+
}
|
|
79
|
+
|
|
80
|
+
}
|
package/src/apis/ProjectsApi.ts
CHANGED
|
@@ -20,8 +20,9 @@ import type {
|
|
|
20
20
|
CreateResponse,
|
|
21
21
|
Project,
|
|
22
22
|
ProjectAccessRequest,
|
|
23
|
+
ProjectCreateOptions,
|
|
23
24
|
ProjectDetail,
|
|
24
|
-
|
|
25
|
+
ProjectInput,
|
|
25
26
|
ProjectUser,
|
|
26
27
|
SetUserProjectRoleRequest,
|
|
27
28
|
Tag,
|
|
@@ -37,10 +38,12 @@ import {
|
|
|
37
38
|
ProjectToJSON,
|
|
38
39
|
ProjectAccessRequestFromJSON,
|
|
39
40
|
ProjectAccessRequestToJSON,
|
|
41
|
+
ProjectCreateOptionsFromJSON,
|
|
42
|
+
ProjectCreateOptionsToJSON,
|
|
40
43
|
ProjectDetailFromJSON,
|
|
41
44
|
ProjectDetailToJSON,
|
|
42
|
-
|
|
43
|
-
|
|
45
|
+
ProjectInputFromJSON,
|
|
46
|
+
ProjectInputToJSON,
|
|
44
47
|
ProjectUserFromJSON,
|
|
45
48
|
ProjectUserToJSON,
|
|
46
49
|
SetUserProjectRoleRequestFromJSON,
|
|
@@ -65,7 +68,7 @@ export interface CreateAccessRequestRequest {
|
|
|
65
68
|
}
|
|
66
69
|
|
|
67
70
|
export interface CreateProjectRequest {
|
|
68
|
-
|
|
71
|
+
projectInput: ProjectInput;
|
|
69
72
|
}
|
|
70
73
|
|
|
71
74
|
export interface DenyAccessRequestRequest {
|
|
@@ -101,7 +104,7 @@ export interface UnarchiveProjectRequest {
|
|
|
101
104
|
|
|
102
105
|
export interface UpdateProjectRequest {
|
|
103
106
|
projectId: string;
|
|
104
|
-
|
|
107
|
+
projectInput: ProjectInput;
|
|
105
108
|
}
|
|
106
109
|
|
|
107
110
|
export interface UpdateProjectTagsRequest {
|
|
@@ -255,8 +258,8 @@ export class ProjectsApi extends runtime.BaseAPI {
|
|
|
255
258
|
* Create project
|
|
256
259
|
*/
|
|
257
260
|
async createProjectRaw(requestParameters: CreateProjectRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<CreateResponse>> {
|
|
258
|
-
if (requestParameters.
|
|
259
|
-
throw new runtime.RequiredError('
|
|
261
|
+
if (requestParameters.projectInput === null || requestParameters.projectInput === undefined) {
|
|
262
|
+
throw new runtime.RequiredError('projectInput','Required parameter requestParameters.projectInput was null or undefined when calling createProject.');
|
|
260
263
|
}
|
|
261
264
|
|
|
262
265
|
const queryParameters: any = {};
|
|
@@ -278,7 +281,7 @@ export class ProjectsApi extends runtime.BaseAPI {
|
|
|
278
281
|
method: 'POST',
|
|
279
282
|
headers: headerParameters,
|
|
280
283
|
query: queryParameters,
|
|
281
|
-
body:
|
|
284
|
+
body: ProjectInputToJSON(requestParameters.projectInput),
|
|
282
285
|
}, initOverrides);
|
|
283
286
|
|
|
284
287
|
return new runtime.JSONApiResponse(response, (jsonValue) => CreateResponseFromJSON(jsonValue));
|
|
@@ -456,6 +459,42 @@ export class ProjectsApi extends runtime.BaseAPI {
|
|
|
456
459
|
return await response.value();
|
|
457
460
|
}
|
|
458
461
|
|
|
462
|
+
/**
|
|
463
|
+
* Get allowed options for creating a project
|
|
464
|
+
* Get project create options
|
|
465
|
+
*/
|
|
466
|
+
async getProjectCreateOptionsRaw(initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<ProjectCreateOptions>> {
|
|
467
|
+
const queryParameters: any = {};
|
|
468
|
+
|
|
469
|
+
const headerParameters: runtime.HTTPHeaders = {};
|
|
470
|
+
|
|
471
|
+
if (this.configuration && this.configuration.accessToken) {
|
|
472
|
+
const token = this.configuration.accessToken;
|
|
473
|
+
const tokenString = await token("accessToken", []);
|
|
474
|
+
|
|
475
|
+
if (tokenString) {
|
|
476
|
+
headerParameters["Authorization"] = `Bearer ${tokenString}`;
|
|
477
|
+
}
|
|
478
|
+
}
|
|
479
|
+
const response = await this.request({
|
|
480
|
+
path: `/projects`,
|
|
481
|
+
method: 'OPTIONS',
|
|
482
|
+
headers: headerParameters,
|
|
483
|
+
query: queryParameters,
|
|
484
|
+
}, initOverrides);
|
|
485
|
+
|
|
486
|
+
return new runtime.JSONApiResponse(response, (jsonValue) => ProjectCreateOptionsFromJSON(jsonValue));
|
|
487
|
+
}
|
|
488
|
+
|
|
489
|
+
/**
|
|
490
|
+
* Get allowed options for creating a project
|
|
491
|
+
* Get project create options
|
|
492
|
+
*/
|
|
493
|
+
async getProjectCreateOptions(initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<ProjectCreateOptions> {
|
|
494
|
+
const response = await this.getProjectCreateOptionsRaw(initOverrides);
|
|
495
|
+
return await response.value();
|
|
496
|
+
}
|
|
497
|
+
|
|
459
498
|
/**
|
|
460
499
|
* Gets users who have access to the project
|
|
461
500
|
* Get project permissions
|
|
@@ -665,8 +704,8 @@ export class ProjectsApi extends runtime.BaseAPI {
|
|
|
665
704
|
throw new runtime.RequiredError('projectId','Required parameter requestParameters.projectId was null or undefined when calling updateProject.');
|
|
666
705
|
}
|
|
667
706
|
|
|
668
|
-
if (requestParameters.
|
|
669
|
-
throw new runtime.RequiredError('
|
|
707
|
+
if (requestParameters.projectInput === null || requestParameters.projectInput === undefined) {
|
|
708
|
+
throw new runtime.RequiredError('projectInput','Required parameter requestParameters.projectInput was null or undefined when calling updateProject.');
|
|
670
709
|
}
|
|
671
710
|
|
|
672
711
|
const queryParameters: any = {};
|
|
@@ -688,7 +727,7 @@ export class ProjectsApi extends runtime.BaseAPI {
|
|
|
688
727
|
method: 'PUT',
|
|
689
728
|
headers: headerParameters,
|
|
690
729
|
query: queryParameters,
|
|
691
|
-
body:
|
|
730
|
+
body: ProjectInputToJSON(requestParameters.projectInput),
|
|
692
731
|
}, initOverrides);
|
|
693
732
|
|
|
694
733
|
return new runtime.JSONApiResponse(response, (jsonValue) => ProjectDetailFromJSON(jsonValue));
|
package/src/apis/index.ts
CHANGED
|
@@ -7,10 +7,12 @@ export * from './DashboardsApi';
|
|
|
7
7
|
export * from './DatasetsApi';
|
|
8
8
|
export * from './ExecutionApi';
|
|
9
9
|
export * from './FileApi';
|
|
10
|
+
export * from './GovernanceApi';
|
|
10
11
|
export * from './MetadataApi';
|
|
11
12
|
export * from './MetricsApi';
|
|
12
13
|
export * from './NotebooksApi';
|
|
13
14
|
export * from './ProcessesApi';
|
|
15
|
+
export * from './ProjectRequestsApi';
|
|
14
16
|
export * from './ProjectsApi';
|
|
15
17
|
export * from './ReferencesApi';
|
|
16
18
|
export * from './SystemApi';
|