@ibm-cloud/secrets-manager 0.0.4 → 0.1.1
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/auth/index.d.ts +2 -2
- package/auth/index.js +9 -9
- package/auth/index.js.map +1 -1
- package/lib/common.d.ts +3 -0
- package/lib/common.js +6 -2
- package/lib/common.js.map +1 -1
- package/package.json +22 -16
- package/readme.md +81 -29
- package/secrets-manager/v1.d.ts +1138 -0
- package/{ibm-cloud-secrets-manager-api → secrets-manager}/v1.js +184 -121
- package/secrets-manager/v1.js.map +1 -0
- package/ibm-cloud-secrets-manager-api/v1.d.ts +0 -842
- package/ibm-cloud-secrets-manager-api/v1.js.map +0 -1
|
@@ -1,842 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* (C) Copyright IBM Corp. 2020.
|
|
3
|
-
*
|
|
4
|
-
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
5
|
-
* you may not use this file except in compliance with the License.
|
|
6
|
-
* You may obtain a copy of the License at
|
|
7
|
-
*
|
|
8
|
-
* http://www.apache.org/licenses/LICENSE-2.0
|
|
9
|
-
*
|
|
10
|
-
* Unless required by applicable law or agreed to in writing, software
|
|
11
|
-
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
12
|
-
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
13
|
-
* See the License for the specific language governing permissions and
|
|
14
|
-
* limitations under the License.
|
|
15
|
-
*/
|
|
16
|
-
/// <reference types="node" />
|
|
17
|
-
import { IncomingHttpHeaders, OutgoingHttpHeaders } from 'http';
|
|
18
|
-
import { BaseService, UserOptions } from 'ibm-cloud-sdk-core';
|
|
19
|
-
/**
|
|
20
|
-
* No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
|
|
21
|
-
*/
|
|
22
|
-
declare class IbmCloudSecretsManagerApiV1 extends BaseService {
|
|
23
|
-
static DEFAULT_SERVICE_URL: string;
|
|
24
|
-
static DEFAULT_SERVICE_NAME: string;
|
|
25
|
-
/*************************
|
|
26
|
-
* Factory method
|
|
27
|
-
************************/
|
|
28
|
-
/**
|
|
29
|
-
* Constructs an instance of IbmCloudSecretsManagerApiV1 with passed in options and external configuration.
|
|
30
|
-
*
|
|
31
|
-
* @param {UserOptions} [options] - The parameters to send to the service.
|
|
32
|
-
* @param {string} [options.serviceName] - The name of the service to configure
|
|
33
|
-
* @param {Authenticator} [options.authenticator] - The Authenticator object used to authenticate requests to the service
|
|
34
|
-
* @param {string} [options.serviceUrl] - The URL for the service
|
|
35
|
-
* @returns {IbmCloudSecretsManagerApiV1}
|
|
36
|
-
*/
|
|
37
|
-
static newInstance(options: UserOptions): IbmCloudSecretsManagerApiV1;
|
|
38
|
-
/**
|
|
39
|
-
* Construct a IbmCloudSecretsManagerApiV1 object.
|
|
40
|
-
*
|
|
41
|
-
* @param {Object} options - Options for the service.
|
|
42
|
-
* @param {string} [options.serviceUrl] - The base url to use when contacting the service (e.g. 'https://gateway.watsonplatform.net'). The base url may differ between IBM Cloud regions.
|
|
43
|
-
* @param {OutgoingHttpHeaders} [options.headers] - Default headers that shall be included with every request to the service.
|
|
44
|
-
* @param {Authenticator} options.authenticator - The Authenticator object used to authenticate requests to the service
|
|
45
|
-
* @constructor
|
|
46
|
-
* @returns {IbmCloudSecretsManagerApiV1}
|
|
47
|
-
*/
|
|
48
|
-
constructor(options: UserOptions);
|
|
49
|
-
/*************************
|
|
50
|
-
* config
|
|
51
|
-
************************/
|
|
52
|
-
/**
|
|
53
|
-
* Configure secrets of a given type.
|
|
54
|
-
*
|
|
55
|
-
* Updates the configuration for the given secret type.
|
|
56
|
-
*
|
|
57
|
-
* @param {Object} params - The parameters to send to the service.
|
|
58
|
-
* @param {string} params.secretType - The secret type.
|
|
59
|
-
* @param {SetEngineConfigOneOf} params.setEngineConfigOneOf - The base request for config update.
|
|
60
|
-
* @param {OutgoingHttpHeaders} [params.headers] - Custom request headers
|
|
61
|
-
* @returns {Promise<IbmCloudSecretsManagerApiV1.Response<IbmCloudSecretsManagerApiV1.Empty>>}
|
|
62
|
-
*/
|
|
63
|
-
putConfig(params: IbmCloudSecretsManagerApiV1.PutConfigParams): Promise<IbmCloudSecretsManagerApiV1.Response<IbmCloudSecretsManagerApiV1.Empty>>;
|
|
64
|
-
/**
|
|
65
|
-
* Get the configuration for a secret type.
|
|
66
|
-
*
|
|
67
|
-
* Retrieves a list of policies that are associated with a specified secret.
|
|
68
|
-
*
|
|
69
|
-
* @param {Object} params - The parameters to send to the service.
|
|
70
|
-
* @param {string} params.secretType - The secret type.
|
|
71
|
-
* @param {OutgoingHttpHeaders} [params.headers] - Custom request headers
|
|
72
|
-
* @returns {Promise<IbmCloudSecretsManagerApiV1.Response<IbmCloudSecretsManagerApiV1.SetIAMSecretEngineRootConfig>>}
|
|
73
|
-
*/
|
|
74
|
-
getConfig(params: IbmCloudSecretsManagerApiV1.GetConfigParams): Promise<IbmCloudSecretsManagerApiV1.Response<IbmCloudSecretsManagerApiV1.SetIAMSecretEngineRootConfig>>;
|
|
75
|
-
/*************************
|
|
76
|
-
* policies
|
|
77
|
-
************************/
|
|
78
|
-
/**
|
|
79
|
-
* Set secret policies.
|
|
80
|
-
*
|
|
81
|
-
* Creates or updates one or more policies for the specified secret.
|
|
82
|
-
*
|
|
83
|
-
* @param {Object} params - The parameters to send to the service.
|
|
84
|
-
* @param {string} params.secretType - The secret type.
|
|
85
|
-
* @param {string} params.id - The v4 UUID that uniquely identifies the secret.
|
|
86
|
-
* @param {CollectionMetadata} params.metadata - The metadata that describes the resource array.
|
|
87
|
-
* @param {SecretPolicyRotation[]} params.resources - A collection of resources.
|
|
88
|
-
* @param {string} [params.policy] - The type of policy that is associated with the specified secret.
|
|
89
|
-
* @param {OutgoingHttpHeaders} [params.headers] - Custom request headers
|
|
90
|
-
* @returns {Promise<IbmCloudSecretsManagerApiV1.Response<IbmCloudSecretsManagerApiV1.GetSecretPoliciesOneOf>>}
|
|
91
|
-
*/
|
|
92
|
-
putPolicy(params: IbmCloudSecretsManagerApiV1.PutPolicyParams): Promise<IbmCloudSecretsManagerApiV1.Response<IbmCloudSecretsManagerApiV1.GetSecretPoliciesOneOf>>;
|
|
93
|
-
/**
|
|
94
|
-
* List secret policies.
|
|
95
|
-
*
|
|
96
|
-
* Retrieves a list of policies that are associated with a specified secret.
|
|
97
|
-
*
|
|
98
|
-
* @param {Object} params - The parameters to send to the service.
|
|
99
|
-
* @param {string} params.secretType - The secret type.
|
|
100
|
-
* @param {string} params.id - The v4 UUID that uniquely identifies the secret.
|
|
101
|
-
* @param {string} [params.policy] - The type of policy that is associated with the specified secret.
|
|
102
|
-
* @param {OutgoingHttpHeaders} [params.headers] - Custom request headers
|
|
103
|
-
* @returns {Promise<IbmCloudSecretsManagerApiV1.Response<IbmCloudSecretsManagerApiV1.GetSecretPoliciesOneOf>>}
|
|
104
|
-
*/
|
|
105
|
-
getPolicy(params: IbmCloudSecretsManagerApiV1.GetPolicyParams): Promise<IbmCloudSecretsManagerApiV1.Response<IbmCloudSecretsManagerApiV1.GetSecretPoliciesOneOf>>;
|
|
106
|
-
/*************************
|
|
107
|
-
* secretGroups
|
|
108
|
-
************************/
|
|
109
|
-
/**
|
|
110
|
-
* Create secret group.
|
|
111
|
-
*
|
|
112
|
-
* Creates a new secret group.
|
|
113
|
-
*
|
|
114
|
-
* @param {Object} params - The parameters to send to the service.
|
|
115
|
-
* @param {CollectionMetadata} params.metadata - The metadata that describes the resource array.
|
|
116
|
-
* @param {SecretGroupResource[]} params.resources - A collection of resources.
|
|
117
|
-
* @param {OutgoingHttpHeaders} [params.headers] - Custom request headers
|
|
118
|
-
* @returns {Promise<IbmCloudSecretsManagerApiV1.Response<IbmCloudSecretsManagerApiV1.SecretGroupDef>>}
|
|
119
|
-
*/
|
|
120
|
-
createSecretGroup(params: IbmCloudSecretsManagerApiV1.CreateSecretGroupParams): Promise<IbmCloudSecretsManagerApiV1.Response<IbmCloudSecretsManagerApiV1.SecretGroupDef>>;
|
|
121
|
-
/**
|
|
122
|
-
* List secret groups.
|
|
123
|
-
*
|
|
124
|
-
* Retrieves the list of secret groups.
|
|
125
|
-
*
|
|
126
|
-
* @param {Object} [params] - The parameters to send to the service.
|
|
127
|
-
* @param {OutgoingHttpHeaders} [params.headers] - Custom request headers
|
|
128
|
-
* @returns {Promise<IbmCloudSecretsManagerApiV1.Response<IbmCloudSecretsManagerApiV1.SecretGroupDef>>}
|
|
129
|
-
*/
|
|
130
|
-
listSecretGroups(params?: IbmCloudSecretsManagerApiV1.ListSecretGroupsParams): Promise<IbmCloudSecretsManagerApiV1.Response<IbmCloudSecretsManagerApiV1.SecretGroupDef>>;
|
|
131
|
-
/**
|
|
132
|
-
* Retrieve a secret group.
|
|
133
|
-
*
|
|
134
|
-
* Retrieves a secret group and its details by specifying the ID of the secret group.
|
|
135
|
-
*
|
|
136
|
-
* @param {Object} params - The parameters to send to the service.
|
|
137
|
-
* @param {string} params.id - The v4 UUID that uniquely identifies the secret group.
|
|
138
|
-
* @param {OutgoingHttpHeaders} [params.headers] - Custom request headers
|
|
139
|
-
* @returns {Promise<IbmCloudSecretsManagerApiV1.Response<IbmCloudSecretsManagerApiV1.SecretGroupDef>>}
|
|
140
|
-
*/
|
|
141
|
-
getSecretGroup(params: IbmCloudSecretsManagerApiV1.GetSecretGroupParams): Promise<IbmCloudSecretsManagerApiV1.Response<IbmCloudSecretsManagerApiV1.SecretGroupDef>>;
|
|
142
|
-
/**
|
|
143
|
-
* Update secret group metadata.
|
|
144
|
-
*
|
|
145
|
-
* Updates the metadata of a secret group.
|
|
146
|
-
*
|
|
147
|
-
* @param {Object} params - The parameters to send to the service.
|
|
148
|
-
* @param {string} params.id - The v4 UUID that uniquely identifies the secret group.
|
|
149
|
-
* @param {CollectionMetadata} params.metadata - The metadata that describes the resource array.
|
|
150
|
-
* @param {SecretGroupMetadataUpdatable[]} params.resources - A collection of resources.
|
|
151
|
-
* @param {OutgoingHttpHeaders} [params.headers] - Custom request headers
|
|
152
|
-
* @returns {Promise<IbmCloudSecretsManagerApiV1.Response<IbmCloudSecretsManagerApiV1.SecretGroupDef>>}
|
|
153
|
-
*/
|
|
154
|
-
updateSecretGroupMetadata(params: IbmCloudSecretsManagerApiV1.UpdateSecretGroupMetadataParams): Promise<IbmCloudSecretsManagerApiV1.Response<IbmCloudSecretsManagerApiV1.SecretGroupDef>>;
|
|
155
|
-
/**
|
|
156
|
-
* Delete a secret group.
|
|
157
|
-
*
|
|
158
|
-
* Deletes a secret group by specifying the ID of the secret group.
|
|
159
|
-
*
|
|
160
|
-
* @param {Object} params - The parameters to send to the service.
|
|
161
|
-
* @param {string} params.id - The v4 UUID that uniquely identifies the secret group.
|
|
162
|
-
* @param {OutgoingHttpHeaders} [params.headers] - Custom request headers
|
|
163
|
-
* @returns {Promise<IbmCloudSecretsManagerApiV1.Response<IbmCloudSecretsManagerApiV1.SecretGroupDef>>}
|
|
164
|
-
*/
|
|
165
|
-
deleteSecretGroup(params: IbmCloudSecretsManagerApiV1.DeleteSecretGroupParams): Promise<IbmCloudSecretsManagerApiV1.Response<IbmCloudSecretsManagerApiV1.SecretGroupDef>>;
|
|
166
|
-
/*************************
|
|
167
|
-
* secrets
|
|
168
|
-
************************/
|
|
169
|
-
/**
|
|
170
|
-
* Create secret.
|
|
171
|
-
*
|
|
172
|
-
* Creates a new secret.
|
|
173
|
-
*
|
|
174
|
-
* @param {Object} params - The parameters to send to the service.
|
|
175
|
-
* @param {string} params.secretType - The secret type.
|
|
176
|
-
* @param {CollectionMetadata} params.metadata - The metadata that describes the resource array.
|
|
177
|
-
* @param {SecretResource[]} params.resources - A collection of resources.
|
|
178
|
-
* @param {OutgoingHttpHeaders} [params.headers] - Custom request headers
|
|
179
|
-
* @returns {Promise<IbmCloudSecretsManagerApiV1.Response<IbmCloudSecretsManagerApiV1.CreateSecret>>}
|
|
180
|
-
*/
|
|
181
|
-
createSecret(params: IbmCloudSecretsManagerApiV1.CreateSecretParams): Promise<IbmCloudSecretsManagerApiV1.Response<IbmCloudSecretsManagerApiV1.CreateSecret>>;
|
|
182
|
-
/**
|
|
183
|
-
* List secrets for type.
|
|
184
|
-
*
|
|
185
|
-
* Retrieves a list of secrets for a specific type.
|
|
186
|
-
*
|
|
187
|
-
* @param {Object} params - The parameters to send to the service.
|
|
188
|
-
* @param {string} params.secretType - The secret type.
|
|
189
|
-
* @param {number} [params.limit] - The number of secrets to retrieve. By default, `GET /secrets/{secret-type}`
|
|
190
|
-
* returns the first 200 secrets. To retrieve a different set of secrets, use `limit` with `offset` to page through
|
|
191
|
-
* your available resources. The maximum value for `limit` is 5000.
|
|
192
|
-
* **Usage:** If you have 20 secrets in your instance, and you want to retrieve only the first 5 secrets, use
|
|
193
|
-
* `../secrets/{secret-type}?limit=5`.
|
|
194
|
-
* @param {number} [params.offset] - The number of secrets to skip. By specifying `offset`, you retrieve a subset of
|
|
195
|
-
* secrets that starts with the `offset` value. Use `offset` with `limit` to page through your available resources.
|
|
196
|
-
* **Usage:** If you have 100 keys in your instance, and you want to retrieve secrets 26 through 50, use
|
|
197
|
-
* `../secrets/{secret-type}?offset=25&limit=25`.
|
|
198
|
-
* @param {OutgoingHttpHeaders} [params.headers] - Custom request headers
|
|
199
|
-
* @returns {Promise<IbmCloudSecretsManagerApiV1.Response<IbmCloudSecretsManagerApiV1.ListSecrets>>}
|
|
200
|
-
*/
|
|
201
|
-
listSecrets(params: IbmCloudSecretsManagerApiV1.ListSecretsParams): Promise<IbmCloudSecretsManagerApiV1.Response<IbmCloudSecretsManagerApiV1.ListSecrets>>;
|
|
202
|
-
/**
|
|
203
|
-
* List secrets of all types.
|
|
204
|
-
*
|
|
205
|
-
* Retrieves a list of secrets of all types.
|
|
206
|
-
*
|
|
207
|
-
* @param {Object} [params] - The parameters to send to the service.
|
|
208
|
-
* @param {number} [params.limit] - The number of secrets to retrieve. By default, `GET /secrets/{secret-type}`
|
|
209
|
-
* returns the first 200 secrets. To retrieve a different set of secrets, use `limit` with `offset` to page through
|
|
210
|
-
* your available resources. The maximum value for `limit` is 5000.
|
|
211
|
-
* **Usage:** If you have 20 secrets in your instance, and you want to retrieve only the first 5 secrets, use
|
|
212
|
-
* `../secrets/{secret-type}?limit=5`.
|
|
213
|
-
* @param {number} [params.offset] - The number of secrets to skip. By specifying `offset`, you retrieve a subset of
|
|
214
|
-
* secrets that starts with the `offset` value. Use `offset` with `limit` to page through your available resources.
|
|
215
|
-
* **Usage:** If you have 100 keys in your instance, and you want to retrieve secrets 26 through 50, use
|
|
216
|
-
* `../secrets/{secret-type}?offset=25&limit=25`.
|
|
217
|
-
* @param {OutgoingHttpHeaders} [params.headers] - Custom request headers
|
|
218
|
-
* @returns {Promise<IbmCloudSecretsManagerApiV1.Response<IbmCloudSecretsManagerApiV1.ListSecrets>>}
|
|
219
|
-
*/
|
|
220
|
-
listAllSecrets(params?: IbmCloudSecretsManagerApiV1.ListAllSecretsParams): Promise<IbmCloudSecretsManagerApiV1.Response<IbmCloudSecretsManagerApiV1.ListSecrets>>;
|
|
221
|
-
/**
|
|
222
|
-
* Retrieve a secret.
|
|
223
|
-
*
|
|
224
|
-
* Retrieves a secret and its details by specifying the ID of the secret.
|
|
225
|
-
*
|
|
226
|
-
* @param {Object} params - The parameters to send to the service.
|
|
227
|
-
* @param {string} params.secretType - The secret type.
|
|
228
|
-
* @param {string} params.id - The v4 UUID that uniquely identifies the secret.
|
|
229
|
-
* @param {OutgoingHttpHeaders} [params.headers] - Custom request headers
|
|
230
|
-
* @returns {Promise<IbmCloudSecretsManagerApiV1.Response<IbmCloudSecretsManagerApiV1.GetSecret>>}
|
|
231
|
-
*/
|
|
232
|
-
getSecret(params: IbmCloudSecretsManagerApiV1.GetSecretParams): Promise<IbmCloudSecretsManagerApiV1.Response<IbmCloudSecretsManagerApiV1.GetSecret>>;
|
|
233
|
-
/**
|
|
234
|
-
* Invoke an action on a secret.
|
|
235
|
-
*
|
|
236
|
-
* Invokes an action on a specified secret. Currently the supported actions are `rotate` for arbitrary and
|
|
237
|
-
* usernname-password secrets, and `delete_credentials` for IAM credentials secrets.
|
|
238
|
-
*
|
|
239
|
-
* @param {Object} params - The parameters to send to the service.
|
|
240
|
-
* @param {string} params.secretType - The secret type.
|
|
241
|
-
* @param {string} params.id - The v4 UUID that uniquely identifies the secret.
|
|
242
|
-
* @param {string} params.action - The action to perform on the specified secret.
|
|
243
|
-
* @param {SecretActionOneOf} params.secretActionOneOf - The base request for invoking an action on a secret.
|
|
244
|
-
* @param {OutgoingHttpHeaders} [params.headers] - Custom request headers
|
|
245
|
-
* @returns {Promise<IbmCloudSecretsManagerApiV1.Response<IbmCloudSecretsManagerApiV1.GetSecret>>}
|
|
246
|
-
*/
|
|
247
|
-
updateSecret(params: IbmCloudSecretsManagerApiV1.UpdateSecretParams): Promise<IbmCloudSecretsManagerApiV1.Response<IbmCloudSecretsManagerApiV1.GetSecret>>;
|
|
248
|
-
/**
|
|
249
|
-
* Delete a secret.
|
|
250
|
-
*
|
|
251
|
-
* Deletes a secret by specifying the ID of the secret.
|
|
252
|
-
*
|
|
253
|
-
* @param {Object} params - The parameters to send to the service.
|
|
254
|
-
* @param {string} params.secretType - The secret type.
|
|
255
|
-
* @param {string} params.id - The v4 UUID that uniquely identifies the secret.
|
|
256
|
-
* @param {OutgoingHttpHeaders} [params.headers] - Custom request headers
|
|
257
|
-
* @returns {Promise<IbmCloudSecretsManagerApiV1.Response<IbmCloudSecretsManagerApiV1.Empty>>}
|
|
258
|
-
*/
|
|
259
|
-
deleteSecret(params: IbmCloudSecretsManagerApiV1.DeleteSecretParams): Promise<IbmCloudSecretsManagerApiV1.Response<IbmCloudSecretsManagerApiV1.Empty>>;
|
|
260
|
-
/**
|
|
261
|
-
* Retrieve secret metadata.
|
|
262
|
-
*
|
|
263
|
-
* Retrieves the details of a secret by specifying the ID. The actual content of the secret is not returned.
|
|
264
|
-
*
|
|
265
|
-
* @param {Object} params - The parameters to send to the service.
|
|
266
|
-
* @param {string} params.secretType - The secret type.
|
|
267
|
-
* @param {string} params.id - The v4 UUID that uniquely identifies the secret.
|
|
268
|
-
* @param {OutgoingHttpHeaders} [params.headers] - Custom request headers
|
|
269
|
-
* @returns {Promise<IbmCloudSecretsManagerApiV1.Response<IbmCloudSecretsManagerApiV1.SecretMetadataRequest>>}
|
|
270
|
-
*/
|
|
271
|
-
getSecretMetadata(params: IbmCloudSecretsManagerApiV1.GetSecretMetadataParams): Promise<IbmCloudSecretsManagerApiV1.Response<IbmCloudSecretsManagerApiV1.SecretMetadataRequest>>;
|
|
272
|
-
/**
|
|
273
|
-
* Update secret metadata.
|
|
274
|
-
*
|
|
275
|
-
* Updates the metadata of a secret. The actual content of the secret is not updated.
|
|
276
|
-
*
|
|
277
|
-
* @param {Object} params - The parameters to send to the service.
|
|
278
|
-
* @param {string} params.secretType - The secret type.
|
|
279
|
-
* @param {string} params.id - The v4 UUID that uniquely identifies the secret.
|
|
280
|
-
* @param {CollectionMetadata} params.metadata - The metadata that describes the resource array.
|
|
281
|
-
* @param {SecretMetadata[]} params.resources - A collection of resources.
|
|
282
|
-
* @param {OutgoingHttpHeaders} [params.headers] - Custom request headers
|
|
283
|
-
* @returns {Promise<IbmCloudSecretsManagerApiV1.Response<IbmCloudSecretsManagerApiV1.SecretMetadataRequest>>}
|
|
284
|
-
*/
|
|
285
|
-
updateSecretMetadata(params: IbmCloudSecretsManagerApiV1.UpdateSecretMetadataParams): Promise<IbmCloudSecretsManagerApiV1.Response<IbmCloudSecretsManagerApiV1.SecretMetadataRequest>>;
|
|
286
|
-
}
|
|
287
|
-
/*************************
|
|
288
|
-
* interfaces
|
|
289
|
-
************************/
|
|
290
|
-
declare namespace IbmCloudSecretsManagerApiV1 {
|
|
291
|
-
/** An operation response. */
|
|
292
|
-
interface Response<T = any> {
|
|
293
|
-
result: T;
|
|
294
|
-
status: number;
|
|
295
|
-
statusText: string;
|
|
296
|
-
headers: IncomingHttpHeaders;
|
|
297
|
-
}
|
|
298
|
-
/** The callback for a service request. */
|
|
299
|
-
type Callback<T> = (error: any, response?: Response<T>) => void;
|
|
300
|
-
/** The body of a service request that returns no response data. */
|
|
301
|
-
interface Empty {
|
|
302
|
-
}
|
|
303
|
-
/** A standard JS object, defined to avoid the limitations of `Object` and `object` */
|
|
304
|
-
interface JsonObject {
|
|
305
|
-
[key: string]: any;
|
|
306
|
-
}
|
|
307
|
-
/*************************
|
|
308
|
-
* request interfaces
|
|
309
|
-
************************/
|
|
310
|
-
/** Parameters for the `putConfig` operation. */
|
|
311
|
-
interface PutConfigParams {
|
|
312
|
-
/** The secret type. */
|
|
313
|
-
secretType: PutConfigConstants.SecretType | string;
|
|
314
|
-
/** The base request for config update. */
|
|
315
|
-
setEngineConfigOneOf: SetEngineConfigOneOf;
|
|
316
|
-
headers?: OutgoingHttpHeaders;
|
|
317
|
-
}
|
|
318
|
-
/** Constants for the `putConfig` operation. */
|
|
319
|
-
namespace PutConfigConstants {
|
|
320
|
-
/** The secret type. */
|
|
321
|
-
enum SecretType {
|
|
322
|
-
IAM_CREDENTIALS = "iam_credentials"
|
|
323
|
-
}
|
|
324
|
-
}
|
|
325
|
-
/** Parameters for the `getConfig` operation. */
|
|
326
|
-
interface GetConfigParams {
|
|
327
|
-
/** The secret type. */
|
|
328
|
-
secretType: GetConfigConstants.SecretType | string;
|
|
329
|
-
headers?: OutgoingHttpHeaders;
|
|
330
|
-
}
|
|
331
|
-
/** Constants for the `getConfig` operation. */
|
|
332
|
-
namespace GetConfigConstants {
|
|
333
|
-
/** The secret type. */
|
|
334
|
-
enum SecretType {
|
|
335
|
-
IAM_CREDENTIALS = "iam_credentials"
|
|
336
|
-
}
|
|
337
|
-
}
|
|
338
|
-
/** Parameters for the `putPolicy` operation. */
|
|
339
|
-
interface PutPolicyParams {
|
|
340
|
-
/** The secret type. */
|
|
341
|
-
secretType: PutPolicyConstants.SecretType | string;
|
|
342
|
-
/** The v4 UUID that uniquely identifies the secret. */
|
|
343
|
-
id: string;
|
|
344
|
-
/** The metadata that describes the resource array. */
|
|
345
|
-
metadata: CollectionMetadata;
|
|
346
|
-
/** A collection of resources. */
|
|
347
|
-
resources: SecretPolicyRotation[];
|
|
348
|
-
/** The type of policy that is associated with the specified secret. */
|
|
349
|
-
policy?: PutPolicyConstants.Policy | string;
|
|
350
|
-
headers?: OutgoingHttpHeaders;
|
|
351
|
-
}
|
|
352
|
-
/** Constants for the `putPolicy` operation. */
|
|
353
|
-
namespace PutPolicyConstants {
|
|
354
|
-
/** The secret type. */
|
|
355
|
-
enum SecretType {
|
|
356
|
-
USERNAME_PASSWORD = "username_password"
|
|
357
|
-
}
|
|
358
|
-
/** The type of policy that is associated with the specified secret. */
|
|
359
|
-
enum Policy {
|
|
360
|
-
ROTATION = "rotation"
|
|
361
|
-
}
|
|
362
|
-
}
|
|
363
|
-
/** Parameters for the `getPolicy` operation. */
|
|
364
|
-
interface GetPolicyParams {
|
|
365
|
-
/** The secret type. */
|
|
366
|
-
secretType: GetPolicyConstants.SecretType | string;
|
|
367
|
-
/** The v4 UUID that uniquely identifies the secret. */
|
|
368
|
-
id: string;
|
|
369
|
-
/** The type of policy that is associated with the specified secret. */
|
|
370
|
-
policy?: GetPolicyConstants.Policy | string;
|
|
371
|
-
headers?: OutgoingHttpHeaders;
|
|
372
|
-
}
|
|
373
|
-
/** Constants for the `getPolicy` operation. */
|
|
374
|
-
namespace GetPolicyConstants {
|
|
375
|
-
/** The secret type. */
|
|
376
|
-
enum SecretType {
|
|
377
|
-
USERNAME_PASSWORD = "username_password"
|
|
378
|
-
}
|
|
379
|
-
/** The type of policy that is associated with the specified secret. */
|
|
380
|
-
enum Policy {
|
|
381
|
-
ROTATION = "rotation"
|
|
382
|
-
}
|
|
383
|
-
}
|
|
384
|
-
/** Parameters for the `createSecretGroup` operation. */
|
|
385
|
-
interface CreateSecretGroupParams {
|
|
386
|
-
/** The metadata that describes the resource array. */
|
|
387
|
-
metadata: CollectionMetadata;
|
|
388
|
-
/** A collection of resources. */
|
|
389
|
-
resources: SecretGroupResource[];
|
|
390
|
-
headers?: OutgoingHttpHeaders;
|
|
391
|
-
}
|
|
392
|
-
/** Parameters for the `listSecretGroups` operation. */
|
|
393
|
-
interface ListSecretGroupsParams {
|
|
394
|
-
headers?: OutgoingHttpHeaders;
|
|
395
|
-
}
|
|
396
|
-
/** Parameters for the `getSecretGroup` operation. */
|
|
397
|
-
interface GetSecretGroupParams {
|
|
398
|
-
/** The v4 UUID that uniquely identifies the secret group. */
|
|
399
|
-
id: string;
|
|
400
|
-
headers?: OutgoingHttpHeaders;
|
|
401
|
-
}
|
|
402
|
-
/** Parameters for the `updateSecretGroupMetadata` operation. */
|
|
403
|
-
interface UpdateSecretGroupMetadataParams {
|
|
404
|
-
/** The v4 UUID that uniquely identifies the secret group. */
|
|
405
|
-
id: string;
|
|
406
|
-
/** The metadata that describes the resource array. */
|
|
407
|
-
metadata: CollectionMetadata;
|
|
408
|
-
/** A collection of resources. */
|
|
409
|
-
resources: SecretGroupMetadataUpdatable[];
|
|
410
|
-
headers?: OutgoingHttpHeaders;
|
|
411
|
-
}
|
|
412
|
-
/** Parameters for the `deleteSecretGroup` operation. */
|
|
413
|
-
interface DeleteSecretGroupParams {
|
|
414
|
-
/** The v4 UUID that uniquely identifies the secret group. */
|
|
415
|
-
id: string;
|
|
416
|
-
headers?: OutgoingHttpHeaders;
|
|
417
|
-
}
|
|
418
|
-
/** Parameters for the `createSecret` operation. */
|
|
419
|
-
interface CreateSecretParams {
|
|
420
|
-
/** The secret type. */
|
|
421
|
-
secretType: CreateSecretConstants.SecretType | string;
|
|
422
|
-
/** The metadata that describes the resource array. */
|
|
423
|
-
metadata: CollectionMetadata;
|
|
424
|
-
/** A collection of resources. */
|
|
425
|
-
resources: SecretResource[];
|
|
426
|
-
headers?: OutgoingHttpHeaders;
|
|
427
|
-
}
|
|
428
|
-
/** Constants for the `createSecret` operation. */
|
|
429
|
-
namespace CreateSecretConstants {
|
|
430
|
-
/** The secret type. */
|
|
431
|
-
enum SecretType {
|
|
432
|
-
ARBITRARY = "arbitrary",
|
|
433
|
-
USERNAME_PASSWORD = "username_password",
|
|
434
|
-
IAM_CREDENTIALS = "iam_credentials"
|
|
435
|
-
}
|
|
436
|
-
}
|
|
437
|
-
/** Parameters for the `listSecrets` operation. */
|
|
438
|
-
interface ListSecretsParams {
|
|
439
|
-
/** The secret type. */
|
|
440
|
-
secretType: ListSecretsConstants.SecretType | string;
|
|
441
|
-
/** The number of secrets to retrieve. By default, `GET /secrets/{secret-type}` returns the first 200 secrets.
|
|
442
|
-
* To retrieve a different set of secrets, use `limit` with `offset` to page through your available resources. The
|
|
443
|
-
* maximum value for `limit` is 5000.
|
|
444
|
-
* **Usage:** If you have 20 secrets in your instance, and you want to retrieve only the first 5 secrets, use
|
|
445
|
-
* `../secrets/{secret-type}?limit=5`.
|
|
446
|
-
*/
|
|
447
|
-
limit?: number;
|
|
448
|
-
/** The number of secrets to skip. By specifying `offset`, you retrieve a subset of secrets that starts with the
|
|
449
|
-
* `offset` value. Use `offset` with `limit` to page through your available resources.
|
|
450
|
-
* **Usage:** If you have 100 keys in your instance, and you want to retrieve secrets 26 through 50, use
|
|
451
|
-
* `../secrets/{secret-type}?offset=25&limit=25`.
|
|
452
|
-
*/
|
|
453
|
-
offset?: number;
|
|
454
|
-
headers?: OutgoingHttpHeaders;
|
|
455
|
-
}
|
|
456
|
-
/** Constants for the `listSecrets` operation. */
|
|
457
|
-
namespace ListSecretsConstants {
|
|
458
|
-
/** The secret type. */
|
|
459
|
-
enum SecretType {
|
|
460
|
-
ARBITRARY = "arbitrary",
|
|
461
|
-
USERNAME_PASSWORD = "username_password",
|
|
462
|
-
IAM_CREDENTIALS = "iam_credentials"
|
|
463
|
-
}
|
|
464
|
-
}
|
|
465
|
-
/** Parameters for the `listAllSecrets` operation. */
|
|
466
|
-
interface ListAllSecretsParams {
|
|
467
|
-
/** The number of secrets to retrieve. By default, `GET /secrets/{secret-type}` returns the first 200 secrets.
|
|
468
|
-
* To retrieve a different set of secrets, use `limit` with `offset` to page through your available resources. The
|
|
469
|
-
* maximum value for `limit` is 5000.
|
|
470
|
-
* **Usage:** If you have 20 secrets in your instance, and you want to retrieve only the first 5 secrets, use
|
|
471
|
-
* `../secrets/{secret-type}?limit=5`.
|
|
472
|
-
*/
|
|
473
|
-
limit?: number;
|
|
474
|
-
/** The number of secrets to skip. By specifying `offset`, you retrieve a subset of secrets that starts with the
|
|
475
|
-
* `offset` value. Use `offset` with `limit` to page through your available resources.
|
|
476
|
-
* **Usage:** If you have 100 keys in your instance, and you want to retrieve secrets 26 through 50, use
|
|
477
|
-
* `../secrets/{secret-type}?offset=25&limit=25`.
|
|
478
|
-
*/
|
|
479
|
-
offset?: number;
|
|
480
|
-
headers?: OutgoingHttpHeaders;
|
|
481
|
-
}
|
|
482
|
-
/** Parameters for the `getSecret` operation. */
|
|
483
|
-
interface GetSecretParams {
|
|
484
|
-
/** The secret type. */
|
|
485
|
-
secretType: GetSecretConstants.SecretType | string;
|
|
486
|
-
/** The v4 UUID that uniquely identifies the secret. */
|
|
487
|
-
id: string;
|
|
488
|
-
headers?: OutgoingHttpHeaders;
|
|
489
|
-
}
|
|
490
|
-
/** Constants for the `getSecret` operation. */
|
|
491
|
-
namespace GetSecretConstants {
|
|
492
|
-
/** The secret type. */
|
|
493
|
-
enum SecretType {
|
|
494
|
-
ARBITRARY = "arbitrary",
|
|
495
|
-
USERNAME_PASSWORD = "username_password",
|
|
496
|
-
IAM_CREDENTIALS = "iam_credentials"
|
|
497
|
-
}
|
|
498
|
-
}
|
|
499
|
-
/** Parameters for the `updateSecret` operation. */
|
|
500
|
-
interface UpdateSecretParams {
|
|
501
|
-
/** The secret type. */
|
|
502
|
-
secretType: UpdateSecretConstants.SecretType | string;
|
|
503
|
-
/** The v4 UUID that uniquely identifies the secret. */
|
|
504
|
-
id: string;
|
|
505
|
-
/** The action to perform on the specified secret. */
|
|
506
|
-
action: UpdateSecretConstants.Action | string;
|
|
507
|
-
/** The base request for invoking an action on a secret. */
|
|
508
|
-
secretActionOneOf: SecretActionOneOf;
|
|
509
|
-
headers?: OutgoingHttpHeaders;
|
|
510
|
-
}
|
|
511
|
-
/** Constants for the `updateSecret` operation. */
|
|
512
|
-
namespace UpdateSecretConstants {
|
|
513
|
-
/** The secret type. */
|
|
514
|
-
enum SecretType {
|
|
515
|
-
ARBITRARY = "arbitrary",
|
|
516
|
-
USERNAME_PASSWORD = "username_password",
|
|
517
|
-
IAM_CREDENTIALS = "iam_credentials"
|
|
518
|
-
}
|
|
519
|
-
/** The action to perform on the specified secret. */
|
|
520
|
-
enum Action {
|
|
521
|
-
ROTATE = "rotate",
|
|
522
|
-
DELETE_CREDENTIALS = "delete_credentials"
|
|
523
|
-
}
|
|
524
|
-
}
|
|
525
|
-
/** Parameters for the `deleteSecret` operation. */
|
|
526
|
-
interface DeleteSecretParams {
|
|
527
|
-
/** The secret type. */
|
|
528
|
-
secretType: DeleteSecretConstants.SecretType | string;
|
|
529
|
-
/** The v4 UUID that uniquely identifies the secret. */
|
|
530
|
-
id: string;
|
|
531
|
-
headers?: OutgoingHttpHeaders;
|
|
532
|
-
}
|
|
533
|
-
/** Constants for the `deleteSecret` operation. */
|
|
534
|
-
namespace DeleteSecretConstants {
|
|
535
|
-
/** The secret type. */
|
|
536
|
-
enum SecretType {
|
|
537
|
-
ARBITRARY = "arbitrary",
|
|
538
|
-
USERNAME_PASSWORD = "username_password",
|
|
539
|
-
IAM_CREDENTIALS = "iam_credentials"
|
|
540
|
-
}
|
|
541
|
-
}
|
|
542
|
-
/** Parameters for the `getSecretMetadata` operation. */
|
|
543
|
-
interface GetSecretMetadataParams {
|
|
544
|
-
/** The secret type. */
|
|
545
|
-
secretType: GetSecretMetadataConstants.SecretType | string;
|
|
546
|
-
/** The v4 UUID that uniquely identifies the secret. */
|
|
547
|
-
id: string;
|
|
548
|
-
headers?: OutgoingHttpHeaders;
|
|
549
|
-
}
|
|
550
|
-
/** Constants for the `getSecretMetadata` operation. */
|
|
551
|
-
namespace GetSecretMetadataConstants {
|
|
552
|
-
/** The secret type. */
|
|
553
|
-
enum SecretType {
|
|
554
|
-
ARBITRARY = "arbitrary",
|
|
555
|
-
USERNAME_PASSWORD = "username_password",
|
|
556
|
-
IAM_CREDENTIALS = "iam_credentials"
|
|
557
|
-
}
|
|
558
|
-
}
|
|
559
|
-
/** Parameters for the `updateSecretMetadata` operation. */
|
|
560
|
-
interface UpdateSecretMetadataParams {
|
|
561
|
-
/** The secret type. */
|
|
562
|
-
secretType: UpdateSecretMetadataConstants.SecretType | string;
|
|
563
|
-
/** The v4 UUID that uniquely identifies the secret. */
|
|
564
|
-
id: string;
|
|
565
|
-
/** The metadata that describes the resource array. */
|
|
566
|
-
metadata: CollectionMetadata;
|
|
567
|
-
/** A collection of resources. */
|
|
568
|
-
resources: SecretMetadata[];
|
|
569
|
-
headers?: OutgoingHttpHeaders;
|
|
570
|
-
}
|
|
571
|
-
/** Constants for the `updateSecretMetadata` operation. */
|
|
572
|
-
namespace UpdateSecretMetadataConstants {
|
|
573
|
-
/** The secret type. */
|
|
574
|
-
enum SecretType {
|
|
575
|
-
ARBITRARY = "arbitrary",
|
|
576
|
-
USERNAME_PASSWORD = "username_password",
|
|
577
|
-
IAM_CREDENTIALS = "iam_credentials"
|
|
578
|
-
}
|
|
579
|
-
}
|
|
580
|
-
/*************************
|
|
581
|
-
* model interfaces
|
|
582
|
-
************************/
|
|
583
|
-
/** The metadata that describes the resource array. */
|
|
584
|
-
interface CollectionMetadata {
|
|
585
|
-
/** The type of resources in the resource array. */
|
|
586
|
-
collection_type: string;
|
|
587
|
-
/** The number of elements in the resource array. */
|
|
588
|
-
collection_total: number;
|
|
589
|
-
}
|
|
590
|
-
/** The base schema for creating secrets. */
|
|
591
|
-
interface CreateSecret {
|
|
592
|
-
/** The metadata that describes the resource array. */
|
|
593
|
-
metadata: CollectionMetadata;
|
|
594
|
-
/** A collection of resources. */
|
|
595
|
-
resources: SecretResource[];
|
|
596
|
-
}
|
|
597
|
-
/** The base schema for secret. */
|
|
598
|
-
interface GetSecret {
|
|
599
|
-
/** The metadata that describes the resource array. */
|
|
600
|
-
metadata: CollectionMetadata;
|
|
601
|
-
/** A collection of resources. */
|
|
602
|
-
resources: SecretResource[];
|
|
603
|
-
}
|
|
604
|
-
/** GetSecretPoliciesOneOf. */
|
|
605
|
-
interface GetSecretPoliciesOneOf {
|
|
606
|
-
}
|
|
607
|
-
/** Policy of type rotation. */
|
|
608
|
-
interface GetSecretPoliciesOneOfGetSecretPolicyRotationResourcesItem {
|
|
609
|
-
/** The v4 UUID used to uniquely identify the policy resource, as specified by RFC 4122. */
|
|
610
|
-
id: string;
|
|
611
|
-
/** The Cloud Resource Name (CRN) that uniquely identifies your cloud resources. */
|
|
612
|
-
crn?: string;
|
|
613
|
-
/** The date the policy was created. The date format follows RFC 3339. */
|
|
614
|
-
creation_date?: string;
|
|
615
|
-
/** The unique identifier for the resource that created the policy. */
|
|
616
|
-
created_by?: string;
|
|
617
|
-
/** Updates when the policy is replaced or modified. The date format follows RFC 3339. */
|
|
618
|
-
last_update_date?: string;
|
|
619
|
-
/** The unique identifier for the resource that updated the policy. */
|
|
620
|
-
updated_by?: string;
|
|
621
|
-
/** Specifies the MIME type that represents the policy resource. Currently, only the default is supported. */
|
|
622
|
-
type: string;
|
|
623
|
-
/** Specifies the secret rotation time interval. "unit" specifies the unit of the interval, and "interval"
|
|
624
|
-
* specifies the amount of the units.
|
|
625
|
-
*/
|
|
626
|
-
rotation: SecretPolicyRotationRotation;
|
|
627
|
-
}
|
|
628
|
-
/** The base schema for listing keys. */
|
|
629
|
-
interface ListSecrets {
|
|
630
|
-
/** The metadata that describes the resource array. */
|
|
631
|
-
metadata: CollectionMetadata;
|
|
632
|
-
/** A collection of resources. */
|
|
633
|
-
resources?: SecretResource[];
|
|
634
|
-
}
|
|
635
|
-
/** SecretActionOneOf. */
|
|
636
|
-
interface SecretActionOneOf {
|
|
637
|
-
}
|
|
638
|
-
/** The base schema definition for a secret group. */
|
|
639
|
-
interface SecretGroupDef {
|
|
640
|
-
/** The metadata that describes the resource array. */
|
|
641
|
-
metadata: CollectionMetadata;
|
|
642
|
-
/** A collection of resources. */
|
|
643
|
-
resources: SecretGroupResource[];
|
|
644
|
-
}
|
|
645
|
-
/** Updatable metadata properties that describe a secret group. */
|
|
646
|
-
interface SecretGroupMetadataUpdatable {
|
|
647
|
-
/** A human-readable name to assign to your secret group. To protect your privacy, do not use personal data,
|
|
648
|
-
* such as your name or location, as an name for your secret group.
|
|
649
|
-
*/
|
|
650
|
-
name?: string;
|
|
651
|
-
/** A text field used to provide a more detailed description of the secret group. The maximum length is 1024
|
|
652
|
-
* characters. To protect your privacy, do not use personal data, such as your name or location, as a description
|
|
653
|
-
* for your secret group.
|
|
654
|
-
*/
|
|
655
|
-
description?: string;
|
|
656
|
-
}
|
|
657
|
-
/** Properties that describe a secret group. */
|
|
658
|
-
interface SecretGroupResource {
|
|
659
|
-
/** The v4 UUID used to uniquely identify the resource, as specified by RFC 4122. */
|
|
660
|
-
id?: string;
|
|
661
|
-
/** A human-readable name to assign to your secret group. To protect your privacy, do not use personal data,
|
|
662
|
-
* such as your name or location, as an name for your secret group.
|
|
663
|
-
*/
|
|
664
|
-
name?: string;
|
|
665
|
-
/** A text field used to provide a more detailed description of the secret group. The maximum length is 1024
|
|
666
|
-
* characters. To protect your privacy, do not use personal data, such as your name or location, as a description
|
|
667
|
-
* for your secret group.
|
|
668
|
-
*/
|
|
669
|
-
description?: string;
|
|
670
|
-
/** SecretGroupResource accepts additional properties. */
|
|
671
|
-
[propName: string]: any;
|
|
672
|
-
}
|
|
673
|
-
/** Metadata properties that describe a secret. */
|
|
674
|
-
interface SecretMetadata {
|
|
675
|
-
/** The unique ID of the secret. */
|
|
676
|
-
id?: string;
|
|
677
|
-
/** The labels of the secret. */
|
|
678
|
-
labels?: string[];
|
|
679
|
-
/** The name of the secret. */
|
|
680
|
-
name: string;
|
|
681
|
-
/** A string describing the secret. */
|
|
682
|
-
description?: string;
|
|
683
|
-
/** The v4 UUID that uniquely identifies the secret group to assign to this secret. Optional, the secret is
|
|
684
|
-
* assigned to the "default" secret group when the param is not included.
|
|
685
|
-
*/
|
|
686
|
-
secret_group_id?: string;
|
|
687
|
-
/** The key state based on NIST SP 800-57. States are integers and correspond to the Pre-activation = 0, Active
|
|
688
|
-
* = 1, Suspended = 2, Deactivated = 3, and Destroyed = 5 values.
|
|
689
|
-
*/
|
|
690
|
-
state?: number;
|
|
691
|
-
/** A text representation of the secret state. */
|
|
692
|
-
state_description?: string;
|
|
693
|
-
/** The secret type. */
|
|
694
|
-
secret_type?: string;
|
|
695
|
-
/** The date the secret material expires. The date format follows RFC 3339. You can set an expiration date on
|
|
696
|
-
* any secret on its creation. If you create a secret without specifying an expiration date, the secret does not
|
|
697
|
-
* expire. This property is only relevant for Arbitrary and Username-Password secrets.
|
|
698
|
-
*/
|
|
699
|
-
expiration_date?: string;
|
|
700
|
-
/** TTL defines the time-to-live for generated credentials. For IAM-credentials secrets, the TTL defines for how
|
|
701
|
-
* long each generated API key will live. The value can be either an integer specifying the number of seconds, or
|
|
702
|
-
* the string representation of a duration (eg. “120m”, “24h”). This parameter is only relevant for IAM-credentials
|
|
703
|
-
* secrets.
|
|
704
|
-
*/
|
|
705
|
-
ttl?: any;
|
|
706
|
-
/** The Cloud Resource Name (CRN) that uniquely identifies your cloud resources. */
|
|
707
|
-
crn?: string;
|
|
708
|
-
/** The date the secret was created. The date format follows RFC 3339. */
|
|
709
|
-
creation_date?: string;
|
|
710
|
-
/** The unique identifier for the entity that created the secret. */
|
|
711
|
-
created_by?: string;
|
|
712
|
-
/** Updates when any part of the secret metadata is modified. The date format follows RFC 3339. */
|
|
713
|
-
last_update_date?: string;
|
|
714
|
-
}
|
|
715
|
-
/** The metadata for a secret. */
|
|
716
|
-
interface SecretMetadataRequest {
|
|
717
|
-
/** The metadata that describes the resource array. */
|
|
718
|
-
metadata: CollectionMetadata;
|
|
719
|
-
/** A collection of resources. */
|
|
720
|
-
resources: SecretMetadata[];
|
|
721
|
-
}
|
|
722
|
-
/** Policy of type rotation. */
|
|
723
|
-
interface SecretPolicyRotation {
|
|
724
|
-
/** Specifies the MIME type that represents the policy resource. Currently, only the default is supported. */
|
|
725
|
-
type: string;
|
|
726
|
-
/** Specifies the secret rotation time interval. "unit" specifies the unit of the interval, and "interval"
|
|
727
|
-
* specifies the amount of the units.
|
|
728
|
-
*/
|
|
729
|
-
rotation: SecretPolicyRotationRotation;
|
|
730
|
-
}
|
|
731
|
-
/** Specifies the secret rotation time interval. "unit" specifies the unit of the interval, and "interval" specifies the amount of the units. */
|
|
732
|
-
interface SecretPolicyRotationRotation {
|
|
733
|
-
/** Specifies the length of the secret rotation time interval. */
|
|
734
|
-
interval: number;
|
|
735
|
-
/** Specifies the units for the secret rotation time interval. */
|
|
736
|
-
unit: string;
|
|
737
|
-
}
|
|
738
|
-
/** Properties that describe a secret. */
|
|
739
|
-
interface SecretResource {
|
|
740
|
-
/** Specifies the MIME type that represents the secret resource. */
|
|
741
|
-
type?: string;
|
|
742
|
-
/** The v4 UUID used to uniquely identify the resource, as specified by RFC 4122. */
|
|
743
|
-
id?: string;
|
|
744
|
-
/** A human-readable alias to assign to your secret. To protect your privacy, do not use personal data, such as
|
|
745
|
-
* your name or location, as an alias for your secret.
|
|
746
|
-
*/
|
|
747
|
-
name: string;
|
|
748
|
-
/** A text field used to provide a more detailed description of the secret. The maximum length is 240
|
|
749
|
-
* characters. To protect your privacy, do not use personal data, such as your name or location, as a description
|
|
750
|
-
* for your secret.
|
|
751
|
-
*/
|
|
752
|
-
description?: string;
|
|
753
|
-
/** The v4 UUID that uniquely identifies the secret group to assign to this secret. Optional, the secret is
|
|
754
|
-
* assigned to the "default" secret group when the param is not included.
|
|
755
|
-
*/
|
|
756
|
-
secret_group_id?: string;
|
|
757
|
-
/** Up to 30 labels can be created. Labels can be between 2-30 characters, including spaces. Special characters
|
|
758
|
-
* not permitted include the angled bracket, comma, colon, ampersand, and vertical pipe character (|). To protect
|
|
759
|
-
* your privacy, do not use personal data, such as your name or location, as a label for your secret.
|
|
760
|
-
*/
|
|
761
|
-
labels?: string[];
|
|
762
|
-
/** The key state based on NIST SP 800-57. States are integers and correspond to the Pre-activation = 0, Active
|
|
763
|
-
* = 1, Suspended = 2, Deactivated = 3, and Destroyed = 5 values.
|
|
764
|
-
*/
|
|
765
|
-
state?: number;
|
|
766
|
-
/** The date the secret material expires. The date format follows RFC 3339. You can set an expiration date on
|
|
767
|
-
* any secret on its creation. If you create a secret without specifying an expiration date, the secret does not
|
|
768
|
-
* expire. This parameter is only relevant for Arbitrary and Username-Password secrets.
|
|
769
|
-
*/
|
|
770
|
-
expiration_date?: string;
|
|
771
|
-
/** TTL defines the time-to-live for generated credentials. For IAM-credentials secrets, the TTL defines for how
|
|
772
|
-
* long each generated API key will live. The value can be either an integer specifying the number of seconds, or
|
|
773
|
-
* the string representation of a duration (eg. "120m", “12h”).
|
|
774
|
-
*/
|
|
775
|
-
ttl?: any;
|
|
776
|
-
/** The IAM access groups that define the capabilities of the IAM credentials generated for an IAM secret. This
|
|
777
|
-
* field is relevant only for IAM secrets.
|
|
778
|
-
*/
|
|
779
|
-
access_groups?: string[];
|
|
780
|
-
/** The Cloud Resource Name (CRN) that uniquely identifies your cloud resources. */
|
|
781
|
-
crn?: string;
|
|
782
|
-
/** The date the secret was created. The date format follows RFC 3339. */
|
|
783
|
-
creation_date?: string;
|
|
784
|
-
/** The unique identifier for the entity that created the secret. */
|
|
785
|
-
created_by?: string;
|
|
786
|
-
/** Updates when any part of the secret metadata is modified. The date format follows RFC 3339. */
|
|
787
|
-
last_update_date?: string;
|
|
788
|
-
/** An array containing metadata for each secret version. */
|
|
789
|
-
versions?: SecretVersion[];
|
|
790
|
-
/** SecretResource accepts additional properties. */
|
|
791
|
-
[propName: string]: any;
|
|
792
|
-
}
|
|
793
|
-
/** Properties associated with a specific secret version. */
|
|
794
|
-
interface SecretVersion {
|
|
795
|
-
/** The ID of the secret version. */
|
|
796
|
-
id?: string;
|
|
797
|
-
/** The date that the version of the secret was created. */
|
|
798
|
-
creation_date?: string;
|
|
799
|
-
/** The unique identifier for the resource that created the secret. */
|
|
800
|
-
created_by?: string;
|
|
801
|
-
}
|
|
802
|
-
/** SetEngineConfigOneOf. */
|
|
803
|
-
interface SetEngineConfigOneOf {
|
|
804
|
-
}
|
|
805
|
-
/** Configuration used for IAM credentials generation. */
|
|
806
|
-
interface SetIAMSecretEngineRootConfig {
|
|
807
|
-
/** An API key that has the capability to create IAM serviceIDs. Specifically, it should be assigned an IAM
|
|
808
|
-
* Editor role on both the IAM Identity Service and the IAM Access Groups Service.
|
|
809
|
-
*/
|
|
810
|
-
api_key: string;
|
|
811
|
-
}
|
|
812
|
-
/** The base schema for retrieving a dual authorization secret policy. */
|
|
813
|
-
interface GetSecretPoliciesOneOfGetSecretPolicyRotation extends GetSecretPoliciesOneOf {
|
|
814
|
-
/** The metadata that describes the resource array. */
|
|
815
|
-
metadata: CollectionMetadata;
|
|
816
|
-
/** A collection of resources. */
|
|
817
|
-
resources: GetSecretPoliciesOneOfGetSecretPolicyRotationResourcesItem[];
|
|
818
|
-
}
|
|
819
|
-
/** Delete credentials generated for an IAM secret. */
|
|
820
|
-
interface SecretActionOneOfDeleteCredentialsForIAMSecret extends SecretActionOneOf {
|
|
821
|
-
/** The IAM serviceId that you want to delete. It will be deleted together with its API key. */
|
|
822
|
-
service_id: string;
|
|
823
|
-
}
|
|
824
|
-
/** Base schema for the request body of a rotate action. */
|
|
825
|
-
interface SecretActionOneOfRotateArbitrarySecretBody extends SecretActionOneOf {
|
|
826
|
-
/** The new secret data. */
|
|
827
|
-
payload: string;
|
|
828
|
-
}
|
|
829
|
-
/** Base schema for the request body of a rotate action. */
|
|
830
|
-
interface SecretActionOneOfRotateUsernamePasswordSecretBody extends SecretActionOneOf {
|
|
831
|
-
/** The new secret password. */
|
|
832
|
-
password: string;
|
|
833
|
-
}
|
|
834
|
-
/** Configuration used for IAM credentials generation. */
|
|
835
|
-
interface SetEngineConfigOneOfSetIAMSecretEngineRootConfig extends SetEngineConfigOneOf {
|
|
836
|
-
/** An API key that has the capability to create IAM serviceIDs. Specifically, it should be assigned an IAM
|
|
837
|
-
* Editor role on both the IAM Identity Service and the IAM Access Groups Service.
|
|
838
|
-
*/
|
|
839
|
-
api_key: string;
|
|
840
|
-
}
|
|
841
|
-
}
|
|
842
|
-
export = IbmCloudSecretsManagerApiV1;
|