@cirrobio/api-client 0.1.23 → 0.1.25
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 +3 -3
- package/dist/apis/ProjectsApi.js +6 -6
- package/dist/apis/index.d.ts +2 -0
- package/dist/apis/index.js +2 -0
- package/dist/models/Agent.d.ts +5 -3
- package/dist/models/ClassificationInput.d.ts +37 -0
- package/dist/models/ClassificationInput.js +53 -0
- package/dist/models/ComputeEnvironmentConfiguration.d.ts +6 -4
- package/dist/models/GovernanceClassification.d.ts +61 -0
- package/dist/models/GovernanceClassification.js +65 -0
- package/dist/models/Project.d.ts +12 -0
- package/dist/models/Project.js +6 -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/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 +11 -11
- package/src/apis/index.ts +2 -0
- package/src/models/Agent.ts +3 -3
- package/src/models/ClassificationInput.ts +75 -0
- package/src/models/ComputeEnvironmentConfiguration.ts +10 -10
- package/src/models/GovernanceClassification.ts +111 -0
- package/src/models/Project.ts +18 -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/RunAnalysisRequest.ts +3 -3
- package/src/models/index.ts +3 -0
package/.openapi-generator/FILES
CHANGED
|
@@ -9,10 +9,12 @@ src/apis/DashboardsApi.ts
|
|
|
9
9
|
src/apis/DatasetsApi.ts
|
|
10
10
|
src/apis/ExecutionApi.ts
|
|
11
11
|
src/apis/FileApi.ts
|
|
12
|
+
src/apis/GovernanceApi.ts
|
|
12
13
|
src/apis/MetadataApi.ts
|
|
13
14
|
src/apis/MetricsApi.ts
|
|
14
15
|
src/apis/NotebooksApi.ts
|
|
15
16
|
src/apis/ProcessesApi.ts
|
|
17
|
+
src/apis/ProjectRequestsApi.ts
|
|
16
18
|
src/apis/ProjectsApi.ts
|
|
17
19
|
src/apis/ReferencesApi.ts
|
|
18
20
|
src/apis/SystemApi.ts
|
|
@@ -31,6 +33,7 @@ src/models/BillingAccount.ts
|
|
|
31
33
|
src/models/BillingAccountRequest.ts
|
|
32
34
|
src/models/BillingMethod.ts
|
|
33
35
|
src/models/BudgetPeriod.ts
|
|
36
|
+
src/models/ClassificationInput.ts
|
|
34
37
|
src/models/CloudAccount.ts
|
|
35
38
|
src/models/CloudAccountType.ts
|
|
36
39
|
src/models/ColumnDefinition.ts
|
|
@@ -60,6 +63,7 @@ src/models/FileRequirements.ts
|
|
|
60
63
|
src/models/FormSchema.ts
|
|
61
64
|
src/models/GenerateSftpCredentialsRequest.ts
|
|
62
65
|
src/models/GetExecutionLogsResponse.ts
|
|
66
|
+
src/models/GovernanceClassification.ts
|
|
63
67
|
src/models/ImportDataRequest.ts
|
|
64
68
|
src/models/InviteUserRequest.ts
|
|
65
69
|
src/models/InviteUserResponse.ts
|
|
@@ -80,6 +84,7 @@ src/models/Project.ts
|
|
|
80
84
|
src/models/ProjectAccessRequest.ts
|
|
81
85
|
src/models/ProjectCreateOptions.ts
|
|
82
86
|
src/models/ProjectDetail.ts
|
|
87
|
+
src/models/ProjectInput.ts
|
|
83
88
|
src/models/ProjectMetrics.ts
|
|
84
89
|
src/models/ProjectRequest.ts
|
|
85
90
|
src/models/ProjectRole.ts
|
package/README.md
CHANGED
|
@@ -0,0 +1,81 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Cirro Data
|
|
3
|
+
* Cirro Data Platform service API
|
|
4
|
+
*
|
|
5
|
+
* The version of the OpenAPI document: latest
|
|
6
|
+
* Contact: support@cirro.bio
|
|
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 * as runtime from '../runtime';
|
|
13
|
+
import type { ClassificationInput, GovernanceClassification } from '../models/index';
|
|
14
|
+
export interface CreateClassificationRequest {
|
|
15
|
+
classificationInput: ClassificationInput;
|
|
16
|
+
}
|
|
17
|
+
export interface DeleteClassificationRequest {
|
|
18
|
+
classificationId: string;
|
|
19
|
+
}
|
|
20
|
+
export interface GetClassificationRequest {
|
|
21
|
+
classificationId: string;
|
|
22
|
+
}
|
|
23
|
+
export interface UpdateClassificationRequest {
|
|
24
|
+
classificationId: string;
|
|
25
|
+
classificationInput: ClassificationInput;
|
|
26
|
+
}
|
|
27
|
+
/**
|
|
28
|
+
*
|
|
29
|
+
*/
|
|
30
|
+
export declare class GovernanceApi extends runtime.BaseAPI {
|
|
31
|
+
/**
|
|
32
|
+
* Creates a classification
|
|
33
|
+
* Create classification
|
|
34
|
+
*/
|
|
35
|
+
createClassificationRaw(requestParameters: CreateClassificationRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<GovernanceClassification>>;
|
|
36
|
+
/**
|
|
37
|
+
* Creates a classification
|
|
38
|
+
* Create classification
|
|
39
|
+
*/
|
|
40
|
+
createClassification(requestParameters: CreateClassificationRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<GovernanceClassification>;
|
|
41
|
+
/**
|
|
42
|
+
* Deletes the classification, and removes it from all projects.
|
|
43
|
+
* Delete a classification
|
|
44
|
+
*/
|
|
45
|
+
deleteClassificationRaw(requestParameters: DeleteClassificationRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<void>>;
|
|
46
|
+
/**
|
|
47
|
+
* Deletes the classification, and removes it from all projects.
|
|
48
|
+
* Delete a classification
|
|
49
|
+
*/
|
|
50
|
+
deleteClassification(requestParameters: DeleteClassificationRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<void>;
|
|
51
|
+
/**
|
|
52
|
+
* Retrieve a data classification
|
|
53
|
+
* Get a classification
|
|
54
|
+
*/
|
|
55
|
+
getClassificationRaw(requestParameters: GetClassificationRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<GovernanceClassification>>;
|
|
56
|
+
/**
|
|
57
|
+
* Retrieve a data classification
|
|
58
|
+
* Get a classification
|
|
59
|
+
*/
|
|
60
|
+
getClassification(requestParameters: GetClassificationRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<GovernanceClassification>;
|
|
61
|
+
/**
|
|
62
|
+
* Retrieve a list of data classifications
|
|
63
|
+
* Get classifications
|
|
64
|
+
*/
|
|
65
|
+
getClassificationsRaw(initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<Array<GovernanceClassification>>>;
|
|
66
|
+
/**
|
|
67
|
+
* Retrieve a list of data classifications
|
|
68
|
+
* Get classifications
|
|
69
|
+
*/
|
|
70
|
+
getClassifications(initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<Array<GovernanceClassification>>;
|
|
71
|
+
/**
|
|
72
|
+
* Updates a classification
|
|
73
|
+
* Update classification
|
|
74
|
+
*/
|
|
75
|
+
updateClassificationRaw(requestParameters: UpdateClassificationRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<GovernanceClassification>>;
|
|
76
|
+
/**
|
|
77
|
+
* Updates a classification
|
|
78
|
+
* Update classification
|
|
79
|
+
*/
|
|
80
|
+
updateClassification(requestParameters: UpdateClassificationRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<GovernanceClassification>;
|
|
81
|
+
}
|
|
@@ -0,0 +1,357 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
/* tslint:disable */
|
|
3
|
+
/* eslint-disable */
|
|
4
|
+
/**
|
|
5
|
+
* Cirro Data
|
|
6
|
+
* Cirro Data Platform service API
|
|
7
|
+
*
|
|
8
|
+
* The version of the OpenAPI document: latest
|
|
9
|
+
* Contact: support@cirro.bio
|
|
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
|
+
var __extends = (this && this.__extends) || (function () {
|
|
16
|
+
var extendStatics = function (d, b) {
|
|
17
|
+
extendStatics = Object.setPrototypeOf ||
|
|
18
|
+
({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
|
|
19
|
+
function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; };
|
|
20
|
+
return extendStatics(d, b);
|
|
21
|
+
};
|
|
22
|
+
return function (d, b) {
|
|
23
|
+
if (typeof b !== "function" && b !== null)
|
|
24
|
+
throw new TypeError("Class extends value " + String(b) + " is not a constructor or null");
|
|
25
|
+
extendStatics(d, b);
|
|
26
|
+
function __() { this.constructor = d; }
|
|
27
|
+
d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
|
|
28
|
+
};
|
|
29
|
+
})();
|
|
30
|
+
var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
|
|
31
|
+
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
|
|
32
|
+
return new (P || (P = Promise))(function (resolve, reject) {
|
|
33
|
+
function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
|
|
34
|
+
function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
|
|
35
|
+
function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
|
|
36
|
+
step((generator = generator.apply(thisArg, _arguments || [])).next());
|
|
37
|
+
});
|
|
38
|
+
};
|
|
39
|
+
var __generator = (this && this.__generator) || function (thisArg, body) {
|
|
40
|
+
var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g;
|
|
41
|
+
return g = { next: verb(0), "throw": verb(1), "return": verb(2) }, typeof Symbol === "function" && (g[Symbol.iterator] = function() { return this; }), g;
|
|
42
|
+
function verb(n) { return function (v) { return step([n, v]); }; }
|
|
43
|
+
function step(op) {
|
|
44
|
+
if (f) throw new TypeError("Generator is already executing.");
|
|
45
|
+
while (g && (g = 0, op[0] && (_ = 0)), _) try {
|
|
46
|
+
if (f = 1, y && (t = op[0] & 2 ? y["return"] : op[0] ? y["throw"] || ((t = y["return"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;
|
|
47
|
+
if (y = 0, t) op = [op[0] & 2, t.value];
|
|
48
|
+
switch (op[0]) {
|
|
49
|
+
case 0: case 1: t = op; break;
|
|
50
|
+
case 4: _.label++; return { value: op[1], done: false };
|
|
51
|
+
case 5: _.label++; y = op[1]; op = [0]; continue;
|
|
52
|
+
case 7: op = _.ops.pop(); _.trys.pop(); continue;
|
|
53
|
+
default:
|
|
54
|
+
if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; }
|
|
55
|
+
if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; }
|
|
56
|
+
if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; }
|
|
57
|
+
if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; }
|
|
58
|
+
if (t[2]) _.ops.pop();
|
|
59
|
+
_.trys.pop(); continue;
|
|
60
|
+
}
|
|
61
|
+
op = body.call(thisArg, _);
|
|
62
|
+
} catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; }
|
|
63
|
+
if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true };
|
|
64
|
+
}
|
|
65
|
+
};
|
|
66
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
67
|
+
exports.GovernanceApi = void 0;
|
|
68
|
+
var runtime = require("../runtime");
|
|
69
|
+
var index_1 = require("../models/index");
|
|
70
|
+
/**
|
|
71
|
+
*
|
|
72
|
+
*/
|
|
73
|
+
var GovernanceApi = /** @class */ (function (_super) {
|
|
74
|
+
__extends(GovernanceApi, _super);
|
|
75
|
+
function GovernanceApi() {
|
|
76
|
+
return _super !== null && _super.apply(this, arguments) || this;
|
|
77
|
+
}
|
|
78
|
+
/**
|
|
79
|
+
* Creates a classification
|
|
80
|
+
* Create classification
|
|
81
|
+
*/
|
|
82
|
+
GovernanceApi.prototype.createClassificationRaw = function (requestParameters, initOverrides) {
|
|
83
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
84
|
+
var queryParameters, headerParameters, token, tokenString, response;
|
|
85
|
+
return __generator(this, function (_a) {
|
|
86
|
+
switch (_a.label) {
|
|
87
|
+
case 0:
|
|
88
|
+
if (requestParameters.classificationInput === null || requestParameters.classificationInput === undefined) {
|
|
89
|
+
throw new runtime.RequiredError('classificationInput', 'Required parameter requestParameters.classificationInput was null or undefined when calling createClassification.');
|
|
90
|
+
}
|
|
91
|
+
queryParameters = {};
|
|
92
|
+
headerParameters = {};
|
|
93
|
+
headerParameters['Content-Type'] = 'application/json';
|
|
94
|
+
if (!(this.configuration && this.configuration.accessToken)) return [3 /*break*/, 2];
|
|
95
|
+
token = this.configuration.accessToken;
|
|
96
|
+
return [4 /*yield*/, token("accessToken", [])];
|
|
97
|
+
case 1:
|
|
98
|
+
tokenString = _a.sent();
|
|
99
|
+
if (tokenString) {
|
|
100
|
+
headerParameters["Authorization"] = "Bearer ".concat(tokenString);
|
|
101
|
+
}
|
|
102
|
+
_a.label = 2;
|
|
103
|
+
case 2: return [4 /*yield*/, this.request({
|
|
104
|
+
path: "/governance/classifications",
|
|
105
|
+
method: 'PUT',
|
|
106
|
+
headers: headerParameters,
|
|
107
|
+
query: queryParameters,
|
|
108
|
+
body: (0, index_1.ClassificationInputToJSON)(requestParameters.classificationInput),
|
|
109
|
+
}, initOverrides)];
|
|
110
|
+
case 3:
|
|
111
|
+
response = _a.sent();
|
|
112
|
+
return [2 /*return*/, new runtime.JSONApiResponse(response, function (jsonValue) { return (0, index_1.GovernanceClassificationFromJSON)(jsonValue); })];
|
|
113
|
+
}
|
|
114
|
+
});
|
|
115
|
+
});
|
|
116
|
+
};
|
|
117
|
+
/**
|
|
118
|
+
* Creates a classification
|
|
119
|
+
* Create classification
|
|
120
|
+
*/
|
|
121
|
+
GovernanceApi.prototype.createClassification = function (requestParameters, initOverrides) {
|
|
122
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
123
|
+
var response;
|
|
124
|
+
return __generator(this, function (_a) {
|
|
125
|
+
switch (_a.label) {
|
|
126
|
+
case 0: return [4 /*yield*/, this.createClassificationRaw(requestParameters, initOverrides)];
|
|
127
|
+
case 1:
|
|
128
|
+
response = _a.sent();
|
|
129
|
+
return [4 /*yield*/, response.value()];
|
|
130
|
+
case 2: return [2 /*return*/, _a.sent()];
|
|
131
|
+
}
|
|
132
|
+
});
|
|
133
|
+
});
|
|
134
|
+
};
|
|
135
|
+
/**
|
|
136
|
+
* Deletes the classification, and removes it from all projects.
|
|
137
|
+
* Delete a classification
|
|
138
|
+
*/
|
|
139
|
+
GovernanceApi.prototype.deleteClassificationRaw = function (requestParameters, initOverrides) {
|
|
140
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
141
|
+
var queryParameters, headerParameters, token, tokenString, response;
|
|
142
|
+
return __generator(this, function (_a) {
|
|
143
|
+
switch (_a.label) {
|
|
144
|
+
case 0:
|
|
145
|
+
if (requestParameters.classificationId === null || requestParameters.classificationId === undefined) {
|
|
146
|
+
throw new runtime.RequiredError('classificationId', 'Required parameter requestParameters.classificationId was null or undefined when calling deleteClassification.');
|
|
147
|
+
}
|
|
148
|
+
queryParameters = {};
|
|
149
|
+
headerParameters = {};
|
|
150
|
+
if (!(this.configuration && this.configuration.accessToken)) return [3 /*break*/, 2];
|
|
151
|
+
token = this.configuration.accessToken;
|
|
152
|
+
return [4 /*yield*/, token("accessToken", [])];
|
|
153
|
+
case 1:
|
|
154
|
+
tokenString = _a.sent();
|
|
155
|
+
if (tokenString) {
|
|
156
|
+
headerParameters["Authorization"] = "Bearer ".concat(tokenString);
|
|
157
|
+
}
|
|
158
|
+
_a.label = 2;
|
|
159
|
+
case 2: return [4 /*yield*/, this.request({
|
|
160
|
+
path: "/governance/classifications/{classificationId}".replace("{".concat("classificationId", "}"), encodeURIComponent(String(requestParameters.classificationId))),
|
|
161
|
+
method: 'DELETE',
|
|
162
|
+
headers: headerParameters,
|
|
163
|
+
query: queryParameters,
|
|
164
|
+
}, initOverrides)];
|
|
165
|
+
case 3:
|
|
166
|
+
response = _a.sent();
|
|
167
|
+
return [2 /*return*/, new runtime.VoidApiResponse(response)];
|
|
168
|
+
}
|
|
169
|
+
});
|
|
170
|
+
});
|
|
171
|
+
};
|
|
172
|
+
/**
|
|
173
|
+
* Deletes the classification, and removes it from all projects.
|
|
174
|
+
* Delete a classification
|
|
175
|
+
*/
|
|
176
|
+
GovernanceApi.prototype.deleteClassification = function (requestParameters, initOverrides) {
|
|
177
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
178
|
+
return __generator(this, function (_a) {
|
|
179
|
+
switch (_a.label) {
|
|
180
|
+
case 0: return [4 /*yield*/, this.deleteClassificationRaw(requestParameters, initOverrides)];
|
|
181
|
+
case 1:
|
|
182
|
+
_a.sent();
|
|
183
|
+
return [2 /*return*/];
|
|
184
|
+
}
|
|
185
|
+
});
|
|
186
|
+
});
|
|
187
|
+
};
|
|
188
|
+
/**
|
|
189
|
+
* Retrieve a data classification
|
|
190
|
+
* Get a classification
|
|
191
|
+
*/
|
|
192
|
+
GovernanceApi.prototype.getClassificationRaw = function (requestParameters, initOverrides) {
|
|
193
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
194
|
+
var queryParameters, headerParameters, token, tokenString, response;
|
|
195
|
+
return __generator(this, function (_a) {
|
|
196
|
+
switch (_a.label) {
|
|
197
|
+
case 0:
|
|
198
|
+
if (requestParameters.classificationId === null || requestParameters.classificationId === undefined) {
|
|
199
|
+
throw new runtime.RequiredError('classificationId', 'Required parameter requestParameters.classificationId was null or undefined when calling getClassification.');
|
|
200
|
+
}
|
|
201
|
+
queryParameters = {};
|
|
202
|
+
headerParameters = {};
|
|
203
|
+
if (!(this.configuration && this.configuration.accessToken)) return [3 /*break*/, 2];
|
|
204
|
+
token = this.configuration.accessToken;
|
|
205
|
+
return [4 /*yield*/, token("accessToken", [])];
|
|
206
|
+
case 1:
|
|
207
|
+
tokenString = _a.sent();
|
|
208
|
+
if (tokenString) {
|
|
209
|
+
headerParameters["Authorization"] = "Bearer ".concat(tokenString);
|
|
210
|
+
}
|
|
211
|
+
_a.label = 2;
|
|
212
|
+
case 2: return [4 /*yield*/, this.request({
|
|
213
|
+
path: "/governance/classifications/{classificationId}".replace("{".concat("classificationId", "}"), encodeURIComponent(String(requestParameters.classificationId))),
|
|
214
|
+
method: 'GET',
|
|
215
|
+
headers: headerParameters,
|
|
216
|
+
query: queryParameters,
|
|
217
|
+
}, initOverrides)];
|
|
218
|
+
case 3:
|
|
219
|
+
response = _a.sent();
|
|
220
|
+
return [2 /*return*/, new runtime.JSONApiResponse(response, function (jsonValue) { return (0, index_1.GovernanceClassificationFromJSON)(jsonValue); })];
|
|
221
|
+
}
|
|
222
|
+
});
|
|
223
|
+
});
|
|
224
|
+
};
|
|
225
|
+
/**
|
|
226
|
+
* Retrieve a data classification
|
|
227
|
+
* Get a classification
|
|
228
|
+
*/
|
|
229
|
+
GovernanceApi.prototype.getClassification = function (requestParameters, initOverrides) {
|
|
230
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
231
|
+
var response;
|
|
232
|
+
return __generator(this, function (_a) {
|
|
233
|
+
switch (_a.label) {
|
|
234
|
+
case 0: return [4 /*yield*/, this.getClassificationRaw(requestParameters, initOverrides)];
|
|
235
|
+
case 1:
|
|
236
|
+
response = _a.sent();
|
|
237
|
+
return [4 /*yield*/, response.value()];
|
|
238
|
+
case 2: return [2 /*return*/, _a.sent()];
|
|
239
|
+
}
|
|
240
|
+
});
|
|
241
|
+
});
|
|
242
|
+
};
|
|
243
|
+
/**
|
|
244
|
+
* Retrieve a list of data classifications
|
|
245
|
+
* Get classifications
|
|
246
|
+
*/
|
|
247
|
+
GovernanceApi.prototype.getClassificationsRaw = function (initOverrides) {
|
|
248
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
249
|
+
var queryParameters, headerParameters, token, tokenString, response;
|
|
250
|
+
return __generator(this, function (_a) {
|
|
251
|
+
switch (_a.label) {
|
|
252
|
+
case 0:
|
|
253
|
+
queryParameters = {};
|
|
254
|
+
headerParameters = {};
|
|
255
|
+
if (!(this.configuration && this.configuration.accessToken)) return [3 /*break*/, 2];
|
|
256
|
+
token = this.configuration.accessToken;
|
|
257
|
+
return [4 /*yield*/, token("accessToken", [])];
|
|
258
|
+
case 1:
|
|
259
|
+
tokenString = _a.sent();
|
|
260
|
+
if (tokenString) {
|
|
261
|
+
headerParameters["Authorization"] = "Bearer ".concat(tokenString);
|
|
262
|
+
}
|
|
263
|
+
_a.label = 2;
|
|
264
|
+
case 2: return [4 /*yield*/, this.request({
|
|
265
|
+
path: "/governance/classifications",
|
|
266
|
+
method: 'GET',
|
|
267
|
+
headers: headerParameters,
|
|
268
|
+
query: queryParameters,
|
|
269
|
+
}, initOverrides)];
|
|
270
|
+
case 3:
|
|
271
|
+
response = _a.sent();
|
|
272
|
+
return [2 /*return*/, new runtime.JSONApiResponse(response, function (jsonValue) { return jsonValue.map(index_1.GovernanceClassificationFromJSON); })];
|
|
273
|
+
}
|
|
274
|
+
});
|
|
275
|
+
});
|
|
276
|
+
};
|
|
277
|
+
/**
|
|
278
|
+
* Retrieve a list of data classifications
|
|
279
|
+
* Get classifications
|
|
280
|
+
*/
|
|
281
|
+
GovernanceApi.prototype.getClassifications = function (initOverrides) {
|
|
282
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
283
|
+
var response;
|
|
284
|
+
return __generator(this, function (_a) {
|
|
285
|
+
switch (_a.label) {
|
|
286
|
+
case 0: return [4 /*yield*/, this.getClassificationsRaw(initOverrides)];
|
|
287
|
+
case 1:
|
|
288
|
+
response = _a.sent();
|
|
289
|
+
return [4 /*yield*/, response.value()];
|
|
290
|
+
case 2: return [2 /*return*/, _a.sent()];
|
|
291
|
+
}
|
|
292
|
+
});
|
|
293
|
+
});
|
|
294
|
+
};
|
|
295
|
+
/**
|
|
296
|
+
* Updates a classification
|
|
297
|
+
* Update classification
|
|
298
|
+
*/
|
|
299
|
+
GovernanceApi.prototype.updateClassificationRaw = function (requestParameters, initOverrides) {
|
|
300
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
301
|
+
var queryParameters, headerParameters, token, tokenString, response;
|
|
302
|
+
return __generator(this, function (_a) {
|
|
303
|
+
switch (_a.label) {
|
|
304
|
+
case 0:
|
|
305
|
+
if (requestParameters.classificationId === null || requestParameters.classificationId === undefined) {
|
|
306
|
+
throw new runtime.RequiredError('classificationId', 'Required parameter requestParameters.classificationId was null or undefined when calling updateClassification.');
|
|
307
|
+
}
|
|
308
|
+
if (requestParameters.classificationInput === null || requestParameters.classificationInput === undefined) {
|
|
309
|
+
throw new runtime.RequiredError('classificationInput', 'Required parameter requestParameters.classificationInput was null or undefined when calling updateClassification.');
|
|
310
|
+
}
|
|
311
|
+
queryParameters = {};
|
|
312
|
+
headerParameters = {};
|
|
313
|
+
headerParameters['Content-Type'] = 'application/json';
|
|
314
|
+
if (!(this.configuration && this.configuration.accessToken)) return [3 /*break*/, 2];
|
|
315
|
+
token = this.configuration.accessToken;
|
|
316
|
+
return [4 /*yield*/, token("accessToken", [])];
|
|
317
|
+
case 1:
|
|
318
|
+
tokenString = _a.sent();
|
|
319
|
+
if (tokenString) {
|
|
320
|
+
headerParameters["Authorization"] = "Bearer ".concat(tokenString);
|
|
321
|
+
}
|
|
322
|
+
_a.label = 2;
|
|
323
|
+
case 2: return [4 /*yield*/, this.request({
|
|
324
|
+
path: "/governance/classifications/{classificationId}".replace("{".concat("classificationId", "}"), encodeURIComponent(String(requestParameters.classificationId))),
|
|
325
|
+
method: 'PUT',
|
|
326
|
+
headers: headerParameters,
|
|
327
|
+
query: queryParameters,
|
|
328
|
+
body: (0, index_1.ClassificationInputToJSON)(requestParameters.classificationInput),
|
|
329
|
+
}, initOverrides)];
|
|
330
|
+
case 3:
|
|
331
|
+
response = _a.sent();
|
|
332
|
+
return [2 /*return*/, new runtime.JSONApiResponse(response, function (jsonValue) { return (0, index_1.GovernanceClassificationFromJSON)(jsonValue); })];
|
|
333
|
+
}
|
|
334
|
+
});
|
|
335
|
+
});
|
|
336
|
+
};
|
|
337
|
+
/**
|
|
338
|
+
* Updates a classification
|
|
339
|
+
* Update classification
|
|
340
|
+
*/
|
|
341
|
+
GovernanceApi.prototype.updateClassification = function (requestParameters, initOverrides) {
|
|
342
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
343
|
+
var response;
|
|
344
|
+
return __generator(this, function (_a) {
|
|
345
|
+
switch (_a.label) {
|
|
346
|
+
case 0: return [4 /*yield*/, this.updateClassificationRaw(requestParameters, initOverrides)];
|
|
347
|
+
case 1:
|
|
348
|
+
response = _a.sent();
|
|
349
|
+
return [4 /*yield*/, response.value()];
|
|
350
|
+
case 2: return [2 /*return*/, _a.sent()];
|
|
351
|
+
}
|
|
352
|
+
});
|
|
353
|
+
});
|
|
354
|
+
};
|
|
355
|
+
return GovernanceApi;
|
|
356
|
+
}(runtime.BaseAPI));
|
|
357
|
+
exports.GovernanceApi = GovernanceApi;
|
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Cirro Data
|
|
3
|
+
* Cirro Data Platform service API
|
|
4
|
+
*
|
|
5
|
+
* The version of the OpenAPI document: latest
|
|
6
|
+
* Contact: support@cirro.bio
|
|
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 * as runtime from '../runtime';
|
|
13
|
+
import type { CreateResponse, ProjectRequest } from '../models/index';
|
|
14
|
+
export interface CreateProjectRequestRequest {
|
|
15
|
+
projectRequest: ProjectRequest;
|
|
16
|
+
}
|
|
17
|
+
/**
|
|
18
|
+
*
|
|
19
|
+
*/
|
|
20
|
+
export declare class ProjectRequestsApi extends runtime.BaseAPI {
|
|
21
|
+
/**
|
|
22
|
+
* Request a new project to be created
|
|
23
|
+
* Create project request
|
|
24
|
+
*/
|
|
25
|
+
createProjectRequestRaw(requestParameters: CreateProjectRequestRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<CreateResponse>>;
|
|
26
|
+
/**
|
|
27
|
+
* Request a new project to be created
|
|
28
|
+
* Create project request
|
|
29
|
+
*/
|
|
30
|
+
createProjectRequest(requestParameters: CreateProjectRequestRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<CreateResponse>;
|
|
31
|
+
}
|
|
@@ -0,0 +1,137 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
/* tslint:disable */
|
|
3
|
+
/* eslint-disable */
|
|
4
|
+
/**
|
|
5
|
+
* Cirro Data
|
|
6
|
+
* Cirro Data Platform service API
|
|
7
|
+
*
|
|
8
|
+
* The version of the OpenAPI document: latest
|
|
9
|
+
* Contact: support@cirro.bio
|
|
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
|
+
var __extends = (this && this.__extends) || (function () {
|
|
16
|
+
var extendStatics = function (d, b) {
|
|
17
|
+
extendStatics = Object.setPrototypeOf ||
|
|
18
|
+
({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
|
|
19
|
+
function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; };
|
|
20
|
+
return extendStatics(d, b);
|
|
21
|
+
};
|
|
22
|
+
return function (d, b) {
|
|
23
|
+
if (typeof b !== "function" && b !== null)
|
|
24
|
+
throw new TypeError("Class extends value " + String(b) + " is not a constructor or null");
|
|
25
|
+
extendStatics(d, b);
|
|
26
|
+
function __() { this.constructor = d; }
|
|
27
|
+
d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
|
|
28
|
+
};
|
|
29
|
+
})();
|
|
30
|
+
var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
|
|
31
|
+
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
|
|
32
|
+
return new (P || (P = Promise))(function (resolve, reject) {
|
|
33
|
+
function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
|
|
34
|
+
function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
|
|
35
|
+
function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
|
|
36
|
+
step((generator = generator.apply(thisArg, _arguments || [])).next());
|
|
37
|
+
});
|
|
38
|
+
};
|
|
39
|
+
var __generator = (this && this.__generator) || function (thisArg, body) {
|
|
40
|
+
var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g;
|
|
41
|
+
return g = { next: verb(0), "throw": verb(1), "return": verb(2) }, typeof Symbol === "function" && (g[Symbol.iterator] = function() { return this; }), g;
|
|
42
|
+
function verb(n) { return function (v) { return step([n, v]); }; }
|
|
43
|
+
function step(op) {
|
|
44
|
+
if (f) throw new TypeError("Generator is already executing.");
|
|
45
|
+
while (g && (g = 0, op[0] && (_ = 0)), _) try {
|
|
46
|
+
if (f = 1, y && (t = op[0] & 2 ? y["return"] : op[0] ? y["throw"] || ((t = y["return"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;
|
|
47
|
+
if (y = 0, t) op = [op[0] & 2, t.value];
|
|
48
|
+
switch (op[0]) {
|
|
49
|
+
case 0: case 1: t = op; break;
|
|
50
|
+
case 4: _.label++; return { value: op[1], done: false };
|
|
51
|
+
case 5: _.label++; y = op[1]; op = [0]; continue;
|
|
52
|
+
case 7: op = _.ops.pop(); _.trys.pop(); continue;
|
|
53
|
+
default:
|
|
54
|
+
if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; }
|
|
55
|
+
if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; }
|
|
56
|
+
if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; }
|
|
57
|
+
if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; }
|
|
58
|
+
if (t[2]) _.ops.pop();
|
|
59
|
+
_.trys.pop(); continue;
|
|
60
|
+
}
|
|
61
|
+
op = body.call(thisArg, _);
|
|
62
|
+
} catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; }
|
|
63
|
+
if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true };
|
|
64
|
+
}
|
|
65
|
+
};
|
|
66
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
67
|
+
exports.ProjectRequestsApi = void 0;
|
|
68
|
+
var runtime = require("../runtime");
|
|
69
|
+
var index_1 = require("../models/index");
|
|
70
|
+
/**
|
|
71
|
+
*
|
|
72
|
+
*/
|
|
73
|
+
var ProjectRequestsApi = /** @class */ (function (_super) {
|
|
74
|
+
__extends(ProjectRequestsApi, _super);
|
|
75
|
+
function ProjectRequestsApi() {
|
|
76
|
+
return _super !== null && _super.apply(this, arguments) || this;
|
|
77
|
+
}
|
|
78
|
+
/**
|
|
79
|
+
* Request a new project to be created
|
|
80
|
+
* Create project request
|
|
81
|
+
*/
|
|
82
|
+
ProjectRequestsApi.prototype.createProjectRequestRaw = function (requestParameters, initOverrides) {
|
|
83
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
84
|
+
var queryParameters, headerParameters, token, tokenString, response;
|
|
85
|
+
return __generator(this, function (_a) {
|
|
86
|
+
switch (_a.label) {
|
|
87
|
+
case 0:
|
|
88
|
+
if (requestParameters.projectRequest === null || requestParameters.projectRequest === undefined) {
|
|
89
|
+
throw new runtime.RequiredError('projectRequest', 'Required parameter requestParameters.projectRequest was null or undefined when calling createProjectRequest.');
|
|
90
|
+
}
|
|
91
|
+
queryParameters = {};
|
|
92
|
+
headerParameters = {};
|
|
93
|
+
headerParameters['Content-Type'] = 'application/json';
|
|
94
|
+
if (!(this.configuration && this.configuration.accessToken)) return [3 /*break*/, 2];
|
|
95
|
+
token = this.configuration.accessToken;
|
|
96
|
+
return [4 /*yield*/, token("accessToken", [])];
|
|
97
|
+
case 1:
|
|
98
|
+
tokenString = _a.sent();
|
|
99
|
+
if (tokenString) {
|
|
100
|
+
headerParameters["Authorization"] = "Bearer ".concat(tokenString);
|
|
101
|
+
}
|
|
102
|
+
_a.label = 2;
|
|
103
|
+
case 2: return [4 /*yield*/, this.request({
|
|
104
|
+
path: "/project-requests",
|
|
105
|
+
method: 'POST',
|
|
106
|
+
headers: headerParameters,
|
|
107
|
+
query: queryParameters,
|
|
108
|
+
body: (0, index_1.ProjectRequestToJSON)(requestParameters.projectRequest),
|
|
109
|
+
}, initOverrides)];
|
|
110
|
+
case 3:
|
|
111
|
+
response = _a.sent();
|
|
112
|
+
return [2 /*return*/, new runtime.JSONApiResponse(response, function (jsonValue) { return (0, index_1.CreateResponseFromJSON)(jsonValue); })];
|
|
113
|
+
}
|
|
114
|
+
});
|
|
115
|
+
});
|
|
116
|
+
};
|
|
117
|
+
/**
|
|
118
|
+
* Request a new project to be created
|
|
119
|
+
* Create project request
|
|
120
|
+
*/
|
|
121
|
+
ProjectRequestsApi.prototype.createProjectRequest = function (requestParameters, initOverrides) {
|
|
122
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
123
|
+
var response;
|
|
124
|
+
return __generator(this, function (_a) {
|
|
125
|
+
switch (_a.label) {
|
|
126
|
+
case 0: return [4 /*yield*/, this.createProjectRequestRaw(requestParameters, initOverrides)];
|
|
127
|
+
case 1:
|
|
128
|
+
response = _a.sent();
|
|
129
|
+
return [4 /*yield*/, response.value()];
|
|
130
|
+
case 2: return [2 /*return*/, _a.sent()];
|
|
131
|
+
}
|
|
132
|
+
});
|
|
133
|
+
});
|
|
134
|
+
};
|
|
135
|
+
return ProjectRequestsApi;
|
|
136
|
+
}(runtime.BaseAPI));
|
|
137
|
+
exports.ProjectRequestsApi = ProjectRequestsApi;
|