@databricks/sdk-keyconfigurations 0.0.0-dev → 0.1.0-dev.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/LICENSE +203 -0
- package/dist/v1/client.d.ts +55 -0
- package/dist/v1/client.d.ts.map +1 -0
- package/dist/v1/client.js +163 -0
- package/dist/v1/client.js.map +1 -0
- package/dist/v1/index.d.ts +4 -0
- package/dist/v1/index.d.ts.map +1 -0
- package/dist/v1/index.js +4 -0
- package/dist/v1/index.js.map +1 -0
- package/dist/v1/model.d.ts +188 -0
- package/dist/v1/model.d.ts.map +1 -0
- package/dist/v1/model.js +186 -0
- package/dist/v1/model.js.map +1 -0
- package/dist/v1/transport.d.ts +5 -0
- package/dist/v1/transport.d.ts.map +1 -0
- package/dist/v1/transport.js +57 -0
- package/dist/v1/transport.js.map +1 -0
- package/dist/v1/utils.d.ts +21 -0
- package/dist/v1/utils.d.ts.map +1 -0
- package/dist/v1/utils.js +113 -0
- package/dist/v1/utils.js.map +1 -0
- package/package.json +38 -4
- package/src/v1/client.ts +209 -0
- package/src/v1/index.ts +22 -0
- package/src/v1/model.ts +373 -0
- package/src/v1/transport.ts +73 -0
- package/src/v1/utils.ts +156 -0
- package/README.md +0 -1
- package/index.js +0 -1
package/LICENSE
ADDED
|
@@ -0,0 +1,203 @@
|
|
|
1
|
+
Copyright 2026 Databricks, Inc. All rights reserved.
|
|
2
|
+
|
|
3
|
+
Apache License
|
|
4
|
+
Version 2.0, January 2004
|
|
5
|
+
http://www.apache.org/licenses/
|
|
6
|
+
|
|
7
|
+
TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
|
|
8
|
+
|
|
9
|
+
1. Definitions.
|
|
10
|
+
|
|
11
|
+
"License" shall mean the terms and conditions for use, reproduction,
|
|
12
|
+
and distribution as defined by Sections 1 through 9 of this document.
|
|
13
|
+
|
|
14
|
+
"Licensor" shall mean the copyright owner or entity authorized by
|
|
15
|
+
the copyright owner that is granting the License.
|
|
16
|
+
|
|
17
|
+
"Legal Entity" shall mean the union of the acting entity and all
|
|
18
|
+
other entities that control, are controlled by, or are under common
|
|
19
|
+
control with that entity. For the purposes of this definition,
|
|
20
|
+
"control" means (i) the power, direct or indirect, to cause the
|
|
21
|
+
direction or management of such entity, whether by contract or
|
|
22
|
+
otherwise, or (ii) ownership of fifty percent (50%) or more of the
|
|
23
|
+
outstanding shares, or (iii) beneficial ownership of such entity.
|
|
24
|
+
|
|
25
|
+
"You" (or "Your") shall mean an individual or Legal Entity
|
|
26
|
+
exercising permissions granted by this License.
|
|
27
|
+
|
|
28
|
+
"Source" form shall mean the preferred form for making modifications,
|
|
29
|
+
including but not limited to software source code, documentation
|
|
30
|
+
source, and configuration files.
|
|
31
|
+
|
|
32
|
+
"Object" form shall mean any form resulting from mechanical
|
|
33
|
+
transformation or translation of a Source form, including but
|
|
34
|
+
not limited to compiled object code, generated documentation,
|
|
35
|
+
and conversions to other media types.
|
|
36
|
+
|
|
37
|
+
"Work" shall mean the work of authorship, whether in Source or
|
|
38
|
+
Object form, made available under the License, as indicated by a
|
|
39
|
+
copyright notice that is included in or attached to the work
|
|
40
|
+
(an example is provided in the Appendix below).
|
|
41
|
+
|
|
42
|
+
"Derivative Works" shall mean any work, whether in Source or Object
|
|
43
|
+
form, that is based on (or derived from) the Work and for which the
|
|
44
|
+
editorial revisions, annotations, elaborations, or other modifications
|
|
45
|
+
represent, as a whole, an original work of authorship. For the purposes
|
|
46
|
+
of this License, Derivative Works shall not include works that remain
|
|
47
|
+
separable from, or merely link (or bind by name) to the interfaces of,
|
|
48
|
+
the Work and Derivative Works thereof.
|
|
49
|
+
|
|
50
|
+
"Contribution" shall mean any work of authorship, including
|
|
51
|
+
the original version of the Work and any modifications or additions
|
|
52
|
+
to that Work or Derivative Works thereof, that is intentionally
|
|
53
|
+
submitted to Licensor for inclusion in the Work by the copyright owner
|
|
54
|
+
or by an individual or Legal Entity authorized to submit on behalf of
|
|
55
|
+
the copyright owner. For the purposes of this definition, "submitted"
|
|
56
|
+
means any form of electronic, verbal, or written communication sent
|
|
57
|
+
to the Licensor or its representatives, including but not limited to
|
|
58
|
+
communication on electronic mailing lists, source code control systems,
|
|
59
|
+
and issue tracking systems that are managed by, or on behalf of, the
|
|
60
|
+
Licensor for the purpose of discussing and improving the Work, but
|
|
61
|
+
excluding communication that is conspicuously marked or otherwise
|
|
62
|
+
designated in writing by the copyright owner as "Not a Contribution."
|
|
63
|
+
|
|
64
|
+
"Contributor" shall mean Licensor and any individual or Legal Entity
|
|
65
|
+
on behalf of whom a Contribution has been received by Licensor and
|
|
66
|
+
subsequently incorporated within the Work.
|
|
67
|
+
|
|
68
|
+
2. Grant of Copyright License. Subject to the terms and conditions of
|
|
69
|
+
this License, each Contributor hereby grants to You a perpetual,
|
|
70
|
+
worldwide, non-exclusive, no-charge, royalty-free, irrevocable
|
|
71
|
+
copyright license to reproduce, prepare Derivative Works of,
|
|
72
|
+
publicly display, publicly perform, sublicense, and distribute the
|
|
73
|
+
Work and such Derivative Works in Source or Object form.
|
|
74
|
+
|
|
75
|
+
3. Grant of Patent License. Subject to the terms and conditions of
|
|
76
|
+
this License, each Contributor hereby grants to You a perpetual,
|
|
77
|
+
worldwide, non-exclusive, no-charge, royalty-free, irrevocable
|
|
78
|
+
(except as stated in this section) patent license to make, have made,
|
|
79
|
+
use, offer to sell, sell, import, and otherwise transfer the Work,
|
|
80
|
+
where such license applies only to those patent claims licensable
|
|
81
|
+
by such Contributor that are necessarily infringed by their
|
|
82
|
+
Contribution(s) alone or by combination of their Contribution(s)
|
|
83
|
+
with the Work to which such Contribution(s) was submitted. If You
|
|
84
|
+
institute patent litigation against any entity (including a
|
|
85
|
+
cross-claim or counterclaim in a lawsuit) alleging that the Work
|
|
86
|
+
or a Contribution incorporated within the Work constitutes direct
|
|
87
|
+
or contributory patent infringement, then any patent licenses
|
|
88
|
+
granted to You under this License for that Work shall terminate
|
|
89
|
+
as of the date such litigation is filed.
|
|
90
|
+
|
|
91
|
+
4. Redistribution. You may reproduce and distribute copies of the
|
|
92
|
+
Work or Derivative Works thereof in any medium, with or without
|
|
93
|
+
modifications, and in Source or Object form, provided that You
|
|
94
|
+
meet the following conditions:
|
|
95
|
+
|
|
96
|
+
(a) You must give any other recipients of the Work or
|
|
97
|
+
Derivative Works a copy of this License; and
|
|
98
|
+
|
|
99
|
+
(b) You must cause any modified files to carry prominent notices
|
|
100
|
+
stating that You changed the files; and
|
|
101
|
+
|
|
102
|
+
(c) You must retain, in the Source form of any Derivative Works
|
|
103
|
+
that You distribute, all copyright, patent, trademark, and
|
|
104
|
+
attribution notices from the Source form of the Work,
|
|
105
|
+
excluding those notices that do not pertain to any part of
|
|
106
|
+
the Derivative Works; and
|
|
107
|
+
|
|
108
|
+
(d) If the Work includes a "NOTICE" text file as part of its
|
|
109
|
+
distribution, then any Derivative Works that You distribute must
|
|
110
|
+
include a readable copy of the attribution notices contained
|
|
111
|
+
within such NOTICE file, excluding those notices that do not
|
|
112
|
+
pertain to any part of the Derivative Works, in at least one
|
|
113
|
+
of the following places: within a NOTICE text file distributed
|
|
114
|
+
as part of the Derivative Works; within the Source form or
|
|
115
|
+
documentation, if provided along with the Derivative Works; or,
|
|
116
|
+
within a display generated by the Derivative Works, if and
|
|
117
|
+
wherever such third-party notices normally appear. The contents
|
|
118
|
+
of the NOTICE file are for informational purposes only and
|
|
119
|
+
do not modify the License. You may add Your own attribution
|
|
120
|
+
notices within Derivative Works that You distribute, alongside
|
|
121
|
+
or as an addendum to the NOTICE text from the Work, provided
|
|
122
|
+
that such additional attribution notices cannot be construed
|
|
123
|
+
as modifying the License.
|
|
124
|
+
|
|
125
|
+
You may add Your own copyright statement to Your modifications and
|
|
126
|
+
may provide additional or different license terms and conditions
|
|
127
|
+
for use, reproduction, or distribution of Your modifications, or
|
|
128
|
+
for any such Derivative Works as a whole, provided Your use,
|
|
129
|
+
reproduction, and distribution of the Work otherwise complies with
|
|
130
|
+
the conditions stated in this License.
|
|
131
|
+
|
|
132
|
+
5. Submission of Contributions. Unless You explicitly state otherwise,
|
|
133
|
+
any Contribution intentionally submitted for inclusion in the Work
|
|
134
|
+
by You to the Licensor shall be under the terms and conditions of
|
|
135
|
+
this License, without any additional terms or conditions.
|
|
136
|
+
Notwithstanding the above, nothing herein shall supersede or modify
|
|
137
|
+
the terms of any separate license agreement you may have executed
|
|
138
|
+
with Licensor regarding such Contributions.
|
|
139
|
+
|
|
140
|
+
6. Trademarks. This License does not grant permission to use the trade
|
|
141
|
+
names, trademarks, service marks, or product names of the Licensor,
|
|
142
|
+
except as required for reasonable and customary use in describing the
|
|
143
|
+
origin of the Work and reproducing the content of the NOTICE file.
|
|
144
|
+
|
|
145
|
+
7. Disclaimer of Warranty. Unless required by applicable law or
|
|
146
|
+
agreed to in writing, Licensor provides the Work (and each
|
|
147
|
+
Contributor provides its Contributions) on an "AS IS" BASIS,
|
|
148
|
+
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
|
|
149
|
+
implied, including, without limitation, any warranties or conditions
|
|
150
|
+
of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
|
|
151
|
+
PARTICULAR PURPOSE. You are solely responsible for determining the
|
|
152
|
+
appropriateness of using or redistributing the Work and assume any
|
|
153
|
+
risks associated with Your exercise of permissions under this License.
|
|
154
|
+
|
|
155
|
+
8. Limitation of Liability. In no event and under no legal theory,
|
|
156
|
+
whether in tort (including negligence), contract, or otherwise,
|
|
157
|
+
unless required by applicable law (such as deliberate and grossly
|
|
158
|
+
negligent acts) or agreed to in writing, shall any Contributor be
|
|
159
|
+
liable to You for damages, including any direct, indirect, special,
|
|
160
|
+
incidental, or consequential damages of any character arising as a
|
|
161
|
+
result of this License or out of the use or inability to use the
|
|
162
|
+
Work (including but not limited to damages for loss of goodwill,
|
|
163
|
+
work stoppage, computer failure or malfunction, or any and all
|
|
164
|
+
other commercial damages or losses), even if such Contributor
|
|
165
|
+
has been advised of the possibility of such damages.
|
|
166
|
+
|
|
167
|
+
9. Accepting Warranty or Additional Liability. While redistributing
|
|
168
|
+
the Work or Derivative Works thereof, You may choose to offer,
|
|
169
|
+
and charge a fee for, acceptance of support, warranty, indemnity,
|
|
170
|
+
or other liability obligations and/or rights consistent with this
|
|
171
|
+
License. However, in accepting such obligations, You may act only
|
|
172
|
+
on Your own behalf and on Your sole responsibility, not on behalf
|
|
173
|
+
of any other Contributor, and only if You agree to indemnify,
|
|
174
|
+
defend, and hold each Contributor harmless for any liability
|
|
175
|
+
incurred by, or claims asserted against, such Contributor by reason
|
|
176
|
+
of your accepting any such warranty or additional liability.
|
|
177
|
+
|
|
178
|
+
END OF TERMS AND CONDITIONS
|
|
179
|
+
|
|
180
|
+
APPENDIX: How to apply the Apache License to your work.
|
|
181
|
+
|
|
182
|
+
To apply the Apache License to your work, attach the following
|
|
183
|
+
boilerplate notice, with the fields enclosed by brackets "[]"
|
|
184
|
+
replaced with your own identifying information. (Don't include
|
|
185
|
+
the brackets!) The text should be enclosed in the appropriate
|
|
186
|
+
comment syntax for the file format. We also recommend that a
|
|
187
|
+
file or class name and description of purpose be included on the
|
|
188
|
+
same "printed page" as the copyright notice for easier
|
|
189
|
+
identification within third-party archives.
|
|
190
|
+
|
|
191
|
+
Copyright [yyyy] [name of copyright owner]
|
|
192
|
+
|
|
193
|
+
Licensed under the Apache License, Version 2.0 (the "License");
|
|
194
|
+
you may not use this file except in compliance with the License.
|
|
195
|
+
You may obtain a copy of the License at
|
|
196
|
+
|
|
197
|
+
http://www.apache.org/licenses/LICENSE-2.0
|
|
198
|
+
|
|
199
|
+
Unless required by applicable law or agreed to in writing, software
|
|
200
|
+
distributed under the License is distributed on an "AS IS" BASIS,
|
|
201
|
+
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
202
|
+
See the License for the specific language governing permissions and
|
|
203
|
+
limitations under the License.
|
|
@@ -0,0 +1,55 @@
|
|
|
1
|
+
import type { CallOptions } from '@databricks/sdk-options/call';
|
|
2
|
+
import type { ClientOptions } from '@databricks/sdk-options/client';
|
|
3
|
+
import type { CreateCustomerManagedKeyRequest, CustomerManagedKey, DeleteCustomerManagedKeyRequest, GetCustomerManagedKeyRequest, ListCustomerManagedKeyRequest, ListCustomerManagedKeyResponse } from './model';
|
|
4
|
+
export declare class KeyConfigurationsClient {
|
|
5
|
+
private readonly host;
|
|
6
|
+
private readonly accountId;
|
|
7
|
+
private readonly httpClient;
|
|
8
|
+
private readonly logger;
|
|
9
|
+
private readonly userAgent;
|
|
10
|
+
constructor(options: ClientOptions);
|
|
11
|
+
/**
|
|
12
|
+
* Creates a customer-managed key configuration object for an account, specified by ID.
|
|
13
|
+
* This operation uploads a reference to a customer-managed key to <Databricks>.
|
|
14
|
+
* If the key is assigned as a workspace's customer-managed key for managed services,
|
|
15
|
+
* <Databricks> uses the key to encrypt the workspaces notebooks and secrets in the control plane,
|
|
16
|
+
* in addition to Databricks SQL queries and query history. If it is specified as a
|
|
17
|
+
* workspace's customer-managed key for workspace storage, the key encrypts the
|
|
18
|
+
* workspace's root S3 bucket (which contains the workspace's root DBFS and system data)
|
|
19
|
+
* and, optionally, cluster EBS volume data.
|
|
20
|
+
*
|
|
21
|
+
* **Important**: Customer-managed keys are supported only for some deployment types,
|
|
22
|
+
* subscription types, and AWS regions that currently support creation of <Databricks> workspaces.
|
|
23
|
+
*
|
|
24
|
+
* This operation is available only if your account is on the E2 version of the
|
|
25
|
+
* platform or on a select custom plan that allows multiple workspaces per account.
|
|
26
|
+
*
|
|
27
|
+
* **GCP only**: To create a customer-managed key on GCP, you must include the
|
|
28
|
+
* `X-Databricks-GCP-SA-Access-Token` HTTP header in your request. This header must contain
|
|
29
|
+
* a Google Cloud OAuth access token with the `cloud-platform` scope. The Google identity
|
|
30
|
+
* associated with the token must also have the `setIamPermissions` and `getIamPermissions`
|
|
31
|
+
* IAM permissions on the key resource. For details on obtaining this token, see
|
|
32
|
+
* [Authenticate with Google ID tokens](https://docs.databricks.com/gcp/en/dev-tools/auth/authentication-google-id.html).
|
|
33
|
+
*/
|
|
34
|
+
createCustomerManagedKeyPublic(req: CreateCustomerManagedKeyRequest, options?: CallOptions): Promise<CustomerManagedKey>;
|
|
35
|
+
/** Deletes a customer-managed key configuration object for an account. You cannot delete a configuration that is associated with a running workspace. */
|
|
36
|
+
deleteCustomerManagedKeyPublic(req: DeleteCustomerManagedKeyRequest, options?: CallOptions): Promise<CustomerManagedKey>;
|
|
37
|
+
/**
|
|
38
|
+
* Gets a customer-managed key configuration object for an account, specified by ID.
|
|
39
|
+
* This operation uploads a reference to a customer-managed key to <Databricks>.
|
|
40
|
+
* If assigned as a workspace's customer-managed key for managed services, <Databricks> uses the
|
|
41
|
+
* key to encrypt the workspaces notebooks and secrets in the control plane, in addition to
|
|
42
|
+
* Databricks SQL queries and query history. If it is specified as a workspace's
|
|
43
|
+
* customer-managed key for storage, the key encrypts the workspace's root S3 bucket
|
|
44
|
+
* (which contains the workspace's root DBFS and system data) and, optionally, cluster EBS volume data.
|
|
45
|
+
*
|
|
46
|
+
* **Important**: Customer-managed keys are supported only for some deployment types,
|
|
47
|
+
* subscription types, and AWS regions.
|
|
48
|
+
*
|
|
49
|
+
* This operation is available only if your account is on the E2 version of the platform.",
|
|
50
|
+
*/
|
|
51
|
+
getCustomerManagedKeyPublic(req: GetCustomerManagedKeyRequest, options?: CallOptions): Promise<CustomerManagedKey>;
|
|
52
|
+
/** Lists <Databricks> customer-managed key configurations for an account. */
|
|
53
|
+
listCustomerManagedKeyPublic(req: ListCustomerManagedKeyRequest, options?: CallOptions): Promise<ListCustomerManagedKeyResponse>;
|
|
54
|
+
}
|
|
55
|
+
//# sourceMappingURL=client.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"client.d.ts","sourceRoot":"","sources":["../../src/v1/client.ts"],"names":[],"mappings":"AAMA,OAAO,KAAK,EAAC,WAAW,EAAC,MAAM,8BAA8B,CAAC;AAC9D,OAAO,KAAK,EAAC,aAAa,EAAC,MAAM,gCAAgC,CAAC;AAYlE,OAAO,KAAK,EACV,+BAA+B,EAC/B,kBAAkB,EAClB,+BAA+B,EAC/B,4BAA4B,EAC5B,6BAA6B,EAC7B,8BAA8B,EAC/B,MAAM,SAAS,CAAC;AAYjB,qBAAa,uBAAuB;IAClC,OAAO,CAAC,QAAQ,CAAC,IAAI,CAAS;IAG9B,OAAO,CAAC,QAAQ,CAAC,SAAS,CAAqB;IAC/C,OAAO,CAAC,QAAQ,CAAC,UAAU,CAAa;IACxC,OAAO,CAAC,QAAQ,CAAC,MAAM,CAAS;IAIhC,OAAO,CAAC,QAAQ,CAAC,SAAS,CAAS;gBAEvB,OAAO,EAAE,aAAa;IAelC;;;;;;;;;;;;;;;;;;;;;;OAsBG;IACG,8BAA8B,CAClC,GAAG,EAAE,+BAA+B,EACpC,OAAO,CAAC,EAAE,WAAW,GACpB,OAAO,CAAC,kBAAkB,CAAC;IAyB9B,yJAAyJ;IACnJ,8BAA8B,CAClC,GAAG,EAAE,+BAA+B,EACpC,OAAO,CAAC,EAAE,WAAW,GACpB,OAAO,CAAC,kBAAkB,CAAC;IAqB9B;;;;;;;;;;;;;OAaG;IACG,2BAA2B,CAC/B,GAAG,EAAE,4BAA4B,EACjC,OAAO,CAAC,EAAE,WAAW,GACpB,OAAO,CAAC,kBAAkB,CAAC;IAqB9B,6EAA6E;IACvE,4BAA4B,CAChC,GAAG,EAAE,6BAA6B,EAClC,OAAO,CAAC,EAAE,WAAW,GACpB,OAAO,CAAC,8BAA8B,CAAC;CAyB3C"}
|
|
@@ -0,0 +1,163 @@
|
|
|
1
|
+
// Code generated from API definition by Databricks SDK Generator. DO NOT EDIT.
|
|
2
|
+
import { VERSION as AUTH_VERSION } from '@databricks/sdk-auth';
|
|
3
|
+
import { createDefault } from '@databricks/sdk-core/clientinfo';
|
|
4
|
+
import { NoOpLogger } from '@databricks/sdk-core/logger';
|
|
5
|
+
import { newHttpClient } from './transport';
|
|
6
|
+
import { buildHttpRequest, executeCall, executeHttpCall, marshalRequest, parseResponse, } from './utils';
|
|
7
|
+
import pkgJson from '../../package.json' with { type: 'json' };
|
|
8
|
+
import { z } from 'zod';
|
|
9
|
+
import { marshalCreateCustomerManagedKeyRequestSchema, unmarshalCustomerManagedKeySchema, } from './model';
|
|
10
|
+
// Package identity segment for this client to be used in the User-Agent header.
|
|
11
|
+
const PACKAGE_SEGMENT = {
|
|
12
|
+
key: 'sdk-js-' + pkgJson.name.replace(/^@[^/]+\/sdk-/, ''),
|
|
13
|
+
value: pkgJson.version,
|
|
14
|
+
};
|
|
15
|
+
export class KeyConfigurationsClient {
|
|
16
|
+
host;
|
|
17
|
+
// Fallback for endpoints whose path contains {account_id}. If the request
|
|
18
|
+
// already carries an accountId, that value wins.
|
|
19
|
+
accountId;
|
|
20
|
+
httpClient;
|
|
21
|
+
logger;
|
|
22
|
+
// User-Agent header value. Composed once at construction from
|
|
23
|
+
// createDefault() merged with this package's identity and the active
|
|
24
|
+
// credential's name.
|
|
25
|
+
userAgent;
|
|
26
|
+
constructor(options) {
|
|
27
|
+
if (options.host === undefined) {
|
|
28
|
+
throw new Error('Host is required.');
|
|
29
|
+
}
|
|
30
|
+
this.host = options.host.replace(/\/$/, '');
|
|
31
|
+
this.accountId = options.accountId;
|
|
32
|
+
this.logger = options.logger ?? new NoOpLogger();
|
|
33
|
+
const info = createDefault()
|
|
34
|
+
.with(PACKAGE_SEGMENT)
|
|
35
|
+
.with({ key: 'sdk-js-auth', value: AUTH_VERSION })
|
|
36
|
+
.with({ key: 'auth', value: options.credentials?.name() ?? 'default' });
|
|
37
|
+
this.userAgent = info.toString();
|
|
38
|
+
this.httpClient = newHttpClient(options);
|
|
39
|
+
}
|
|
40
|
+
/**
|
|
41
|
+
* Creates a customer-managed key configuration object for an account, specified by ID.
|
|
42
|
+
* This operation uploads a reference to a customer-managed key to <Databricks>.
|
|
43
|
+
* If the key is assigned as a workspace's customer-managed key for managed services,
|
|
44
|
+
* <Databricks> uses the key to encrypt the workspaces notebooks and secrets in the control plane,
|
|
45
|
+
* in addition to Databricks SQL queries and query history. If it is specified as a
|
|
46
|
+
* workspace's customer-managed key for workspace storage, the key encrypts the
|
|
47
|
+
* workspace's root S3 bucket (which contains the workspace's root DBFS and system data)
|
|
48
|
+
* and, optionally, cluster EBS volume data.
|
|
49
|
+
*
|
|
50
|
+
* **Important**: Customer-managed keys are supported only for some deployment types,
|
|
51
|
+
* subscription types, and AWS regions that currently support creation of <Databricks> workspaces.
|
|
52
|
+
*
|
|
53
|
+
* This operation is available only if your account is on the E2 version of the
|
|
54
|
+
* platform or on a select custom plan that allows multiple workspaces per account.
|
|
55
|
+
*
|
|
56
|
+
* **GCP only**: To create a customer-managed key on GCP, you must include the
|
|
57
|
+
* `X-Databricks-GCP-SA-Access-Token` HTTP header in your request. This header must contain
|
|
58
|
+
* a Google Cloud OAuth access token with the `cloud-platform` scope. The Google identity
|
|
59
|
+
* associated with the token must also have the `setIamPermissions` and `getIamPermissions`
|
|
60
|
+
* IAM permissions on the key resource. For details on obtaining this token, see
|
|
61
|
+
* [Authenticate with Google ID tokens](https://docs.databricks.com/gcp/en/dev-tools/auth/authentication-google-id.html).
|
|
62
|
+
*/
|
|
63
|
+
async createCustomerManagedKeyPublic(req, options) {
|
|
64
|
+
const url = `${this.host}/api/2.0/accounts/${req.accountId ?? this.accountId ?? ''}/customer-managed-keys`;
|
|
65
|
+
const body = marshalRequest(req, marshalCreateCustomerManagedKeyRequestSchema);
|
|
66
|
+
let resp;
|
|
67
|
+
const call = async (callSignal) => {
|
|
68
|
+
const headers = new Headers({ 'Content-Type': 'application/json' });
|
|
69
|
+
headers.set('User-Agent', this.userAgent);
|
|
70
|
+
const httpReq = buildHttpRequest('POST', url, headers, callSignal, body);
|
|
71
|
+
const respBody = await executeHttpCall({
|
|
72
|
+
request: httpReq,
|
|
73
|
+
httpClient: this.httpClient,
|
|
74
|
+
logger: this.logger,
|
|
75
|
+
});
|
|
76
|
+
resp = parseResponse(respBody, unmarshalCustomerManagedKeySchema);
|
|
77
|
+
};
|
|
78
|
+
await executeCall(call, options);
|
|
79
|
+
if (resp === undefined) {
|
|
80
|
+
throw new Error('operation completed without a result.');
|
|
81
|
+
}
|
|
82
|
+
return resp;
|
|
83
|
+
}
|
|
84
|
+
/** Deletes a customer-managed key configuration object for an account. You cannot delete a configuration that is associated with a running workspace. */
|
|
85
|
+
async deleteCustomerManagedKeyPublic(req, options) {
|
|
86
|
+
const url = `${this.host}/api/2.0/accounts/${req.accountId ?? this.accountId ?? ''}/customer-managed-keys/${req.customerManagedKeyId ?? ''}`;
|
|
87
|
+
let resp;
|
|
88
|
+
const call = async (callSignal) => {
|
|
89
|
+
const headers = new Headers();
|
|
90
|
+
headers.set('User-Agent', this.userAgent);
|
|
91
|
+
const httpReq = buildHttpRequest('DELETE', url, headers, callSignal);
|
|
92
|
+
const respBody = await executeHttpCall({
|
|
93
|
+
request: httpReq,
|
|
94
|
+
httpClient: this.httpClient,
|
|
95
|
+
logger: this.logger,
|
|
96
|
+
});
|
|
97
|
+
resp = parseResponse(respBody, unmarshalCustomerManagedKeySchema);
|
|
98
|
+
};
|
|
99
|
+
await executeCall(call, options);
|
|
100
|
+
if (resp === undefined) {
|
|
101
|
+
throw new Error('operation completed without a result.');
|
|
102
|
+
}
|
|
103
|
+
return resp;
|
|
104
|
+
}
|
|
105
|
+
/**
|
|
106
|
+
* Gets a customer-managed key configuration object for an account, specified by ID.
|
|
107
|
+
* This operation uploads a reference to a customer-managed key to <Databricks>.
|
|
108
|
+
* If assigned as a workspace's customer-managed key for managed services, <Databricks> uses the
|
|
109
|
+
* key to encrypt the workspaces notebooks and secrets in the control plane, in addition to
|
|
110
|
+
* Databricks SQL queries and query history. If it is specified as a workspace's
|
|
111
|
+
* customer-managed key for storage, the key encrypts the workspace's root S3 bucket
|
|
112
|
+
* (which contains the workspace's root DBFS and system data) and, optionally, cluster EBS volume data.
|
|
113
|
+
*
|
|
114
|
+
* **Important**: Customer-managed keys are supported only for some deployment types,
|
|
115
|
+
* subscription types, and AWS regions.
|
|
116
|
+
*
|
|
117
|
+
* This operation is available only if your account is on the E2 version of the platform.",
|
|
118
|
+
*/
|
|
119
|
+
async getCustomerManagedKeyPublic(req, options) {
|
|
120
|
+
const url = `${this.host}/api/2.0/accounts/${req.accountId ?? this.accountId ?? ''}/customer-managed-keys/${req.customerManagedKeyId ?? ''}`;
|
|
121
|
+
let resp;
|
|
122
|
+
const call = async (callSignal) => {
|
|
123
|
+
const headers = new Headers();
|
|
124
|
+
headers.set('User-Agent', this.userAgent);
|
|
125
|
+
const httpReq = buildHttpRequest('GET', url, headers, callSignal);
|
|
126
|
+
const respBody = await executeHttpCall({
|
|
127
|
+
request: httpReq,
|
|
128
|
+
httpClient: this.httpClient,
|
|
129
|
+
logger: this.logger,
|
|
130
|
+
});
|
|
131
|
+
resp = parseResponse(respBody, unmarshalCustomerManagedKeySchema);
|
|
132
|
+
};
|
|
133
|
+
await executeCall(call, options);
|
|
134
|
+
if (resp === undefined) {
|
|
135
|
+
throw new Error('operation completed without a result.');
|
|
136
|
+
}
|
|
137
|
+
return resp;
|
|
138
|
+
}
|
|
139
|
+
/** Lists <Databricks> customer-managed key configurations for an account. */
|
|
140
|
+
async listCustomerManagedKeyPublic(req, options) {
|
|
141
|
+
const url = `${this.host}/api/2.0/accounts/${req.accountId ?? this.accountId ?? ''}/customer-managed-keys`;
|
|
142
|
+
let resp;
|
|
143
|
+
const call = async (callSignal) => {
|
|
144
|
+
const headers = new Headers();
|
|
145
|
+
headers.set('User-Agent', this.userAgent);
|
|
146
|
+
const httpReq = buildHttpRequest('GET', url, headers, callSignal);
|
|
147
|
+
const respBody = await executeHttpCall({
|
|
148
|
+
request: httpReq,
|
|
149
|
+
httpClient: this.httpClient,
|
|
150
|
+
logger: this.logger,
|
|
151
|
+
});
|
|
152
|
+
resp = {
|
|
153
|
+
customerManagedKeys: parseResponse(respBody, z.array(z.lazy(() => unmarshalCustomerManagedKeySchema))),
|
|
154
|
+
};
|
|
155
|
+
};
|
|
156
|
+
await executeCall(call, options);
|
|
157
|
+
if (resp === undefined) {
|
|
158
|
+
throw new Error('operation completed without a result.');
|
|
159
|
+
}
|
|
160
|
+
return resp;
|
|
161
|
+
}
|
|
162
|
+
}
|
|
163
|
+
//# sourceMappingURL=client.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"client.js","sourceRoot":"","sources":["../../src/v1/client.ts"],"names":[],"mappings":"AAAA,+EAA+E;AAE/E,OAAO,EAAC,OAAO,IAAI,YAAY,EAAC,MAAM,sBAAsB,CAAC;AAC7D,OAAO,EAAC,aAAa,EAAC,MAAM,iCAAiC,CAAC;AAE9D,OAAO,EAAC,UAAU,EAAC,MAAM,6BAA6B,CAAC;AAIvD,OAAO,EAAC,aAAa,EAAC,MAAM,aAAa,CAAC;AAC1C,OAAO,EACL,gBAAgB,EAChB,WAAW,EACX,eAAe,EACf,cAAc,EACd,aAAa,GACd,MAAM,SAAS,CAAC;AACjB,OAAO,OAAO,MAAM,oBAAoB,CAAC,OAAM,IAAI,EAAE,MAAM,EAAC,CAAC;AAC7D,OAAO,EAAC,CAAC,EAAC,MAAM,KAAK,CAAC;AAStB,OAAO,EACL,4CAA4C,EAC5C,iCAAiC,GAClC,MAAM,SAAS,CAAC;AAEjB,gFAAgF;AAChF,MAAM,eAAe,GAAG;IACtB,GAAG,EAAE,SAAS,GAAG,OAAO,CAAC,IAAI,CAAC,OAAO,CAAC,eAAe,EAAE,EAAE,CAAC;IAC1D,KAAK,EAAE,OAAO,CAAC,OAAO;CACvB,CAAC;AAEF,MAAM,OAAO,uBAAuB;IACjB,IAAI,CAAS;IAC9B,0EAA0E;IAC1E,iDAAiD;IAChC,SAAS,CAAqB;IAC9B,UAAU,CAAa;IACvB,MAAM,CAAS;IAChC,8DAA8D;IAC9D,qEAAqE;IACrE,qBAAqB;IACJ,SAAS,CAAS;IAEnC,YAAY,OAAsB;QAChC,IAAI,OAAO,CAAC,IAAI,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AAC;QACD,OAAO,IAAI,CAAC;IACd,CAAC;IAED,6EAA6E;IAC7E,KAAK,CAAC,4BAA4B,CAChC,GAAkC,EAClC,OAAqB;QAErB,MAAM,GAAG,GAAG,GAAG,IAAI,CAAC,IAAI,qBAAqB,GAAG,CAAC,SAAS,IAAI,IAAI,CAAC,SAAS,IAAI,EAAE,wBAAwB,CAAC;QAC3G,IAAI,IAAgD,CAAC;QACrD,MAAM,IAAI,GAAG,KAAK,EAAE,UAAwB,EAAiB,EAAE;YAC7D,MAAM,OAAO,GAAG,IAAI,OAAO,EAAE,CAAC;YAC9B,OAAO,CAAC,GAAG,CAAC,YAAY,EAAE,IAAI,CAAC,SAAS,CAAC,CAAC;YAC1C,MAAM,OAAO,GAAG,gBAAgB,CAAC,KAAK,EAAE,GAAG,EAAE,OAAO,EAAE,UAAU,CAAC,CAAC;YAClE,MAAM,QAAQ,GAAG,MAAM,eAAe,CAAC;gBACrC,OAAO,EAAE,OAAO;gBAChB,UAAU,EAAE,IAAI,CAAC,UAAU;gBAC3B,MAAM,EAAE,IAAI,CAAC,MAAM;aACpB,CAAC,CAAC;YACH,IAAI,GAAG;gBACL,mBAAmB,EAAE,aAAa,CAChC,QAAQ,EACR,CAAC,CAAC,KAAK,CAAC,CAAC,CAAC,IAAI,CAAC,GAAG,EAAE,CAAC,iCAAiC,CAAC,CAAC,CACzD;aACF,CAAC;QACJ,CAAC,CAAC;QACF,MAAM,WAAW,CAAC,IAAI,EAAE,OAAO,CAAC,CAAC;QACjC,IAAI,IAAI,KAAK,SAAS,EAAE,CAAC;YACvB,MAAM,IAAI,KAAK,CAAC,uCAAuC,CAAC,CAAC;QAC3D,CAAC;QACD,OAAO,IAAI,CAAC;IACd,CAAC;CACF"}
|
|
@@ -0,0 +1,4 @@
|
|
|
1
|
+
export { KeyConfigurationsClient } from './client';
|
|
2
|
+
export { CmkUseCase } from './model';
|
|
3
|
+
export type { AwsKeyInfo, AzureKeyInfo, CreateAwsKeyInfo, CreateAzureKeyInfo, CreateCustomerManagedKeyRequest, CreateGcpKeyInfo, CustomerManagedKey, DeleteCustomerManagedKeyRequest, GcpKeyInfo, GcpServiceAccount, GetCustomerManagedKeyRequest, KeyAccessConfiguration, ListCustomerManagedKeyRequest, ListCustomerManagedKeyResponse, } from './model';
|
|
4
|
+
//# sourceMappingURL=index.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/v1/index.ts"],"names":[],"mappings":"AAEA,OAAO,EAAC,uBAAuB,EAAC,MAAM,UAAU,CAAC;AAEjD,OAAO,EAAC,UAAU,EAAC,MAAM,SAAS,CAAC;AAEnC,YAAY,EACV,UAAU,EACV,YAAY,EACZ,gBAAgB,EAChB,kBAAkB,EAClB,+BAA+B,EAC/B,gBAAgB,EAChB,kBAAkB,EAClB,+BAA+B,EAC/B,UAAU,EACV,iBAAiB,EACjB,4BAA4B,EAC5B,sBAAsB,EACtB,6BAA6B,EAC7B,8BAA8B,GAC/B,MAAM,SAAS,CAAC"}
|
package/dist/v1/index.js
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/v1/index.ts"],"names":[],"mappings":"AAAA,+EAA+E;AAE/E,OAAO,EAAC,uBAAuB,EAAC,MAAM,UAAU,CAAC;AAEjD,OAAO,EAAC,UAAU,EAAC,MAAM,SAAS,CAAC"}
|
|
@@ -0,0 +1,188 @@
|
|
|
1
|
+
import { z } from 'zod';
|
|
2
|
+
export declare enum CmkUseCase {
|
|
3
|
+
/** Encryption for the control plane resources. */
|
|
4
|
+
MANAGED_SERVICES = "MANAGED_SERVICES",
|
|
5
|
+
/** Encryption for the customer cloud resources. */
|
|
6
|
+
STORAGE = "STORAGE"
|
|
7
|
+
}
|
|
8
|
+
export interface AwsKeyInfo {
|
|
9
|
+
/** The AWS KMS key's Amazon Resource Name (ARN). */
|
|
10
|
+
keyArn?: string | undefined;
|
|
11
|
+
/** The AWS KMS key alias. */
|
|
12
|
+
keyAlias?: string | undefined;
|
|
13
|
+
/** The AWS KMS key region. */
|
|
14
|
+
keyRegion?: string | undefined;
|
|
15
|
+
/**
|
|
16
|
+
* This field applies only if the `use_cases` property includes `STORAGE`. If this is set to true or omitted, the key is also used to encrypt
|
|
17
|
+
* cluster EBS volumes. If you do not want to use this key for encrypting EBS volumes, set to false.
|
|
18
|
+
*/
|
|
19
|
+
reuseKeyForClusterVolumes?: boolean | undefined;
|
|
20
|
+
}
|
|
21
|
+
export interface AzureKeyInfo {
|
|
22
|
+
/** The base URI of the KeyVault. */
|
|
23
|
+
keyVaultUri?: string | undefined;
|
|
24
|
+
/** The name of the key in KeyVault. */
|
|
25
|
+
keyName?: string | undefined;
|
|
26
|
+
/** The current key version. */
|
|
27
|
+
version?: string | undefined;
|
|
28
|
+
/** The tenant id where the KeyVault lives. */
|
|
29
|
+
tenantId?: string | undefined;
|
|
30
|
+
/**
|
|
31
|
+
* The Disk Encryption Set id that is used to represent the key info used for
|
|
32
|
+
* Managed Disk BYOK use case
|
|
33
|
+
*/
|
|
34
|
+
diskEncryptionSetId?: string | undefined;
|
|
35
|
+
/**
|
|
36
|
+
* The structure to store key access credential
|
|
37
|
+
* This is set if the Managed Identity is being used to access the Azure Key Vault key.
|
|
38
|
+
*/
|
|
39
|
+
keyAccessConfiguration?: KeyAccessConfiguration | undefined;
|
|
40
|
+
}
|
|
41
|
+
export interface CreateAwsKeyInfo {
|
|
42
|
+
/** The AWS KMS key's Amazon Resource Name (ARN). */
|
|
43
|
+
keyArn?: string | undefined;
|
|
44
|
+
/** The AWS KMS key alias. */
|
|
45
|
+
keyAlias?: string | undefined;
|
|
46
|
+
/** The AWS KMS key region. */
|
|
47
|
+
keyRegion?: string | undefined;
|
|
48
|
+
/**
|
|
49
|
+
* This field applies only if the `use_cases` property includes `STORAGE`. If this is set to true or omitted, the key is also used to encrypt
|
|
50
|
+
* cluster EBS volumes. If you do not want to use this key for encrypting EBS volumes, set to false.
|
|
51
|
+
*/
|
|
52
|
+
reuseKeyForClusterVolumes?: boolean | undefined;
|
|
53
|
+
}
|
|
54
|
+
export interface CreateAzureKeyInfo {
|
|
55
|
+
/** The base URI of the KeyVault. */
|
|
56
|
+
keyVaultUri?: string | undefined;
|
|
57
|
+
/** The name of the key in KeyVault. */
|
|
58
|
+
keyName?: string | undefined;
|
|
59
|
+
/** The current key version. */
|
|
60
|
+
version?: string | undefined;
|
|
61
|
+
/** The tenant id where the KeyVault lives. */
|
|
62
|
+
tenantId?: string | undefined;
|
|
63
|
+
/**
|
|
64
|
+
* The Disk Encryption Set id that is used to represent the key info used for
|
|
65
|
+
* Managed Disk BYOK use case
|
|
66
|
+
*/
|
|
67
|
+
diskEncryptionSetId?: string | undefined;
|
|
68
|
+
/**
|
|
69
|
+
* The structure to store key access credential
|
|
70
|
+
* This is set if the Managed Identity is being used to access the Azure Key Vault key.
|
|
71
|
+
*/
|
|
72
|
+
keyAccessConfiguration?: KeyAccessConfiguration | undefined;
|
|
73
|
+
}
|
|
74
|
+
export interface CreateCustomerManagedKeyRequest {
|
|
75
|
+
accountId?: string | undefined;
|
|
76
|
+
/**
|
|
77
|
+
* (-- The key information. Exactly one of aws_key_info, gcp_key_info, or
|
|
78
|
+
* azure_key_info must be set, matching the cloud of the account. --)
|
|
79
|
+
*/
|
|
80
|
+
keyInfo?: {
|
|
81
|
+
$case: 'awsKeyInfo';
|
|
82
|
+
awsKeyInfo: CreateAwsKeyInfo;
|
|
83
|
+
} | {
|
|
84
|
+
$case: 'gcpKeyInfo';
|
|
85
|
+
gcpKeyInfo: CreateGcpKeyInfo;
|
|
86
|
+
} | {
|
|
87
|
+
$case: 'azureKeyInfo';
|
|
88
|
+
azureKeyInfo: CreateAzureKeyInfo;
|
|
89
|
+
} | undefined;
|
|
90
|
+
/** The cases that the key can be used for. */
|
|
91
|
+
useCases?: CmkUseCase[] | undefined;
|
|
92
|
+
}
|
|
93
|
+
export interface CreateGcpKeyInfo {
|
|
94
|
+
/**
|
|
95
|
+
* Globally unique kms key resource id of the form
|
|
96
|
+
* projects/testProjectId/locations/us-east4/keyRings/gcpCmkKeyRing/cryptoKeys/cmk-eastus4
|
|
97
|
+
*/
|
|
98
|
+
kmsKeyId?: string | undefined;
|
|
99
|
+
/**
|
|
100
|
+
* Globally unique service account email that has access to the KMS key.
|
|
101
|
+
* The service account exists within the Databricks CP project.
|
|
102
|
+
*/
|
|
103
|
+
gcpServiceAccount?: GcpServiceAccount | undefined;
|
|
104
|
+
/**
|
|
105
|
+
* When true, <Databricks> will not use OAuth to grant the service account
|
|
106
|
+
* access to the KMS key. The customer is responsible for granting access
|
|
107
|
+
* manually.
|
|
108
|
+
*/
|
|
109
|
+
manual?: boolean | undefined;
|
|
110
|
+
}
|
|
111
|
+
export interface CustomerManagedKey {
|
|
112
|
+
/** ID of the encryption key configuration object. */
|
|
113
|
+
customerManagedKeyId?: string | undefined;
|
|
114
|
+
/** Time in epoch milliseconds when the customer key was created. */
|
|
115
|
+
creationTime?: bigint | undefined;
|
|
116
|
+
/** The <Databricks> account ID that holds the customer-managed key. */
|
|
117
|
+
accountId?: string | undefined;
|
|
118
|
+
/**
|
|
119
|
+
* (-- The key information, if aws_key_info is defined, it's a AWS Databricks object.
|
|
120
|
+
* If azure_key_info is defined, it's an Azure Databricks customer key object. --)
|
|
121
|
+
*/
|
|
122
|
+
keyInfo?: {
|
|
123
|
+
$case: 'awsKeyInfo';
|
|
124
|
+
awsKeyInfo: AwsKeyInfo;
|
|
125
|
+
} | {
|
|
126
|
+
$case: 'azureKeyInfo';
|
|
127
|
+
azureKeyInfo: AzureKeyInfo;
|
|
128
|
+
} | {
|
|
129
|
+
$case: 'gcpKeyInfo';
|
|
130
|
+
gcpKeyInfo: GcpKeyInfo;
|
|
131
|
+
} | undefined;
|
|
132
|
+
/** The cases that the key can be used for. */
|
|
133
|
+
useCases?: CmkUseCase[] | undefined;
|
|
134
|
+
}
|
|
135
|
+
export interface DeleteCustomerManagedKeyRequest {
|
|
136
|
+
/** <Databricks> encryption key configuration ID. */
|
|
137
|
+
customerManagedKeyId?: string | undefined;
|
|
138
|
+
accountId?: string | undefined;
|
|
139
|
+
}
|
|
140
|
+
export interface GcpKeyInfo {
|
|
141
|
+
/**
|
|
142
|
+
* Globally unique kms key resource id of the form
|
|
143
|
+
* projects/testProjectId/locations/us-east4/keyRings/gcpCmkKeyRing/cryptoKeys/cmk-eastus4
|
|
144
|
+
*/
|
|
145
|
+
kmsKeyId?: string | undefined;
|
|
146
|
+
/**
|
|
147
|
+
* Globally unique service account email that has access to the KMS key.
|
|
148
|
+
* The service account exists within the Databricks CP project.
|
|
149
|
+
*/
|
|
150
|
+
gcpServiceAccount?: GcpServiceAccount | undefined;
|
|
151
|
+
/**
|
|
152
|
+
* When true, <Databricks> will not use OAuth to grant the service account
|
|
153
|
+
* access to the KMS key. The customer is responsible for granting access
|
|
154
|
+
* manually.
|
|
155
|
+
*/
|
|
156
|
+
manual?: boolean | undefined;
|
|
157
|
+
}
|
|
158
|
+
export interface GcpServiceAccount {
|
|
159
|
+
serviceAccountEmail?: string | undefined;
|
|
160
|
+
}
|
|
161
|
+
export interface GetCustomerManagedKeyRequest {
|
|
162
|
+
/** <Databricks> encryption key configuration ID. */
|
|
163
|
+
customerManagedKeyId?: string | undefined;
|
|
164
|
+
accountId?: string | undefined;
|
|
165
|
+
}
|
|
166
|
+
/** The credential ID that is used to access the key vault. */
|
|
167
|
+
export interface KeyAccessConfiguration {
|
|
168
|
+
credentialId?: string | undefined;
|
|
169
|
+
}
|
|
170
|
+
export interface ListCustomerManagedKeyRequest {
|
|
171
|
+
accountId?: string | undefined;
|
|
172
|
+
}
|
|
173
|
+
export interface ListCustomerManagedKeyResponse {
|
|
174
|
+
customerManagedKeys?: CustomerManagedKey[] | undefined;
|
|
175
|
+
}
|
|
176
|
+
export declare const unmarshalAwsKeyInfoSchema: z.ZodType<AwsKeyInfo>;
|
|
177
|
+
export declare const unmarshalAzureKeyInfoSchema: z.ZodType<AzureKeyInfo>;
|
|
178
|
+
export declare const unmarshalCustomerManagedKeySchema: z.ZodType<CustomerManagedKey>;
|
|
179
|
+
export declare const unmarshalGcpKeyInfoSchema: z.ZodType<GcpKeyInfo>;
|
|
180
|
+
export declare const unmarshalGcpServiceAccountSchema: z.ZodType<GcpServiceAccount>;
|
|
181
|
+
export declare const unmarshalKeyAccessConfigurationSchema: z.ZodType<KeyAccessConfiguration>;
|
|
182
|
+
export declare const marshalCreateAwsKeyInfoSchema: z.ZodType;
|
|
183
|
+
export declare const marshalCreateAzureKeyInfoSchema: z.ZodType;
|
|
184
|
+
export declare const marshalCreateCustomerManagedKeyRequestSchema: z.ZodType;
|
|
185
|
+
export declare const marshalCreateGcpKeyInfoSchema: z.ZodType;
|
|
186
|
+
export declare const marshalGcpServiceAccountSchema: z.ZodType;
|
|
187
|
+
export declare const marshalKeyAccessConfigurationSchema: z.ZodType;
|
|
188
|
+
//# sourceMappingURL=model.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"model.d.ts","sourceRoot":"","sources":["../../src/v1/model.ts"],"names":[],"mappings":"AAEA,OAAO,EAAC,CAAC,EAAC,MAAM,KAAK,CAAC;AAEtB,oBAAY,UAAU;IACpB,kDAAkD;IAClD,gBAAgB,qBAAqB;IACrC,mDAAmD;IACnD,OAAO,YAAY;CACpB;AAED,MAAM,WAAW,UAAU;IACzB,oDAAoD;IACpD,MAAM,CAAC,EAAE,MAAM,GAAG,SAAS,CAAC;IAC5B,6BAA6B;IAC7B,QAAQ,CAAC,EAAE,MAAM,GAAG,SAAS,CAAC;IAC9B,8BAA8B;IAC9B,SAAS,CAAC,EAAE,MAAM,GAAG,SAAS,CAAC;IAC/B;;;OAGG;IACH,yBAAyB,CAAC,EAAE,OAAO,GAAG,SAAS,CAAC;CACjD;AAED,MAAM,WAAW,YAAY;IAC3B,oCAAoC;IACpC,WAAW,CAAC,EAAE,MAAM,GAAG,SAAS,CAAC;IACjC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