@databricks/sdk-accessmanagement 0.1.0-dev.1 → 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/dist/v1/client.d.ts +14 -14
- package/dist/v1/client.d.ts.map +1 -1
- package/dist/v1/client.js +55 -55
- package/dist/v1/client.js.map +1 -1
- package/dist/v1/index.d.ts +2 -2
- package/dist/v1/index.d.ts.map +1 -1
- package/dist/v1/index.js +1 -1
- package/dist/v1/model.d.ts +41 -41
- package/dist/v1/model.d.ts.map +1 -1
- package/dist/v1/model.js +12 -12
- package/dist/v1/model.js.map +1 -1
- package/dist/v1/utils.d.ts +1 -2
- package/dist/v1/utils.d.ts.map +1 -1
- package/dist/v1/utils.js +1 -1
- package/dist/v1/utils.js.map +1 -1
- package/package.json +4 -4
- package/src/v1/client.ts +102 -103
- package/src/v1/index.ts +7 -7
- package/src/v1/model.ts +59 -59
- package/src/v1/utils.ts +3 -3
package/src/v1/model.ts
CHANGED
|
@@ -131,26 +131,6 @@ export interface DeleteWorkspacePermissionAssignmentRequest {
|
|
|
131
131
|
// eslint-disable-next-line @typescript-eslint/naming-convention, @typescript-eslint/no-empty-object-type -- Proto-style nested message name.
|
|
132
132
|
export interface DeleteWorkspacePermissionAssignmentRequest_Response {}
|
|
133
133
|
|
|
134
|
-
export interface GetAssignableRolesForResourceRequest {
|
|
135
|
-
/** <Databricks> account ID. */
|
|
136
|
-
accountId?: string | undefined;
|
|
137
|
-
/**
|
|
138
|
-
* The resource name for which assignable roles will be listed.
|
|
139
|
-
*
|
|
140
|
-
* Examples | Summary
|
|
141
|
-
* :--- | :---
|
|
142
|
-
* `resource=accounts/<ACCOUNT_ID>` | A resource name for the account.
|
|
143
|
-
* `resource=accounts/<ACCOUNT_ID>/groups/<GROUP_ID>` | A resource name for the group.
|
|
144
|
-
* `resource=accounts/<ACCOUNT_ID>/servicePrincipals/<SP_ID>` | A resource name for the service principal.
|
|
145
|
-
* `resource=accounts/<ACCOUNT_ID>/tagPolicies/<TAG_POLICY_ID>` | A resource name for the tag policy.
|
|
146
|
-
*/
|
|
147
|
-
resource?: string | undefined;
|
|
148
|
-
}
|
|
149
|
-
|
|
150
|
-
export interface GetAssignableRolesForResourceResponse {
|
|
151
|
-
roles?: Role[] | undefined;
|
|
152
|
-
}
|
|
153
|
-
|
|
154
134
|
export interface GetObjectPermissionsRequest {
|
|
155
135
|
/** The type of the request object. Can be one of the following: alerts, alertsv2, authorization, clusters, cluster-policies, dashboards, database-projects, dbsql-dashboards, directories, experiments, files, genie, instance-pools, jobs, knowledge-assistants, notebooks, pipelines, queries, registered-models, repos, serving-endpoints, supervisor-agents, vector-search-endpoints, or warehouses. */
|
|
156
136
|
requestObjectType?: string | undefined;
|
|
@@ -158,18 +138,6 @@ export interface GetObjectPermissionsRequest {
|
|
|
158
138
|
requestObjectId?: string | undefined;
|
|
159
139
|
}
|
|
160
140
|
|
|
161
|
-
export interface GetPermissionLevelsRequest {
|
|
162
|
-
/** The type of the request object. Can be one of the following: alerts, alertsv2, authorization, clusters, cluster-policies, dashboards, database-projects, dbsql-dashboards, directories, experiments, files, genie, instance-pools, jobs, knowledge-assistants, notebooks, pipelines, queries, registered-models, repos, serving-endpoints, supervisor-agents, vector-search-endpoints, or warehouses. */
|
|
163
|
-
requestObjectType?: string | undefined;
|
|
164
|
-
requestObjectId?: string | undefined;
|
|
165
|
-
}
|
|
166
|
-
|
|
167
|
-
// eslint-disable-next-line @typescript-eslint/naming-convention -- Proto-style nested message name.
|
|
168
|
-
export interface GetPermissionLevelsRequest_Response {
|
|
169
|
-
/** Specific permission levels */
|
|
170
|
-
permissionLevels?: PermissionsDescription[] | undefined;
|
|
171
|
-
}
|
|
172
|
-
|
|
173
141
|
export interface GetRuleSetRequest {
|
|
174
142
|
/** <Databricks> account ID. */
|
|
175
143
|
accountId?: string | undefined;
|
|
@@ -199,20 +167,6 @@ export interface GetRuleSetRequest {
|
|
|
199
167
|
etag?: string | undefined;
|
|
200
168
|
}
|
|
201
169
|
|
|
202
|
-
/** Gets all the permission assignments for a workspace, given an account and a workspace. */
|
|
203
|
-
export interface GetWorkspacePermissionAssignmentsRequest {
|
|
204
|
-
/** The account ID. */
|
|
205
|
-
accountId?: string | undefined;
|
|
206
|
-
/** The workspace ID for the account. */
|
|
207
|
-
workspaceId?: bigint | undefined;
|
|
208
|
-
}
|
|
209
|
-
|
|
210
|
-
// eslint-disable-next-line @typescript-eslint/naming-convention -- Proto-style nested message name.
|
|
211
|
-
export interface GetWorkspacePermissionAssignmentsRequest_Response {
|
|
212
|
-
/** Array of permissions assignments defined for a workspace. */
|
|
213
|
-
permissionAssignments?: WorkspacePermissionAssignmentOutput[] | undefined;
|
|
214
|
-
}
|
|
215
|
-
|
|
216
170
|
export interface GrantRule {
|
|
217
171
|
/**
|
|
218
172
|
* Principals this grant rule applies to.
|
|
@@ -227,6 +181,52 @@ export interface GrantRule {
|
|
|
227
181
|
role?: string | undefined;
|
|
228
182
|
}
|
|
229
183
|
|
|
184
|
+
export interface ListAssignableRolesForResourceRequest {
|
|
185
|
+
/** <Databricks> account ID. */
|
|
186
|
+
accountId?: string | undefined;
|
|
187
|
+
/**
|
|
188
|
+
* The resource name for which assignable roles will be listed.
|
|
189
|
+
*
|
|
190
|
+
* Examples | Summary
|
|
191
|
+
* :--- | :---
|
|
192
|
+
* `resource=accounts/<ACCOUNT_ID>` | A resource name for the account.
|
|
193
|
+
* `resource=accounts/<ACCOUNT_ID>/groups/<GROUP_ID>` | A resource name for the group.
|
|
194
|
+
* `resource=accounts/<ACCOUNT_ID>/servicePrincipals/<SP_ID>` | A resource name for the service principal.
|
|
195
|
+
* `resource=accounts/<ACCOUNT_ID>/tagPolicies/<TAG_POLICY_ID>` | A resource name for the tag policy.
|
|
196
|
+
*/
|
|
197
|
+
resource?: string | undefined;
|
|
198
|
+
}
|
|
199
|
+
|
|
200
|
+
export interface ListAssignableRolesForResourceResponse {
|
|
201
|
+
roles?: Role[] | undefined;
|
|
202
|
+
}
|
|
203
|
+
|
|
204
|
+
export interface ListPermissionLevelsRequest {
|
|
205
|
+
/** The type of the request object. Can be one of the following: alerts, alertsv2, authorization, clusters, cluster-policies, dashboards, database-projects, dbsql-dashboards, directories, experiments, files, genie, instance-pools, jobs, knowledge-assistants, notebooks, pipelines, queries, registered-models, repos, serving-endpoints, supervisor-agents, vector-search-endpoints, or warehouses. */
|
|
206
|
+
requestObjectType?: string | undefined;
|
|
207
|
+
requestObjectId?: string | undefined;
|
|
208
|
+
}
|
|
209
|
+
|
|
210
|
+
// eslint-disable-next-line @typescript-eslint/naming-convention -- Proto-style nested message name.
|
|
211
|
+
export interface ListPermissionLevelsRequest_Response {
|
|
212
|
+
/** Specific permission levels */
|
|
213
|
+
permissionLevels?: PermissionsDescription[] | undefined;
|
|
214
|
+
}
|
|
215
|
+
|
|
216
|
+
/** Gets all the permission assignments for a workspace, given an account and a workspace. */
|
|
217
|
+
export interface ListWorkspacePermissionAssignmentsRequest {
|
|
218
|
+
/** The account ID. */
|
|
219
|
+
accountId?: string | undefined;
|
|
220
|
+
/** The workspace ID for the account. */
|
|
221
|
+
workspaceId?: bigint | undefined;
|
|
222
|
+
}
|
|
223
|
+
|
|
224
|
+
// eslint-disable-next-line @typescript-eslint/naming-convention -- Proto-style nested message name.
|
|
225
|
+
export interface ListWorkspacePermissionAssignmentsRequest_Response {
|
|
226
|
+
/** Array of permissions assignments defined for a workspace. */
|
|
227
|
+
permissionAssignments?: WorkspacePermissionAssignmentOutput[] | undefined;
|
|
228
|
+
}
|
|
229
|
+
|
|
230
230
|
/** List permissions for a workspace, given an account and a workspace. */
|
|
231
231
|
export interface ListWorkspacePermissionsRequest {
|
|
232
232
|
/** The account ID. */
|
|
@@ -441,7 +441,17 @@ export const unmarshalConsistencyTokenSchema: z.ZodType<ConsistencyToken> = z
|
|
|
441
441
|
export const unmarshalDeleteWorkspacePermissionAssignmentRequest_ResponseSchema: z.ZodType<DeleteWorkspacePermissionAssignmentRequest_Response> =
|
|
442
442
|
z.object({});
|
|
443
443
|
|
|
444
|
-
export const
|
|
444
|
+
export const unmarshalGrantRuleSchema: z.ZodType<GrantRule> = z
|
|
445
|
+
.object({
|
|
446
|
+
principals: z.array(z.string()).optional(),
|
|
447
|
+
role: z.string().optional(),
|
|
448
|
+
})
|
|
449
|
+
.transform(d => ({
|
|
450
|
+
principals: d.principals,
|
|
451
|
+
role: d.role,
|
|
452
|
+
}));
|
|
453
|
+
|
|
454
|
+
export const unmarshalListAssignableRolesForResourceResponseSchema: z.ZodType<ListAssignableRolesForResourceResponse> =
|
|
445
455
|
z
|
|
446
456
|
.object({
|
|
447
457
|
roles: z.array(z.lazy(() => unmarshalRoleSchema)).optional(),
|
|
@@ -451,7 +461,7 @@ export const unmarshalGetAssignableRolesForResourceResponseSchema: z.ZodType<Get
|
|
|
451
461
|
}));
|
|
452
462
|
|
|
453
463
|
// eslint-disable-next-line @typescript-eslint/naming-convention -- Proto-style nested message name.
|
|
454
|
-
export const
|
|
464
|
+
export const unmarshalListPermissionLevelsRequest_ResponseSchema: z.ZodType<ListPermissionLevelsRequest_Response> =
|
|
455
465
|
z
|
|
456
466
|
.object({
|
|
457
467
|
permission_levels: z
|
|
@@ -463,7 +473,7 @@ export const unmarshalGetPermissionLevelsRequest_ResponseSchema: z.ZodType<GetPe
|
|
|
463
473
|
}));
|
|
464
474
|
|
|
465
475
|
// eslint-disable-next-line @typescript-eslint/naming-convention -- Proto-style nested message name.
|
|
466
|
-
export const
|
|
476
|
+
export const unmarshalListWorkspacePermissionAssignmentsRequest_ResponseSchema: z.ZodType<ListWorkspacePermissionAssignmentsRequest_Response> =
|
|
467
477
|
z
|
|
468
478
|
.object({
|
|
469
479
|
permission_assignments: z
|
|
@@ -474,16 +484,6 @@ export const unmarshalGetWorkspacePermissionAssignmentsRequest_ResponseSchema: z
|
|
|
474
484
|
permissionAssignments: d.permission_assignments,
|
|
475
485
|
}));
|
|
476
486
|
|
|
477
|
-
export const unmarshalGrantRuleSchema: z.ZodType<GrantRule> = z
|
|
478
|
-
.object({
|
|
479
|
-
principals: z.array(z.string()).optional(),
|
|
480
|
-
role: z.string().optional(),
|
|
481
|
-
})
|
|
482
|
-
.transform(d => ({
|
|
483
|
-
principals: d.principals,
|
|
484
|
-
role: d.role,
|
|
485
|
-
}));
|
|
486
|
-
|
|
487
487
|
// eslint-disable-next-line @typescript-eslint/naming-convention -- Proto-style nested message name.
|
|
488
488
|
export const unmarshalListWorkspacePermissionsRequest_ResponseSchema: z.ZodType<ListWorkspacePermissionsRequest_Response> =
|
|
489
489
|
z
|
package/src/v1/utils.ts
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
// Code generated from API definition by Databricks SDK Generator. DO NOT EDIT.
|
|
2
2
|
|
|
3
|
-
import type {
|
|
4
|
-
import {execute} from '@databricks/sdk-core/
|
|
3
|
+
import type {Options} from '@databricks/sdk-core/ops';
|
|
4
|
+
import {execute} from '@databricks/sdk-core/ops';
|
|
5
5
|
import {ApiError} from '@databricks/sdk-core/apierror';
|
|
6
6
|
import type {
|
|
7
7
|
HttpClient,
|
|
@@ -30,7 +30,7 @@ export interface HttpCallOptions {
|
|
|
30
30
|
* API from the executor's internal type so they can diverge.
|
|
31
31
|
*/
|
|
32
32
|
export async function executeCall(
|
|
33
|
-
call:
|
|
33
|
+
call: (signal?: AbortSignal) => Promise<void>,
|
|
34
34
|
options?: CallOptions
|
|
35
35
|
): Promise<void> {
|
|
36
36
|
const opts: Options = {
|