@lwshen/vault-hub-ts-fetch-client 0.0.1-beta.2
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 +35 -0
- package/.openapi-generator/VERSION +1 -0
- package/.openapi-generator-ignore +23 -0
- package/README.md +46 -0
- package/dist/apis/APIKeyApi.d.ts +64 -0
- package/dist/apis/APIKeyApi.js +270 -0
- package/dist/apis/AuditApi.d.ts +33 -0
- package/dist/apis/AuditApi.js +142 -0
- package/dist/apis/AuthApi.d.ts +48 -0
- package/dist/apis/AuthApi.js +211 -0
- package/dist/apis/CliApi.d.ts +48 -0
- package/dist/apis/CliApi.js +209 -0
- package/dist/apis/DefaultApi.d.ts +26 -0
- package/dist/apis/DefaultApi.js +121 -0
- package/dist/apis/UserApi.d.ts +26 -0
- package/dist/apis/UserApi.js +121 -0
- package/dist/apis/VaultApi.d.ts +71 -0
- package/dist/apis/VaultApi.js +302 -0
- package/dist/apis/index.d.ts +7 -0
- package/dist/apis/index.js +25 -0
- package/dist/index.d.ts +3 -0
- package/dist/index.js +21 -0
- package/dist/models/APIKeysResponse.d.ts +51 -0
- package/dist/models/APIKeysResponse.js +64 -0
- package/dist/models/AuditLog.d.ts +80 -0
- package/dist/models/AuditLog.js +81 -0
- package/dist/models/AuditLogsResponse.d.ts +51 -0
- package/dist/models/AuditLogsResponse.js +64 -0
- package/dist/models/CreateAPIKeyRequest.d.ts +44 -0
- package/dist/models/CreateAPIKeyRequest.js +55 -0
- package/dist/models/CreateAPIKeyResponse.d.ts +39 -0
- package/dist/models/CreateAPIKeyResponse.js +56 -0
- package/dist/models/CreateVaultRequest.d.ts +50 -0
- package/dist/models/CreateVaultRequest.js +59 -0
- package/dist/models/EnableClientEncryption.d.ts +25 -0
- package/dist/models/EnableClientEncryption.js +51 -0
- package/dist/models/GetUserResponse.d.ts +44 -0
- package/dist/models/GetUserResponse.js +55 -0
- package/dist/models/HealthCheckResponse.d.ts +38 -0
- package/dist/models/HealthCheckResponse.js +51 -0
- package/dist/models/LoginRequest.d.ts +38 -0
- package/dist/models/LoginRequest.js +55 -0
- package/dist/models/LoginResponse.d.ts +32 -0
- package/dist/models/LoginResponse.js +51 -0
- package/dist/models/SignupRequest.d.ts +44 -0
- package/dist/models/SignupRequest.js +59 -0
- package/dist/models/SignupResponse.d.ts +32 -0
- package/dist/models/SignupResponse.js +51 -0
- package/dist/models/UpdateAPIKeyRequest.d.ts +50 -0
- package/dist/models/UpdateAPIKeyRequest.js +55 -0
- package/dist/models/UpdateVaultRequest.d.ts +50 -0
- package/dist/models/UpdateVaultRequest.js +55 -0
- package/dist/models/Vault.d.ts +74 -0
- package/dist/models/Vault.js +69 -0
- package/dist/models/VaultAPIKey.d.ts +75 -0
- package/dist/models/VaultAPIKey.js +72 -0
- package/dist/models/VaultLite.d.ts +56 -0
- package/dist/models/VaultLite.js +61 -0
- package/dist/models/index.d.ts +18 -0
- package/dist/models/index.js +36 -0
- package/dist/runtime.d.ts +184 -0
- package/dist/runtime.js +564 -0
- package/package.json +19 -0
- package/src/apis/APIKeyApi.ts +219 -0
- package/src/apis/AuditApi.ts +98 -0
- package/src/apis/AuthApi.ts +144 -0
- package/src/apis/CliApi.ts +133 -0
- package/src/apis/DefaultApi.ts +56 -0
- package/src/apis/UserApi.ts +56 -0
- package/src/apis/VaultApi.ts +226 -0
- package/src/apis/index.ts +9 -0
- package/src/index.ts +5 -0
- package/src/models/APIKeysResponse.ts +101 -0
- package/src/models/AuditLog.ts +141 -0
- package/src/models/AuditLogsResponse.ts +101 -0
- package/src/models/CreateAPIKeyRequest.ts +82 -0
- package/src/models/CreateAPIKeyResponse.ts +83 -0
- package/src/models/CreateVaultRequest.ts +91 -0
- package/src/models/EnableClientEncryption.ts +53 -0
- package/src/models/GetUserResponse.ts +82 -0
- package/src/models/HealthCheckResponse.ts +73 -0
- package/src/models/LoginRequest.ts +75 -0
- package/src/models/LoginResponse.ts +66 -0
- package/src/models/SignupRequest.ts +84 -0
- package/src/models/SignupResponse.ts +66 -0
- package/src/models/UpdateAPIKeyRequest.ts +89 -0
- package/src/models/UpdateVaultRequest.ts +89 -0
- package/src/models/Vault.ts +124 -0
- package/src/models/VaultAPIKey.ts +133 -0
- package/src/models/VaultLite.ts +99 -0
- package/src/models/index.ts +20 -0
- package/src/runtime.ts +432 -0
- package/tsconfig.json +20 -0
|
@@ -0,0 +1,66 @@
|
|
|
1
|
+
/* tslint:disable */
|
|
2
|
+
/* eslint-disable */
|
|
3
|
+
/**
|
|
4
|
+
* Vault Hub Server
|
|
5
|
+
* No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
|
|
6
|
+
*
|
|
7
|
+
* The version of the OpenAPI document: 1.0.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
|
+
*
|
|
18
|
+
* @export
|
|
19
|
+
* @interface SignupResponse
|
|
20
|
+
*/
|
|
21
|
+
export interface SignupResponse {
|
|
22
|
+
/**
|
|
23
|
+
*
|
|
24
|
+
* @type {string}
|
|
25
|
+
* @memberof SignupResponse
|
|
26
|
+
*/
|
|
27
|
+
token: string;
|
|
28
|
+
}
|
|
29
|
+
|
|
30
|
+
/**
|
|
31
|
+
* Check if a given object implements the SignupResponse interface.
|
|
32
|
+
*/
|
|
33
|
+
export function instanceOfSignupResponse(value: object): value is SignupResponse {
|
|
34
|
+
if (!('token' in value) || value['token'] === undefined) return false;
|
|
35
|
+
return true;
|
|
36
|
+
}
|
|
37
|
+
|
|
38
|
+
export function SignupResponseFromJSON(json: any): SignupResponse {
|
|
39
|
+
return SignupResponseFromJSONTyped(json, false);
|
|
40
|
+
}
|
|
41
|
+
|
|
42
|
+
export function SignupResponseFromJSONTyped(json: any, ignoreDiscriminator: boolean): SignupResponse {
|
|
43
|
+
if (json == null) {
|
|
44
|
+
return json;
|
|
45
|
+
}
|
|
46
|
+
return {
|
|
47
|
+
|
|
48
|
+
'token': json['token'],
|
|
49
|
+
};
|
|
50
|
+
}
|
|
51
|
+
|
|
52
|
+
export function SignupResponseToJSON(json: any): SignupResponse {
|
|
53
|
+
return SignupResponseToJSONTyped(json, false);
|
|
54
|
+
}
|
|
55
|
+
|
|
56
|
+
export function SignupResponseToJSONTyped(value?: SignupResponse | null, ignoreDiscriminator: boolean = false): any {
|
|
57
|
+
if (value == null) {
|
|
58
|
+
return value;
|
|
59
|
+
}
|
|
60
|
+
|
|
61
|
+
return {
|
|
62
|
+
|
|
63
|
+
'token': value['token'],
|
|
64
|
+
};
|
|
65
|
+
}
|
|
66
|
+
|
|
@@ -0,0 +1,89 @@
|
|
|
1
|
+
/* tslint:disable */
|
|
2
|
+
/* eslint-disable */
|
|
3
|
+
/**
|
|
4
|
+
* Vault Hub Server
|
|
5
|
+
* No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
|
|
6
|
+
*
|
|
7
|
+
* The version of the OpenAPI document: 1.0.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
|
+
*
|
|
18
|
+
* @export
|
|
19
|
+
* @interface UpdateAPIKeyRequest
|
|
20
|
+
*/
|
|
21
|
+
export interface UpdateAPIKeyRequest {
|
|
22
|
+
/**
|
|
23
|
+
* Human-readable name for the API key
|
|
24
|
+
* @type {string}
|
|
25
|
+
* @memberof UpdateAPIKeyRequest
|
|
26
|
+
*/
|
|
27
|
+
name?: string;
|
|
28
|
+
/**
|
|
29
|
+
* Array of vault unique IDs this key can access (empty = all user's vaults)
|
|
30
|
+
* @type {Array<string>}
|
|
31
|
+
* @memberof UpdateAPIKeyRequest
|
|
32
|
+
*/
|
|
33
|
+
vaultUniqueIds?: Array<string>;
|
|
34
|
+
/**
|
|
35
|
+
* Optional expiration date
|
|
36
|
+
* @type {Date}
|
|
37
|
+
* @memberof UpdateAPIKeyRequest
|
|
38
|
+
*/
|
|
39
|
+
expiresAt?: Date;
|
|
40
|
+
/**
|
|
41
|
+
* Enable or disable the API key
|
|
42
|
+
* @type {boolean}
|
|
43
|
+
* @memberof UpdateAPIKeyRequest
|
|
44
|
+
*/
|
|
45
|
+
isActive?: boolean;
|
|
46
|
+
}
|
|
47
|
+
|
|
48
|
+
/**
|
|
49
|
+
* Check if a given object implements the UpdateAPIKeyRequest interface.
|
|
50
|
+
*/
|
|
51
|
+
export function instanceOfUpdateAPIKeyRequest(value: object): value is UpdateAPIKeyRequest {
|
|
52
|
+
return true;
|
|
53
|
+
}
|
|
54
|
+
|
|
55
|
+
export function UpdateAPIKeyRequestFromJSON(json: any): UpdateAPIKeyRequest {
|
|
56
|
+
return UpdateAPIKeyRequestFromJSONTyped(json, false);
|
|
57
|
+
}
|
|
58
|
+
|
|
59
|
+
export function UpdateAPIKeyRequestFromJSONTyped(json: any, ignoreDiscriminator: boolean): UpdateAPIKeyRequest {
|
|
60
|
+
if (json == null) {
|
|
61
|
+
return json;
|
|
62
|
+
}
|
|
63
|
+
return {
|
|
64
|
+
|
|
65
|
+
'name': json['name'] == null ? undefined : json['name'],
|
|
66
|
+
'vaultUniqueIds': json['vaultUniqueIds'] == null ? undefined : json['vaultUniqueIds'],
|
|
67
|
+
'expiresAt': json['expiresAt'] == null ? undefined : (new Date(json['expiresAt'])),
|
|
68
|
+
'isActive': json['isActive'] == null ? undefined : json['isActive'],
|
|
69
|
+
};
|
|
70
|
+
}
|
|
71
|
+
|
|
72
|
+
export function UpdateAPIKeyRequestToJSON(json: any): UpdateAPIKeyRequest {
|
|
73
|
+
return UpdateAPIKeyRequestToJSONTyped(json, false);
|
|
74
|
+
}
|
|
75
|
+
|
|
76
|
+
export function UpdateAPIKeyRequestToJSONTyped(value?: UpdateAPIKeyRequest | null, ignoreDiscriminator: boolean = false): any {
|
|
77
|
+
if (value == null) {
|
|
78
|
+
return value;
|
|
79
|
+
}
|
|
80
|
+
|
|
81
|
+
return {
|
|
82
|
+
|
|
83
|
+
'name': value['name'],
|
|
84
|
+
'vaultUniqueIds': value['vaultUniqueIds'],
|
|
85
|
+
'expiresAt': value['expiresAt'] == null ? undefined : ((value['expiresAt']).toISOString()),
|
|
86
|
+
'isActive': value['isActive'],
|
|
87
|
+
};
|
|
88
|
+
}
|
|
89
|
+
|
|
@@ -0,0 +1,89 @@
|
|
|
1
|
+
/* tslint:disable */
|
|
2
|
+
/* eslint-disable */
|
|
3
|
+
/**
|
|
4
|
+
* Vault Hub Server
|
|
5
|
+
* No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
|
|
6
|
+
*
|
|
7
|
+
* The version of the OpenAPI document: 1.0.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
|
+
*
|
|
18
|
+
* @export
|
|
19
|
+
* @interface UpdateVaultRequest
|
|
20
|
+
*/
|
|
21
|
+
export interface UpdateVaultRequest {
|
|
22
|
+
/**
|
|
23
|
+
* Human-readable name
|
|
24
|
+
* @type {string}
|
|
25
|
+
* @memberof UpdateVaultRequest
|
|
26
|
+
*/
|
|
27
|
+
name?: string;
|
|
28
|
+
/**
|
|
29
|
+
* Value to be encrypted and stored
|
|
30
|
+
* @type {string}
|
|
31
|
+
* @memberof UpdateVaultRequest
|
|
32
|
+
*/
|
|
33
|
+
value?: string;
|
|
34
|
+
/**
|
|
35
|
+
* Human-readable description
|
|
36
|
+
* @type {string}
|
|
37
|
+
* @memberof UpdateVaultRequest
|
|
38
|
+
*/
|
|
39
|
+
description?: string;
|
|
40
|
+
/**
|
|
41
|
+
* Category/type of vault
|
|
42
|
+
* @type {string}
|
|
43
|
+
* @memberof UpdateVaultRequest
|
|
44
|
+
*/
|
|
45
|
+
category?: string;
|
|
46
|
+
}
|
|
47
|
+
|
|
48
|
+
/**
|
|
49
|
+
* Check if a given object implements the UpdateVaultRequest interface.
|
|
50
|
+
*/
|
|
51
|
+
export function instanceOfUpdateVaultRequest(value: object): value is UpdateVaultRequest {
|
|
52
|
+
return true;
|
|
53
|
+
}
|
|
54
|
+
|
|
55
|
+
export function UpdateVaultRequestFromJSON(json: any): UpdateVaultRequest {
|
|
56
|
+
return UpdateVaultRequestFromJSONTyped(json, false);
|
|
57
|
+
}
|
|
58
|
+
|
|
59
|
+
export function UpdateVaultRequestFromJSONTyped(json: any, ignoreDiscriminator: boolean): UpdateVaultRequest {
|
|
60
|
+
if (json == null) {
|
|
61
|
+
return json;
|
|
62
|
+
}
|
|
63
|
+
return {
|
|
64
|
+
|
|
65
|
+
'name': json['name'] == null ? undefined : json['name'],
|
|
66
|
+
'value': json['value'] == null ? undefined : json['value'],
|
|
67
|
+
'description': json['description'] == null ? undefined : json['description'],
|
|
68
|
+
'category': json['category'] == null ? undefined : json['category'],
|
|
69
|
+
};
|
|
70
|
+
}
|
|
71
|
+
|
|
72
|
+
export function UpdateVaultRequestToJSON(json: any): UpdateVaultRequest {
|
|
73
|
+
return UpdateVaultRequestToJSONTyped(json, false);
|
|
74
|
+
}
|
|
75
|
+
|
|
76
|
+
export function UpdateVaultRequestToJSONTyped(value?: UpdateVaultRequest | null, ignoreDiscriminator: boolean = false): any {
|
|
77
|
+
if (value == null) {
|
|
78
|
+
return value;
|
|
79
|
+
}
|
|
80
|
+
|
|
81
|
+
return {
|
|
82
|
+
|
|
83
|
+
'name': value['name'],
|
|
84
|
+
'value': value['value'],
|
|
85
|
+
'description': value['description'],
|
|
86
|
+
'category': value['category'],
|
|
87
|
+
};
|
|
88
|
+
}
|
|
89
|
+
|
|
@@ -0,0 +1,124 @@
|
|
|
1
|
+
/* tslint:disable */
|
|
2
|
+
/* eslint-disable */
|
|
3
|
+
/**
|
|
4
|
+
* Vault Hub Server
|
|
5
|
+
* No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
|
|
6
|
+
*
|
|
7
|
+
* The version of the OpenAPI document: 1.0.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
|
+
*
|
|
18
|
+
* @export
|
|
19
|
+
* @interface Vault
|
|
20
|
+
*/
|
|
21
|
+
export interface Vault {
|
|
22
|
+
/**
|
|
23
|
+
* Unique identifier for the vault
|
|
24
|
+
* @type {string}
|
|
25
|
+
* @memberof Vault
|
|
26
|
+
*/
|
|
27
|
+
uniqueId: string;
|
|
28
|
+
/**
|
|
29
|
+
* ID of the user who owns this vault
|
|
30
|
+
* @type {number}
|
|
31
|
+
* @memberof Vault
|
|
32
|
+
*/
|
|
33
|
+
userId?: number;
|
|
34
|
+
/**
|
|
35
|
+
* Human-readable name
|
|
36
|
+
* @type {string}
|
|
37
|
+
* @memberof Vault
|
|
38
|
+
*/
|
|
39
|
+
name: string;
|
|
40
|
+
/**
|
|
41
|
+
* Encrypted value
|
|
42
|
+
* @type {string}
|
|
43
|
+
* @memberof Vault
|
|
44
|
+
*/
|
|
45
|
+
value: string;
|
|
46
|
+
/**
|
|
47
|
+
* Human-readable description
|
|
48
|
+
* @type {string}
|
|
49
|
+
* @memberof Vault
|
|
50
|
+
*/
|
|
51
|
+
description?: string;
|
|
52
|
+
/**
|
|
53
|
+
* Category/type of vault
|
|
54
|
+
* @type {string}
|
|
55
|
+
* @memberof Vault
|
|
56
|
+
*/
|
|
57
|
+
category?: string;
|
|
58
|
+
/**
|
|
59
|
+
*
|
|
60
|
+
* @type {Date}
|
|
61
|
+
* @memberof Vault
|
|
62
|
+
*/
|
|
63
|
+
createdAt?: Date;
|
|
64
|
+
/**
|
|
65
|
+
*
|
|
66
|
+
* @type {Date}
|
|
67
|
+
* @memberof Vault
|
|
68
|
+
*/
|
|
69
|
+
updatedAt?: Date;
|
|
70
|
+
}
|
|
71
|
+
|
|
72
|
+
/**
|
|
73
|
+
* Check if a given object implements the Vault interface.
|
|
74
|
+
*/
|
|
75
|
+
export function instanceOfVault(value: object): value is Vault {
|
|
76
|
+
if (!('uniqueId' in value) || value['uniqueId'] === undefined) return false;
|
|
77
|
+
if (!('name' in value) || value['name'] === undefined) return false;
|
|
78
|
+
if (!('value' in value) || value['value'] === undefined) return false;
|
|
79
|
+
return true;
|
|
80
|
+
}
|
|
81
|
+
|
|
82
|
+
export function VaultFromJSON(json: any): Vault {
|
|
83
|
+
return VaultFromJSONTyped(json, false);
|
|
84
|
+
}
|
|
85
|
+
|
|
86
|
+
export function VaultFromJSONTyped(json: any, ignoreDiscriminator: boolean): Vault {
|
|
87
|
+
if (json == null) {
|
|
88
|
+
return json;
|
|
89
|
+
}
|
|
90
|
+
return {
|
|
91
|
+
|
|
92
|
+
'uniqueId': json['uniqueId'],
|
|
93
|
+
'userId': json['userId'] == null ? undefined : json['userId'],
|
|
94
|
+
'name': json['name'],
|
|
95
|
+
'value': json['value'],
|
|
96
|
+
'description': json['description'] == null ? undefined : json['description'],
|
|
97
|
+
'category': json['category'] == null ? undefined : json['category'],
|
|
98
|
+
'createdAt': json['createdAt'] == null ? undefined : (new Date(json['createdAt'])),
|
|
99
|
+
'updatedAt': json['updatedAt'] == null ? undefined : (new Date(json['updatedAt'])),
|
|
100
|
+
};
|
|
101
|
+
}
|
|
102
|
+
|
|
103
|
+
export function VaultToJSON(json: any): Vault {
|
|
104
|
+
return VaultToJSONTyped(json, false);
|
|
105
|
+
}
|
|
106
|
+
|
|
107
|
+
export function VaultToJSONTyped(value?: Vault | null, ignoreDiscriminator: boolean = false): any {
|
|
108
|
+
if (value == null) {
|
|
109
|
+
return value;
|
|
110
|
+
}
|
|
111
|
+
|
|
112
|
+
return {
|
|
113
|
+
|
|
114
|
+
'uniqueId': value['uniqueId'],
|
|
115
|
+
'userId': value['userId'],
|
|
116
|
+
'name': value['name'],
|
|
117
|
+
'value': value['value'],
|
|
118
|
+
'description': value['description'],
|
|
119
|
+
'category': value['category'],
|
|
120
|
+
'createdAt': value['createdAt'] == null ? undefined : ((value['createdAt']).toISOString()),
|
|
121
|
+
'updatedAt': value['updatedAt'] == null ? undefined : ((value['updatedAt']).toISOString()),
|
|
122
|
+
};
|
|
123
|
+
}
|
|
124
|
+
|
|
@@ -0,0 +1,133 @@
|
|
|
1
|
+
/* tslint:disable */
|
|
2
|
+
/* eslint-disable */
|
|
3
|
+
/**
|
|
4
|
+
* Vault Hub Server
|
|
5
|
+
* No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
|
|
6
|
+
*
|
|
7
|
+
* The version of the OpenAPI document: 1.0.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 { VaultLite } from './VaultLite';
|
|
17
|
+
import {
|
|
18
|
+
VaultLiteFromJSON,
|
|
19
|
+
VaultLiteFromJSONTyped,
|
|
20
|
+
VaultLiteToJSON,
|
|
21
|
+
VaultLiteToJSONTyped,
|
|
22
|
+
} from './VaultLite';
|
|
23
|
+
|
|
24
|
+
/**
|
|
25
|
+
*
|
|
26
|
+
* @export
|
|
27
|
+
* @interface VaultAPIKey
|
|
28
|
+
*/
|
|
29
|
+
export interface VaultAPIKey {
|
|
30
|
+
/**
|
|
31
|
+
* Unique API key ID
|
|
32
|
+
* @type {number}
|
|
33
|
+
* @memberof VaultAPIKey
|
|
34
|
+
*/
|
|
35
|
+
id: number;
|
|
36
|
+
/**
|
|
37
|
+
* Human-readable name for the API key
|
|
38
|
+
* @type {string}
|
|
39
|
+
* @memberof VaultAPIKey
|
|
40
|
+
*/
|
|
41
|
+
name: string;
|
|
42
|
+
/**
|
|
43
|
+
* Array of vaults this key can access (null/empty = all user's vaults)
|
|
44
|
+
* @type {Array<VaultLite>}
|
|
45
|
+
* @memberof VaultAPIKey
|
|
46
|
+
*/
|
|
47
|
+
vaults?: Array<VaultLite>;
|
|
48
|
+
/**
|
|
49
|
+
* Optional expiration date
|
|
50
|
+
* @type {Date}
|
|
51
|
+
* @memberof VaultAPIKey
|
|
52
|
+
*/
|
|
53
|
+
expiresAt?: Date;
|
|
54
|
+
/**
|
|
55
|
+
* When the key was last used
|
|
56
|
+
* @type {Date}
|
|
57
|
+
* @memberof VaultAPIKey
|
|
58
|
+
*/
|
|
59
|
+
lastUsedAt?: Date;
|
|
60
|
+
/**
|
|
61
|
+
* Whether the key is currently active
|
|
62
|
+
* @type {boolean}
|
|
63
|
+
* @memberof VaultAPIKey
|
|
64
|
+
*/
|
|
65
|
+
isActive: boolean;
|
|
66
|
+
/**
|
|
67
|
+
* When the key was created
|
|
68
|
+
* @type {Date}
|
|
69
|
+
* @memberof VaultAPIKey
|
|
70
|
+
*/
|
|
71
|
+
createdAt: Date;
|
|
72
|
+
/**
|
|
73
|
+
* When the key was last updated
|
|
74
|
+
* @type {Date}
|
|
75
|
+
* @memberof VaultAPIKey
|
|
76
|
+
*/
|
|
77
|
+
updatedAt?: Date;
|
|
78
|
+
}
|
|
79
|
+
|
|
80
|
+
/**
|
|
81
|
+
* Check if a given object implements the VaultAPIKey interface.
|
|
82
|
+
*/
|
|
83
|
+
export function instanceOfVaultAPIKey(value: object): value is VaultAPIKey {
|
|
84
|
+
if (!('id' in value) || value['id'] === undefined) return false;
|
|
85
|
+
if (!('name' in value) || value['name'] === undefined) return false;
|
|
86
|
+
if (!('isActive' in value) || value['isActive'] === undefined) return false;
|
|
87
|
+
if (!('createdAt' in value) || value['createdAt'] === undefined) return false;
|
|
88
|
+
return true;
|
|
89
|
+
}
|
|
90
|
+
|
|
91
|
+
export function VaultAPIKeyFromJSON(json: any): VaultAPIKey {
|
|
92
|
+
return VaultAPIKeyFromJSONTyped(json, false);
|
|
93
|
+
}
|
|
94
|
+
|
|
95
|
+
export function VaultAPIKeyFromJSONTyped(json: any, ignoreDiscriminator: boolean): VaultAPIKey {
|
|
96
|
+
if (json == null) {
|
|
97
|
+
return json;
|
|
98
|
+
}
|
|
99
|
+
return {
|
|
100
|
+
|
|
101
|
+
'id': json['id'],
|
|
102
|
+
'name': json['name'],
|
|
103
|
+
'vaults': json['vaults'] == null ? undefined : ((json['vaults'] as Array<any>).map(VaultLiteFromJSON)),
|
|
104
|
+
'expiresAt': json['expiresAt'] == null ? undefined : (new Date(json['expiresAt'])),
|
|
105
|
+
'lastUsedAt': json['lastUsedAt'] == null ? undefined : (new Date(json['lastUsedAt'])),
|
|
106
|
+
'isActive': json['isActive'],
|
|
107
|
+
'createdAt': (new Date(json['createdAt'])),
|
|
108
|
+
'updatedAt': json['updatedAt'] == null ? undefined : (new Date(json['updatedAt'])),
|
|
109
|
+
};
|
|
110
|
+
}
|
|
111
|
+
|
|
112
|
+
export function VaultAPIKeyToJSON(json: any): VaultAPIKey {
|
|
113
|
+
return VaultAPIKeyToJSONTyped(json, false);
|
|
114
|
+
}
|
|
115
|
+
|
|
116
|
+
export function VaultAPIKeyToJSONTyped(value?: VaultAPIKey | null, ignoreDiscriminator: boolean = false): any {
|
|
117
|
+
if (value == null) {
|
|
118
|
+
return value;
|
|
119
|
+
}
|
|
120
|
+
|
|
121
|
+
return {
|
|
122
|
+
|
|
123
|
+
'id': value['id'],
|
|
124
|
+
'name': value['name'],
|
|
125
|
+
'vaults': value['vaults'] == null ? undefined : ((value['vaults'] as Array<any>).map(VaultLiteToJSON)),
|
|
126
|
+
'expiresAt': value['expiresAt'] == null ? undefined : ((value['expiresAt']).toISOString()),
|
|
127
|
+
'lastUsedAt': value['lastUsedAt'] == null ? undefined : ((value['lastUsedAt']).toISOString()),
|
|
128
|
+
'isActive': value['isActive'],
|
|
129
|
+
'createdAt': ((value['createdAt']).toISOString()),
|
|
130
|
+
'updatedAt': value['updatedAt'] == null ? undefined : ((value['updatedAt']).toISOString()),
|
|
131
|
+
};
|
|
132
|
+
}
|
|
133
|
+
|
|
@@ -0,0 +1,99 @@
|
|
|
1
|
+
/* tslint:disable */
|
|
2
|
+
/* eslint-disable */
|
|
3
|
+
/**
|
|
4
|
+
* Vault Hub Server
|
|
5
|
+
* No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
|
|
6
|
+
*
|
|
7
|
+
* The version of the OpenAPI document: 1.0.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
|
+
*
|
|
18
|
+
* @export
|
|
19
|
+
* @interface VaultLite
|
|
20
|
+
*/
|
|
21
|
+
export interface VaultLite {
|
|
22
|
+
/**
|
|
23
|
+
* Unique identifier for the vault
|
|
24
|
+
* @type {string}
|
|
25
|
+
* @memberof VaultLite
|
|
26
|
+
*/
|
|
27
|
+
uniqueId: string;
|
|
28
|
+
/**
|
|
29
|
+
* Human-readable name
|
|
30
|
+
* @type {string}
|
|
31
|
+
* @memberof VaultLite
|
|
32
|
+
*/
|
|
33
|
+
name: string;
|
|
34
|
+
/**
|
|
35
|
+
* Human-readable description
|
|
36
|
+
* @type {string}
|
|
37
|
+
* @memberof VaultLite
|
|
38
|
+
*/
|
|
39
|
+
description?: string;
|
|
40
|
+
/**
|
|
41
|
+
* Category/type of vault
|
|
42
|
+
* @type {string}
|
|
43
|
+
* @memberof VaultLite
|
|
44
|
+
*/
|
|
45
|
+
category?: string;
|
|
46
|
+
/**
|
|
47
|
+
*
|
|
48
|
+
* @type {Date}
|
|
49
|
+
* @memberof VaultLite
|
|
50
|
+
*/
|
|
51
|
+
updatedAt?: Date;
|
|
52
|
+
}
|
|
53
|
+
|
|
54
|
+
/**
|
|
55
|
+
* Check if a given object implements the VaultLite interface.
|
|
56
|
+
*/
|
|
57
|
+
export function instanceOfVaultLite(value: object): value is VaultLite {
|
|
58
|
+
if (!('uniqueId' in value) || value['uniqueId'] === undefined) return false;
|
|
59
|
+
if (!('name' in value) || value['name'] === undefined) return false;
|
|
60
|
+
return true;
|
|
61
|
+
}
|
|
62
|
+
|
|
63
|
+
export function VaultLiteFromJSON(json: any): VaultLite {
|
|
64
|
+
return VaultLiteFromJSONTyped(json, false);
|
|
65
|
+
}
|
|
66
|
+
|
|
67
|
+
export function VaultLiteFromJSONTyped(json: any, ignoreDiscriminator: boolean): VaultLite {
|
|
68
|
+
if (json == null) {
|
|
69
|
+
return json;
|
|
70
|
+
}
|
|
71
|
+
return {
|
|
72
|
+
|
|
73
|
+
'uniqueId': json['uniqueId'],
|
|
74
|
+
'name': json['name'],
|
|
75
|
+
'description': json['description'] == null ? undefined : json['description'],
|
|
76
|
+
'category': json['category'] == null ? undefined : json['category'],
|
|
77
|
+
'updatedAt': json['updatedAt'] == null ? undefined : (new Date(json['updatedAt'])),
|
|
78
|
+
};
|
|
79
|
+
}
|
|
80
|
+
|
|
81
|
+
export function VaultLiteToJSON(json: any): VaultLite {
|
|
82
|
+
return VaultLiteToJSONTyped(json, false);
|
|
83
|
+
}
|
|
84
|
+
|
|
85
|
+
export function VaultLiteToJSONTyped(value?: VaultLite | null, ignoreDiscriminator: boolean = false): any {
|
|
86
|
+
if (value == null) {
|
|
87
|
+
return value;
|
|
88
|
+
}
|
|
89
|
+
|
|
90
|
+
return {
|
|
91
|
+
|
|
92
|
+
'uniqueId': value['uniqueId'],
|
|
93
|
+
'name': value['name'],
|
|
94
|
+
'description': value['description'],
|
|
95
|
+
'category': value['category'],
|
|
96
|
+
'updatedAt': value['updatedAt'] == null ? undefined : ((value['updatedAt']).toISOString()),
|
|
97
|
+
};
|
|
98
|
+
}
|
|
99
|
+
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
/* tslint:disable */
|
|
2
|
+
/* eslint-disable */
|
|
3
|
+
export * from './APIKeysResponse';
|
|
4
|
+
export * from './AuditLog';
|
|
5
|
+
export * from './AuditLogsResponse';
|
|
6
|
+
export * from './CreateAPIKeyRequest';
|
|
7
|
+
export * from './CreateAPIKeyResponse';
|
|
8
|
+
export * from './CreateVaultRequest';
|
|
9
|
+
export * from './EnableClientEncryption';
|
|
10
|
+
export * from './GetUserResponse';
|
|
11
|
+
export * from './HealthCheckResponse';
|
|
12
|
+
export * from './LoginRequest';
|
|
13
|
+
export * from './LoginResponse';
|
|
14
|
+
export * from './SignupRequest';
|
|
15
|
+
export * from './SignupResponse';
|
|
16
|
+
export * from './UpdateAPIKeyRequest';
|
|
17
|
+
export * from './UpdateVaultRequest';
|
|
18
|
+
export * from './Vault';
|
|
19
|
+
export * from './VaultAPIKey';
|
|
20
|
+
export * from './VaultLite';
|