@cirrobio/api-client 0.2.8 → 0.2.10
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 +7 -2
- package/README.md +1 -1
- package/dist/apis/FileApi.d.ts +3 -3
- package/dist/apis/FileApi.js +6 -6
- package/dist/apis/GovernanceApi.d.ts +29 -1
- package/dist/apis/GovernanceApi.js +118 -0
- package/dist/models/FulfillmentResponse.d.ts +37 -0
- package/dist/models/FulfillmentResponse.js +53 -0
- package/dist/models/GovernanceAccessType.d.ts +25 -0
- package/dist/models/GovernanceAccessType.js +40 -0
- package/dist/models/GovernanceFileAccessRequest.d.ts +44 -0
- package/dist/models/GovernanceFileAccessRequest.js +56 -0
- package/dist/models/GovernanceRequirement.d.ts +1 -1
- package/dist/models/GovernanceRequirement.js +2 -2
- package/dist/models/{AccessType.d.ts → ProjectAccessType.d.ts} +5 -7
- package/dist/models/ProjectAccessType.js +41 -0
- package/dist/models/ProjectFileAccessRequest.d.ts +44 -0
- package/dist/models/{FileAccessRequest.js → ProjectFileAccessRequest.js} +14 -14
- package/dist/models/ProjectRequirement.d.ts +145 -0
- package/dist/models/ProjectRequirement.js +100 -0
- package/dist/models/RequirementFulfillmentInput.d.ts +31 -0
- package/dist/models/RequirementFulfillmentInput.js +50 -0
- package/dist/models/RequirementInput.d.ts +1 -1
- package/dist/models/RequirementInput.js +2 -2
- package/dist/models/index.d.ts +7 -2
- package/dist/models/index.js +7 -2
- package/package.json +1 -1
- package/src/apis/FileApi.ts +14 -11
- package/src/apis/GovernanceApi.ts +110 -0
- package/src/models/FulfillmentResponse.ts +75 -0
- package/src/models/GovernanceAccessType.ts +39 -0
- package/src/models/GovernanceFileAccessRequest.ts +89 -0
- package/src/models/GovernanceRequirement.ts +3 -3
- package/src/models/{AccessType.ts → ProjectAccessType.ts} +7 -9
- package/src/models/{FileAccessRequest.ts → ProjectFileAccessRequest.ts} +20 -20
- package/src/models/ProjectRequirement.ts +254 -0
- package/src/models/RequirementFulfillmentInput.ts +65 -0
- package/src/models/RequirementInput.ts +3 -3
- package/src/models/index.ts +7 -2
- package/dist/models/AccessType.js +0 -43
- package/dist/models/FileAccessRequest.d.ts +0 -44
package/src/apis/FileApi.ts
CHANGED
|
@@ -16,29 +16,32 @@
|
|
|
16
16
|
import * as runtime from '../runtime';
|
|
17
17
|
import type {
|
|
18
18
|
AWSCredentials,
|
|
19
|
-
FileAccessRequest,
|
|
20
19
|
GenerateSftpCredentialsRequest,
|
|
20
|
+
GovernanceFileAccessRequest,
|
|
21
|
+
ProjectFileAccessRequest,
|
|
21
22
|
SftpCredentials,
|
|
22
23
|
} from '../models/index';
|
|
23
24
|
import {
|
|
24
25
|
AWSCredentialsFromJSON,
|
|
25
26
|
AWSCredentialsToJSON,
|
|
26
|
-
FileAccessRequestFromJSON,
|
|
27
|
-
FileAccessRequestToJSON,
|
|
28
27
|
GenerateSftpCredentialsRequestFromJSON,
|
|
29
28
|
GenerateSftpCredentialsRequestToJSON,
|
|
29
|
+
GovernanceFileAccessRequestFromJSON,
|
|
30
|
+
GovernanceFileAccessRequestToJSON,
|
|
31
|
+
ProjectFileAccessRequestFromJSON,
|
|
32
|
+
ProjectFileAccessRequestToJSON,
|
|
30
33
|
SftpCredentialsFromJSON,
|
|
31
34
|
SftpCredentialsToJSON,
|
|
32
35
|
} from '../models/index';
|
|
33
36
|
|
|
34
37
|
export interface GenerateGovernanceFileAccessTokenRequest {
|
|
35
38
|
requirementId: string;
|
|
36
|
-
|
|
39
|
+
governanceFileAccessRequest: GovernanceFileAccessRequest;
|
|
37
40
|
}
|
|
38
41
|
|
|
39
42
|
export interface GenerateProjectFileAccessTokenRequest {
|
|
40
43
|
projectId: string;
|
|
41
|
-
|
|
44
|
+
projectFileAccessRequest: ProjectFileAccessRequest;
|
|
42
45
|
}
|
|
43
46
|
|
|
44
47
|
export interface GenerateProjectSftpTokenRequest {
|
|
@@ -60,8 +63,8 @@ export class FileApi extends runtime.BaseAPI {
|
|
|
60
63
|
throw new runtime.RequiredError('requirementId','Required parameter requestParameters.requirementId was null or undefined when calling generateGovernanceFileAccessToken.');
|
|
61
64
|
}
|
|
62
65
|
|
|
63
|
-
if (requestParameters.
|
|
64
|
-
throw new runtime.RequiredError('
|
|
66
|
+
if (requestParameters.governanceFileAccessRequest === null || requestParameters.governanceFileAccessRequest === undefined) {
|
|
67
|
+
throw new runtime.RequiredError('governanceFileAccessRequest','Required parameter requestParameters.governanceFileAccessRequest was null or undefined when calling generateGovernanceFileAccessToken.');
|
|
65
68
|
}
|
|
66
69
|
|
|
67
70
|
const queryParameters: any = {};
|
|
@@ -83,7 +86,7 @@ export class FileApi extends runtime.BaseAPI {
|
|
|
83
86
|
method: 'POST',
|
|
84
87
|
headers: headerParameters,
|
|
85
88
|
query: queryParameters,
|
|
86
|
-
body:
|
|
89
|
+
body: GovernanceFileAccessRequestToJSON(requestParameters.governanceFileAccessRequest),
|
|
87
90
|
}, initOverrides);
|
|
88
91
|
|
|
89
92
|
return new runtime.JSONApiResponse(response, (jsonValue) => AWSCredentialsFromJSON(jsonValue));
|
|
@@ -107,8 +110,8 @@ export class FileApi extends runtime.BaseAPI {
|
|
|
107
110
|
throw new runtime.RequiredError('projectId','Required parameter requestParameters.projectId was null or undefined when calling generateProjectFileAccessToken.');
|
|
108
111
|
}
|
|
109
112
|
|
|
110
|
-
if (requestParameters.
|
|
111
|
-
throw new runtime.RequiredError('
|
|
113
|
+
if (requestParameters.projectFileAccessRequest === null || requestParameters.projectFileAccessRequest === undefined) {
|
|
114
|
+
throw new runtime.RequiredError('projectFileAccessRequest','Required parameter requestParameters.projectFileAccessRequest was null or undefined when calling generateProjectFileAccessToken.');
|
|
112
115
|
}
|
|
113
116
|
|
|
114
117
|
const queryParameters: any = {};
|
|
@@ -130,7 +133,7 @@ export class FileApi extends runtime.BaseAPI {
|
|
|
130
133
|
method: 'POST',
|
|
131
134
|
headers: headerParameters,
|
|
132
135
|
query: queryParameters,
|
|
133
|
-
body:
|
|
136
|
+
body: ProjectFileAccessRequestToJSON(requestParameters.projectFileAccessRequest),
|
|
134
137
|
}, initOverrides);
|
|
135
138
|
|
|
136
139
|
return new runtime.JSONApiResponse(response, (jsonValue) => AWSCredentialsFromJSON(jsonValue));
|
|
@@ -17,9 +17,12 @@ import * as runtime from '../runtime';
|
|
|
17
17
|
import type {
|
|
18
18
|
ClassificationInput,
|
|
19
19
|
ContactInput,
|
|
20
|
+
FulfillmentResponse,
|
|
20
21
|
GovernanceClassification,
|
|
21
22
|
GovernanceContact,
|
|
22
23
|
GovernanceRequirement,
|
|
24
|
+
ProjectRequirement,
|
|
25
|
+
RequirementFulfillmentInput,
|
|
23
26
|
RequirementInput,
|
|
24
27
|
} from '../models/index';
|
|
25
28
|
import {
|
|
@@ -27,12 +30,18 @@ import {
|
|
|
27
30
|
ClassificationInputToJSON,
|
|
28
31
|
ContactInputFromJSON,
|
|
29
32
|
ContactInputToJSON,
|
|
33
|
+
FulfillmentResponseFromJSON,
|
|
34
|
+
FulfillmentResponseToJSON,
|
|
30
35
|
GovernanceClassificationFromJSON,
|
|
31
36
|
GovernanceClassificationToJSON,
|
|
32
37
|
GovernanceContactFromJSON,
|
|
33
38
|
GovernanceContactToJSON,
|
|
34
39
|
GovernanceRequirementFromJSON,
|
|
35
40
|
GovernanceRequirementToJSON,
|
|
41
|
+
ProjectRequirementFromJSON,
|
|
42
|
+
ProjectRequirementToJSON,
|
|
43
|
+
RequirementFulfillmentInputFromJSON,
|
|
44
|
+
RequirementFulfillmentInputToJSON,
|
|
36
45
|
RequirementInputFromJSON,
|
|
37
46
|
RequirementInputToJSON,
|
|
38
47
|
} from '../models/index';
|
|
@@ -61,6 +70,12 @@ export interface DeleteRequirementRequest {
|
|
|
61
70
|
requirementId: string;
|
|
62
71
|
}
|
|
63
72
|
|
|
73
|
+
export interface FulfillRequirementRequest {
|
|
74
|
+
projectId: string;
|
|
75
|
+
requirementId: string;
|
|
76
|
+
requirementFulfillmentInput: RequirementFulfillmentInput;
|
|
77
|
+
}
|
|
78
|
+
|
|
64
79
|
export interface GetClassificationRequest {
|
|
65
80
|
classificationId: string;
|
|
66
81
|
}
|
|
@@ -73,6 +88,10 @@ export interface GetRequirementRequest {
|
|
|
73
88
|
requirementId: string;
|
|
74
89
|
}
|
|
75
90
|
|
|
91
|
+
export interface GetRequirementsByProjectRequest {
|
|
92
|
+
projectId: string;
|
|
93
|
+
}
|
|
94
|
+
|
|
76
95
|
export interface UpdateClassificationRequest {
|
|
77
96
|
classificationId: string;
|
|
78
97
|
classificationInput: ClassificationInput;
|
|
@@ -339,6 +358,57 @@ export class GovernanceApi extends runtime.BaseAPI {
|
|
|
339
358
|
await this.deleteRequirementRaw(requestParameters, initOverrides);
|
|
340
359
|
}
|
|
341
360
|
|
|
361
|
+
/**
|
|
362
|
+
* Saves a record of the fulfillment of a governance requirement
|
|
363
|
+
* Fulfill a project\'s requirement
|
|
364
|
+
*/
|
|
365
|
+
async fulfillRequirementRaw(requestParameters: FulfillRequirementRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<FulfillmentResponse>> {
|
|
366
|
+
if (requestParameters.projectId === null || requestParameters.projectId === undefined) {
|
|
367
|
+
throw new runtime.RequiredError('projectId','Required parameter requestParameters.projectId was null or undefined when calling fulfillRequirement.');
|
|
368
|
+
}
|
|
369
|
+
|
|
370
|
+
if (requestParameters.requirementId === null || requestParameters.requirementId === undefined) {
|
|
371
|
+
throw new runtime.RequiredError('requirementId','Required parameter requestParameters.requirementId was null or undefined when calling fulfillRequirement.');
|
|
372
|
+
}
|
|
373
|
+
|
|
374
|
+
if (requestParameters.requirementFulfillmentInput === null || requestParameters.requirementFulfillmentInput === undefined) {
|
|
375
|
+
throw new runtime.RequiredError('requirementFulfillmentInput','Required parameter requestParameters.requirementFulfillmentInput was null or undefined when calling fulfillRequirement.');
|
|
376
|
+
}
|
|
377
|
+
|
|
378
|
+
const queryParameters: any = {};
|
|
379
|
+
|
|
380
|
+
const headerParameters: runtime.HTTPHeaders = {};
|
|
381
|
+
|
|
382
|
+
headerParameters['Content-Type'] = 'application/json';
|
|
383
|
+
|
|
384
|
+
if (this.configuration && this.configuration.accessToken) {
|
|
385
|
+
const token = this.configuration.accessToken;
|
|
386
|
+
const tokenString = await token("accessToken", []);
|
|
387
|
+
|
|
388
|
+
if (tokenString) {
|
|
389
|
+
headerParameters["Authorization"] = `Bearer ${tokenString}`;
|
|
390
|
+
}
|
|
391
|
+
}
|
|
392
|
+
const response = await this.request({
|
|
393
|
+
path: `/governance/projects/{projectId}/requirements/{requirementId}:fulfill`.replace(`{${"projectId"}}`, encodeURIComponent(String(requestParameters.projectId))).replace(`{${"requirementId"}}`, encodeURIComponent(String(requestParameters.requirementId))),
|
|
394
|
+
method: 'POST',
|
|
395
|
+
headers: headerParameters,
|
|
396
|
+
query: queryParameters,
|
|
397
|
+
body: RequirementFulfillmentInputToJSON(requestParameters.requirementFulfillmentInput),
|
|
398
|
+
}, initOverrides);
|
|
399
|
+
|
|
400
|
+
return new runtime.JSONApiResponse(response, (jsonValue) => FulfillmentResponseFromJSON(jsonValue));
|
|
401
|
+
}
|
|
402
|
+
|
|
403
|
+
/**
|
|
404
|
+
* Saves a record of the fulfillment of a governance requirement
|
|
405
|
+
* Fulfill a project\'s requirement
|
|
406
|
+
*/
|
|
407
|
+
async fulfillRequirement(requestParameters: FulfillRequirementRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<FulfillmentResponse> {
|
|
408
|
+
const response = await this.fulfillRequirementRaw(requestParameters, initOverrides);
|
|
409
|
+
return await response.value();
|
|
410
|
+
}
|
|
411
|
+
|
|
342
412
|
/**
|
|
343
413
|
* Retrieve a data classification
|
|
344
414
|
* Get a classification
|
|
@@ -567,6 +637,46 @@ export class GovernanceApi extends runtime.BaseAPI {
|
|
|
567
637
|
return await response.value();
|
|
568
638
|
}
|
|
569
639
|
|
|
640
|
+
/**
|
|
641
|
+
* Retrieve governance requirements for a project with fulfillment information for the current user
|
|
642
|
+
* Get project requirements
|
|
643
|
+
*/
|
|
644
|
+
async getRequirementsByProjectRaw(requestParameters: GetRequirementsByProjectRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<Array<ProjectRequirement>>> {
|
|
645
|
+
if (requestParameters.projectId === null || requestParameters.projectId === undefined) {
|
|
646
|
+
throw new runtime.RequiredError('projectId','Required parameter requestParameters.projectId was null or undefined when calling getRequirementsByProject.');
|
|
647
|
+
}
|
|
648
|
+
|
|
649
|
+
const queryParameters: any = {};
|
|
650
|
+
|
|
651
|
+
const headerParameters: runtime.HTTPHeaders = {};
|
|
652
|
+
|
|
653
|
+
if (this.configuration && this.configuration.accessToken) {
|
|
654
|
+
const token = this.configuration.accessToken;
|
|
655
|
+
const tokenString = await token("accessToken", []);
|
|
656
|
+
|
|
657
|
+
if (tokenString) {
|
|
658
|
+
headerParameters["Authorization"] = `Bearer ${tokenString}`;
|
|
659
|
+
}
|
|
660
|
+
}
|
|
661
|
+
const response = await this.request({
|
|
662
|
+
path: `/governance/projects/{projectId}/requirements`.replace(`{${"projectId"}}`, encodeURIComponent(String(requestParameters.projectId))),
|
|
663
|
+
method: 'GET',
|
|
664
|
+
headers: headerParameters,
|
|
665
|
+
query: queryParameters,
|
|
666
|
+
}, initOverrides);
|
|
667
|
+
|
|
668
|
+
return new runtime.JSONApiResponse(response, (jsonValue) => jsonValue.map(ProjectRequirementFromJSON));
|
|
669
|
+
}
|
|
670
|
+
|
|
671
|
+
/**
|
|
672
|
+
* Retrieve governance requirements for a project with fulfillment information for the current user
|
|
673
|
+
* Get project requirements
|
|
674
|
+
*/
|
|
675
|
+
async getRequirementsByProject(requestParameters: GetRequirementsByProjectRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<Array<ProjectRequirement>> {
|
|
676
|
+
const response = await this.getRequirementsByProjectRaw(requestParameters, initOverrides);
|
|
677
|
+
return await response.value();
|
|
678
|
+
}
|
|
679
|
+
|
|
570
680
|
/**
|
|
571
681
|
* Updates a classification
|
|
572
682
|
* Update classification
|
|
@@ -0,0 +1,75 @@
|
|
|
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
|
+
import { exists, mapValues } from '../runtime';
|
|
16
|
+
/**
|
|
17
|
+
*
|
|
18
|
+
* @export
|
|
19
|
+
* @interface FulfillmentResponse
|
|
20
|
+
*/
|
|
21
|
+
export interface FulfillmentResponse {
|
|
22
|
+
/**
|
|
23
|
+
*
|
|
24
|
+
* @type {string}
|
|
25
|
+
* @memberof FulfillmentResponse
|
|
26
|
+
*/
|
|
27
|
+
fulfillmentId: string;
|
|
28
|
+
/**
|
|
29
|
+
*
|
|
30
|
+
* @type {string}
|
|
31
|
+
* @memberof FulfillmentResponse
|
|
32
|
+
*/
|
|
33
|
+
path: string;
|
|
34
|
+
}
|
|
35
|
+
|
|
36
|
+
/**
|
|
37
|
+
* Check if a given object implements the FulfillmentResponse interface.
|
|
38
|
+
*/
|
|
39
|
+
export function instanceOfFulfillmentResponse(value: object): boolean {
|
|
40
|
+
let isInstance = true;
|
|
41
|
+
isInstance = isInstance && "fulfillmentId" in value;
|
|
42
|
+
isInstance = isInstance && "path" in value;
|
|
43
|
+
|
|
44
|
+
return isInstance;
|
|
45
|
+
}
|
|
46
|
+
|
|
47
|
+
export function FulfillmentResponseFromJSON(json: any): FulfillmentResponse {
|
|
48
|
+
return FulfillmentResponseFromJSONTyped(json, false);
|
|
49
|
+
}
|
|
50
|
+
|
|
51
|
+
export function FulfillmentResponseFromJSONTyped(json: any, ignoreDiscriminator: boolean): FulfillmentResponse {
|
|
52
|
+
if ((json === undefined) || (json === null)) {
|
|
53
|
+
return json;
|
|
54
|
+
}
|
|
55
|
+
return {
|
|
56
|
+
|
|
57
|
+
'fulfillmentId': json['fulfillmentId'],
|
|
58
|
+
'path': json['path'],
|
|
59
|
+
};
|
|
60
|
+
}
|
|
61
|
+
|
|
62
|
+
export function FulfillmentResponseToJSON(value?: FulfillmentResponse | null): any {
|
|
63
|
+
if (value === undefined) {
|
|
64
|
+
return undefined;
|
|
65
|
+
}
|
|
66
|
+
if (value === null) {
|
|
67
|
+
return null;
|
|
68
|
+
}
|
|
69
|
+
return {
|
|
70
|
+
|
|
71
|
+
'fulfillmentId': value.fulfillmentId,
|
|
72
|
+
'path': value.path,
|
|
73
|
+
};
|
|
74
|
+
}
|
|
75
|
+
|
|
@@ -0,0 +1,39 @@
|
|
|
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
|
+
*
|
|
17
|
+
* @export
|
|
18
|
+
* @enum {string}
|
|
19
|
+
*/
|
|
20
|
+
export enum GovernanceAccessType {
|
|
21
|
+
GovernanceUpload = 'GOVERNANCE_UPLOAD',
|
|
22
|
+
GovernanceDownload = 'GOVERNANCE_DOWNLOAD',
|
|
23
|
+
FulfillmentUpload = 'FULFILLMENT_UPLOAD',
|
|
24
|
+
FulfillmentDownload = 'FULFILLMENT_DOWNLOAD'
|
|
25
|
+
}
|
|
26
|
+
|
|
27
|
+
|
|
28
|
+
export function GovernanceAccessTypeFromJSON(json: any): GovernanceAccessType {
|
|
29
|
+
return GovernanceAccessTypeFromJSONTyped(json, false);
|
|
30
|
+
}
|
|
31
|
+
|
|
32
|
+
export function GovernanceAccessTypeFromJSONTyped(json: any, ignoreDiscriminator: boolean): GovernanceAccessType {
|
|
33
|
+
return json as GovernanceAccessType;
|
|
34
|
+
}
|
|
35
|
+
|
|
36
|
+
export function GovernanceAccessTypeToJSON(value?: GovernanceAccessType | null): any {
|
|
37
|
+
return value as any;
|
|
38
|
+
}
|
|
39
|
+
|
|
@@ -0,0 +1,89 @@
|
|
|
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
|
+
import { exists, mapValues } from '../runtime';
|
|
16
|
+
import type { GovernanceAccessType } from './GovernanceAccessType';
|
|
17
|
+
import {
|
|
18
|
+
GovernanceAccessTypeFromJSON,
|
|
19
|
+
GovernanceAccessTypeFromJSONTyped,
|
|
20
|
+
GovernanceAccessTypeToJSON,
|
|
21
|
+
} from './GovernanceAccessType';
|
|
22
|
+
|
|
23
|
+
/**
|
|
24
|
+
*
|
|
25
|
+
* @export
|
|
26
|
+
* @interface GovernanceFileAccessRequest
|
|
27
|
+
*/
|
|
28
|
+
export interface GovernanceFileAccessRequest {
|
|
29
|
+
/**
|
|
30
|
+
*
|
|
31
|
+
* @type {GovernanceAccessType}
|
|
32
|
+
* @memberof GovernanceFileAccessRequest
|
|
33
|
+
*/
|
|
34
|
+
accessType: GovernanceAccessType;
|
|
35
|
+
/**
|
|
36
|
+
*
|
|
37
|
+
* @type {string}
|
|
38
|
+
* @memberof GovernanceFileAccessRequest
|
|
39
|
+
*/
|
|
40
|
+
fulfillmentId?: string | null;
|
|
41
|
+
/**
|
|
42
|
+
*
|
|
43
|
+
* @type {number}
|
|
44
|
+
* @memberof GovernanceFileAccessRequest
|
|
45
|
+
*/
|
|
46
|
+
tokenLifetimeHours?: number | null;
|
|
47
|
+
}
|
|
48
|
+
|
|
49
|
+
/**
|
|
50
|
+
* Check if a given object implements the GovernanceFileAccessRequest interface.
|
|
51
|
+
*/
|
|
52
|
+
export function instanceOfGovernanceFileAccessRequest(value: object): boolean {
|
|
53
|
+
let isInstance = true;
|
|
54
|
+
isInstance = isInstance && "accessType" in value;
|
|
55
|
+
|
|
56
|
+
return isInstance;
|
|
57
|
+
}
|
|
58
|
+
|
|
59
|
+
export function GovernanceFileAccessRequestFromJSON(json: any): GovernanceFileAccessRequest {
|
|
60
|
+
return GovernanceFileAccessRequestFromJSONTyped(json, false);
|
|
61
|
+
}
|
|
62
|
+
|
|
63
|
+
export function GovernanceFileAccessRequestFromJSONTyped(json: any, ignoreDiscriminator: boolean): GovernanceFileAccessRequest {
|
|
64
|
+
if ((json === undefined) || (json === null)) {
|
|
65
|
+
return json;
|
|
66
|
+
}
|
|
67
|
+
return {
|
|
68
|
+
|
|
69
|
+
'accessType': GovernanceAccessTypeFromJSON(json['accessType']),
|
|
70
|
+
'fulfillmentId': !exists(json, 'fulfillmentId') ? undefined : json['fulfillmentId'],
|
|
71
|
+
'tokenLifetimeHours': !exists(json, 'tokenLifetimeHours') ? undefined : json['tokenLifetimeHours'],
|
|
72
|
+
};
|
|
73
|
+
}
|
|
74
|
+
|
|
75
|
+
export function GovernanceFileAccessRequestToJSON(value?: GovernanceFileAccessRequest | null): any {
|
|
76
|
+
if (value === undefined) {
|
|
77
|
+
return undefined;
|
|
78
|
+
}
|
|
79
|
+
if (value === null) {
|
|
80
|
+
return null;
|
|
81
|
+
}
|
|
82
|
+
return {
|
|
83
|
+
|
|
84
|
+
'accessType': GovernanceAccessTypeToJSON(value.accessType),
|
|
85
|
+
'fulfillmentId': value.fulfillmentId,
|
|
86
|
+
'tokenLifetimeHours': value.tokenLifetimeHours,
|
|
87
|
+
};
|
|
88
|
+
}
|
|
89
|
+
|
|
@@ -133,7 +133,7 @@ export interface GovernanceRequirement {
|
|
|
133
133
|
* @type {GovernanceTrainingVerification}
|
|
134
134
|
* @memberof GovernanceRequirement
|
|
135
135
|
*/
|
|
136
|
-
|
|
136
|
+
verificationMethod?: GovernanceTrainingVerification | null;
|
|
137
137
|
/**
|
|
138
138
|
*
|
|
139
139
|
* @type {string}
|
|
@@ -197,7 +197,7 @@ export function GovernanceRequirementFromJSONTyped(json: any, ignoreDiscriminato
|
|
|
197
197
|
'supplementalDocs': !exists(json, 'supplementalDocs') ? undefined : (json['supplementalDocs'] === null ? null : (json['supplementalDocs'] as Array<any>).map(GovernanceFileFromJSON)),
|
|
198
198
|
'file': !exists(json, 'file') ? undefined : GovernanceFileFromJSON(json['file']),
|
|
199
199
|
'authorship': !exists(json, 'authorship') ? undefined : GovernanceScopeFromJSON(json['authorship']),
|
|
200
|
-
'
|
|
200
|
+
'verificationMethod': !exists(json, 'verificationMethod') ? undefined : GovernanceTrainingVerificationFromJSON(json['verificationMethod']),
|
|
201
201
|
'createdBy': json['createdBy'],
|
|
202
202
|
'createdAt': (new Date(json['createdAt'])),
|
|
203
203
|
'updatedAt': (new Date(json['updatedAt'])),
|
|
@@ -226,7 +226,7 @@ export function GovernanceRequirementToJSON(value?: GovernanceRequirement | null
|
|
|
226
226
|
'supplementalDocs': value.supplementalDocs === undefined ? undefined : (value.supplementalDocs === null ? null : (value.supplementalDocs as Array<any>).map(GovernanceFileToJSON)),
|
|
227
227
|
'file': GovernanceFileToJSON(value.file),
|
|
228
228
|
'authorship': GovernanceScopeToJSON(value.authorship),
|
|
229
|
-
'
|
|
229
|
+
'verificationMethod': GovernanceTrainingVerificationToJSON(value.verificationMethod),
|
|
230
230
|
'createdBy': value.createdBy,
|
|
231
231
|
'createdAt': (value.createdAt.toISOString()),
|
|
232
232
|
'updatedAt': (value.updatedAt.toISOString()),
|
|
@@ -17,26 +17,24 @@
|
|
|
17
17
|
* @export
|
|
18
18
|
* @enum {string}
|
|
19
19
|
*/
|
|
20
|
-
export enum
|
|
20
|
+
export enum ProjectAccessType {
|
|
21
21
|
DatasetUpload = 'DATASET_UPLOAD',
|
|
22
22
|
SharedDatasetDownload = 'SHARED_DATASET_DOWNLOAD',
|
|
23
23
|
SamplesheetUpload = 'SAMPLESHEET_UPLOAD',
|
|
24
24
|
ReferenceUpload = 'REFERENCE_UPLOAD',
|
|
25
|
-
ProjectDownload = 'PROJECT_DOWNLOAD'
|
|
26
|
-
GovernanceUpload = 'GOVERNANCE_UPLOAD',
|
|
27
|
-
GovernanceDownload = 'GOVERNANCE_DOWNLOAD'
|
|
25
|
+
ProjectDownload = 'PROJECT_DOWNLOAD'
|
|
28
26
|
}
|
|
29
27
|
|
|
30
28
|
|
|
31
|
-
export function
|
|
32
|
-
return
|
|
29
|
+
export function ProjectAccessTypeFromJSON(json: any): ProjectAccessType {
|
|
30
|
+
return ProjectAccessTypeFromJSONTyped(json, false);
|
|
33
31
|
}
|
|
34
32
|
|
|
35
|
-
export function
|
|
36
|
-
return json as
|
|
33
|
+
export function ProjectAccessTypeFromJSONTyped(json: any, ignoreDiscriminator: boolean): ProjectAccessType {
|
|
34
|
+
return json as ProjectAccessType;
|
|
37
35
|
}
|
|
38
36
|
|
|
39
|
-
export function
|
|
37
|
+
export function ProjectAccessTypeToJSON(value?: ProjectAccessType | null): any {
|
|
40
38
|
return value as any;
|
|
41
39
|
}
|
|
42
40
|
|
|
@@ -13,66 +13,66 @@
|
|
|
13
13
|
*/
|
|
14
14
|
|
|
15
15
|
import { exists, mapValues } from '../runtime';
|
|
16
|
-
import type {
|
|
16
|
+
import type { ProjectAccessType } from './ProjectAccessType';
|
|
17
17
|
import {
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
} from './
|
|
18
|
+
ProjectAccessTypeFromJSON,
|
|
19
|
+
ProjectAccessTypeFromJSONTyped,
|
|
20
|
+
ProjectAccessTypeToJSON,
|
|
21
|
+
} from './ProjectAccessType';
|
|
22
22
|
|
|
23
23
|
/**
|
|
24
24
|
*
|
|
25
25
|
* @export
|
|
26
|
-
* @interface
|
|
26
|
+
* @interface ProjectFileAccessRequest
|
|
27
27
|
*/
|
|
28
|
-
export interface
|
|
28
|
+
export interface ProjectFileAccessRequest {
|
|
29
29
|
/**
|
|
30
30
|
*
|
|
31
|
-
* @type {
|
|
32
|
-
* @memberof
|
|
31
|
+
* @type {ProjectAccessType}
|
|
32
|
+
* @memberof ProjectFileAccessRequest
|
|
33
33
|
*/
|
|
34
|
-
accessType:
|
|
34
|
+
accessType: ProjectAccessType;
|
|
35
35
|
/**
|
|
36
36
|
*
|
|
37
37
|
* @type {string}
|
|
38
|
-
* @memberof
|
|
38
|
+
* @memberof ProjectFileAccessRequest
|
|
39
39
|
*/
|
|
40
40
|
datasetId?: string | null;
|
|
41
41
|
/**
|
|
42
42
|
*
|
|
43
43
|
* @type {number}
|
|
44
|
-
* @memberof
|
|
44
|
+
* @memberof ProjectFileAccessRequest
|
|
45
45
|
*/
|
|
46
46
|
tokenLifetimeHours?: number | null;
|
|
47
47
|
}
|
|
48
48
|
|
|
49
49
|
/**
|
|
50
|
-
* Check if a given object implements the
|
|
50
|
+
* Check if a given object implements the ProjectFileAccessRequest interface.
|
|
51
51
|
*/
|
|
52
|
-
export function
|
|
52
|
+
export function instanceOfProjectFileAccessRequest(value: object): boolean {
|
|
53
53
|
let isInstance = true;
|
|
54
54
|
isInstance = isInstance && "accessType" in value;
|
|
55
55
|
|
|
56
56
|
return isInstance;
|
|
57
57
|
}
|
|
58
58
|
|
|
59
|
-
export function
|
|
60
|
-
return
|
|
59
|
+
export function ProjectFileAccessRequestFromJSON(json: any): ProjectFileAccessRequest {
|
|
60
|
+
return ProjectFileAccessRequestFromJSONTyped(json, false);
|
|
61
61
|
}
|
|
62
62
|
|
|
63
|
-
export function
|
|
63
|
+
export function ProjectFileAccessRequestFromJSONTyped(json: any, ignoreDiscriminator: boolean): ProjectFileAccessRequest {
|
|
64
64
|
if ((json === undefined) || (json === null)) {
|
|
65
65
|
return json;
|
|
66
66
|
}
|
|
67
67
|
return {
|
|
68
68
|
|
|
69
|
-
'accessType':
|
|
69
|
+
'accessType': ProjectAccessTypeFromJSON(json['accessType']),
|
|
70
70
|
'datasetId': !exists(json, 'datasetId') ? undefined : json['datasetId'],
|
|
71
71
|
'tokenLifetimeHours': !exists(json, 'tokenLifetimeHours') ? undefined : json['tokenLifetimeHours'],
|
|
72
72
|
};
|
|
73
73
|
}
|
|
74
74
|
|
|
75
|
-
export function
|
|
75
|
+
export function ProjectFileAccessRequestToJSON(value?: ProjectFileAccessRequest | null): any {
|
|
76
76
|
if (value === undefined) {
|
|
77
77
|
return undefined;
|
|
78
78
|
}
|
|
@@ -81,7 +81,7 @@ export function FileAccessRequestToJSON(value?: FileAccessRequest | null): any {
|
|
|
81
81
|
}
|
|
82
82
|
return {
|
|
83
83
|
|
|
84
|
-
'accessType':
|
|
84
|
+
'accessType': ProjectAccessTypeToJSON(value.accessType),
|
|
85
85
|
'datasetId': value.datasetId,
|
|
86
86
|
'tokenLifetimeHours': value.tokenLifetimeHours,
|
|
87
87
|
};
|