databricks-sdk 0.56.0__py3-none-any.whl → 0.58.0__py3-none-any.whl
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.
Potentially problematic release.
This version of databricks-sdk might be problematic. Click here for more details.
- databricks/sdk/__init__.py +38 -11
- databricks/sdk/service/aibuilder.py +122 -17
- databricks/sdk/service/apps.py +15 -45
- databricks/sdk/service/billing.py +70 -74
- databricks/sdk/service/catalog.py +1898 -557
- databricks/sdk/service/cleanrooms.py +14 -55
- databricks/sdk/service/compute.py +305 -508
- databricks/sdk/service/dashboards.py +148 -223
- databricks/sdk/service/database.py +657 -127
- databricks/sdk/service/files.py +18 -54
- databricks/sdk/service/iam.py +55 -165
- databricks/sdk/service/jobs.py +238 -214
- databricks/sdk/service/marketplace.py +47 -146
- databricks/sdk/service/ml.py +1137 -447
- databricks/sdk/service/oauth2.py +17 -46
- databricks/sdk/service/pipelines.py +93 -69
- databricks/sdk/service/provisioning.py +34 -212
- databricks/sdk/service/qualitymonitorv2.py +5 -33
- databricks/sdk/service/serving.py +69 -55
- databricks/sdk/service/settings.py +106 -434
- databricks/sdk/service/sharing.py +33 -95
- databricks/sdk/service/sql.py +164 -254
- databricks/sdk/service/vectorsearch.py +13 -62
- databricks/sdk/service/workspace.py +36 -110
- databricks/sdk/version.py +1 -1
- {databricks_sdk-0.56.0.dist-info → databricks_sdk-0.58.0.dist-info}/METADATA +1 -1
- {databricks_sdk-0.56.0.dist-info → databricks_sdk-0.58.0.dist-info}/RECORD +31 -31
- {databricks_sdk-0.56.0.dist-info → databricks_sdk-0.58.0.dist-info}/WHEEL +0 -0
- {databricks_sdk-0.56.0.dist-info → databricks_sdk-0.58.0.dist-info}/licenses/LICENSE +0 -0
- {databricks_sdk-0.56.0.dist-info → databricks_sdk-0.58.0.dist-info}/licenses/NOTICE +0 -0
- {databricks_sdk-0.56.0.dist-info → databricks_sdk-0.58.0.dist-info}/top_level.txt +0 -0
databricks/sdk/service/iam.py
CHANGED
|
@@ -21,7 +21,6 @@ class AccessControlRequest:
|
|
|
21
21
|
"""name of the group"""
|
|
22
22
|
|
|
23
23
|
permission_level: Optional[PermissionLevel] = None
|
|
24
|
-
"""Permission level"""
|
|
25
24
|
|
|
26
25
|
service_principal_name: Optional[str] = None
|
|
27
26
|
"""application ID of a service principal"""
|
|
@@ -1220,7 +1219,6 @@ class Permission:
|
|
|
1220
1219
|
inherited_from_object: Optional[List[str]] = None
|
|
1221
1220
|
|
|
1222
1221
|
permission_level: Optional[PermissionLevel] = None
|
|
1223
|
-
"""Permission level"""
|
|
1224
1222
|
|
|
1225
1223
|
def as_dict(self) -> dict:
|
|
1226
1224
|
"""Serializes the Permission into a dictionary suitable for use as a JSON request body."""
|
|
@@ -1387,7 +1385,6 @@ class PermissionsDescription:
|
|
|
1387
1385
|
description: Optional[str] = None
|
|
1388
1386
|
|
|
1389
1387
|
permission_level: Optional[PermissionLevel] = None
|
|
1390
|
-
"""Permission level"""
|
|
1391
1388
|
|
|
1392
1389
|
def as_dict(self) -> dict:
|
|
1393
1390
|
"""Serializes the PermissionsDescription into a dictionary suitable for use as a JSON request body."""
|
|
@@ -2163,9 +2160,7 @@ class AccountAccessControlAPI:
|
|
|
2163
2160
|
self._api = api_client
|
|
2164
2161
|
|
|
2165
2162
|
def get_assignable_roles_for_resource(self, resource: str) -> GetAssignableRolesForResourceResponse:
|
|
2166
|
-
"""
|
|
2167
|
-
|
|
2168
|
-
Gets all the roles that can be granted on an account level resource. A role is grantable if the rule
|
|
2163
|
+
"""Gets all the roles that can be granted on an account level resource. A role is grantable if the rule
|
|
2169
2164
|
set on the resource can contain an access rule of the role.
|
|
2170
2165
|
|
|
2171
2166
|
:param resource: str
|
|
@@ -2195,9 +2190,7 @@ class AccountAccessControlAPI:
|
|
|
2195
2190
|
return GetAssignableRolesForResourceResponse.from_dict(res)
|
|
2196
2191
|
|
|
2197
2192
|
def get_rule_set(self, name: str, etag: str) -> RuleSetResponse:
|
|
2198
|
-
"""Get a rule set.
|
|
2199
|
-
|
|
2200
|
-
Get a rule set by its name. A rule set is always attached to a resource and contains a list of access
|
|
2193
|
+
"""Get a rule set by its name. A rule set is always attached to a resource and contains a list of access
|
|
2201
2194
|
rules on the said resource. Currently only a default rule set for each resource is supported.
|
|
2202
2195
|
|
|
2203
2196
|
:param name: str
|
|
@@ -2241,9 +2234,7 @@ class AccountAccessControlAPI:
|
|
|
2241
2234
|
return RuleSetResponse.from_dict(res)
|
|
2242
2235
|
|
|
2243
2236
|
def update_rule_set(self, name: str, rule_set: RuleSetUpdateRequest) -> RuleSetResponse:
|
|
2244
|
-
"""
|
|
2245
|
-
|
|
2246
|
-
Replace the rules of a rule set. First, use get to read the current version of the rule set before
|
|
2237
|
+
"""Replace the rules of a rule set. First, use get to read the current version of the rule set before
|
|
2247
2238
|
modifying it. This pattern helps prevent conflicts between concurrent updates.
|
|
2248
2239
|
|
|
2249
2240
|
:param name: str
|
|
@@ -2280,9 +2271,7 @@ class AccountAccessControlProxyAPI:
|
|
|
2280
2271
|
self._api = api_client
|
|
2281
2272
|
|
|
2282
2273
|
def get_assignable_roles_for_resource(self, resource: str) -> GetAssignableRolesForResourceResponse:
|
|
2283
|
-
"""
|
|
2284
|
-
|
|
2285
|
-
Gets all the roles that can be granted on an account level resource. A role is grantable if the rule
|
|
2274
|
+
"""Gets all the roles that can be granted on an account level resource. A role is grantable if the rule
|
|
2286
2275
|
set on the resource can contain an access rule of the role.
|
|
2287
2276
|
|
|
2288
2277
|
:param resource: str
|
|
@@ -2309,9 +2298,7 @@ class AccountAccessControlProxyAPI:
|
|
|
2309
2298
|
return GetAssignableRolesForResourceResponse.from_dict(res)
|
|
2310
2299
|
|
|
2311
2300
|
def get_rule_set(self, name: str, etag: str) -> RuleSetResponse:
|
|
2312
|
-
"""Get a rule set.
|
|
2313
|
-
|
|
2314
|
-
Get a rule set by its name. A rule set is always attached to a resource and contains a list of access
|
|
2301
|
+
"""Get a rule set by its name. A rule set is always attached to a resource and contains a list of access
|
|
2315
2302
|
rules on the said resource. Currently only a default rule set for each resource is supported.
|
|
2316
2303
|
|
|
2317
2304
|
:param name: str
|
|
@@ -2350,9 +2337,7 @@ class AccountAccessControlProxyAPI:
|
|
|
2350
2337
|
return RuleSetResponse.from_dict(res)
|
|
2351
2338
|
|
|
2352
2339
|
def update_rule_set(self, name: str, rule_set: RuleSetUpdateRequest) -> RuleSetResponse:
|
|
2353
|
-
"""
|
|
2354
|
-
|
|
2355
|
-
Replace the rules of a rule set. First, use get to read the current version of the rule set before
|
|
2340
|
+
"""Replace the rules of a rule set. First, use get to read the current version of the rule set before
|
|
2356
2341
|
modifying it. This pattern helps prevent conflicts between concurrent updates.
|
|
2357
2342
|
|
|
2358
2343
|
:param name: str
|
|
@@ -2399,9 +2384,7 @@ class AccountGroupsAPI:
|
|
|
2399
2384
|
roles: Optional[List[ComplexValue]] = None,
|
|
2400
2385
|
schemas: Optional[List[GroupSchema]] = None,
|
|
2401
2386
|
) -> Group:
|
|
2402
|
-
"""
|
|
2403
|
-
|
|
2404
|
-
Creates a group in the Databricks account with a unique name, using the supplied group details.
|
|
2387
|
+
"""Creates a group in the Databricks account with a unique name, using the supplied group details.
|
|
2405
2388
|
|
|
2406
2389
|
:param display_name: str (optional)
|
|
2407
2390
|
String that represents a human-readable group name
|
|
@@ -2454,9 +2437,7 @@ class AccountGroupsAPI:
|
|
|
2454
2437
|
return Group.from_dict(res)
|
|
2455
2438
|
|
|
2456
2439
|
def delete(self, id: str):
|
|
2457
|
-
"""
|
|
2458
|
-
|
|
2459
|
-
Deletes a group from the Databricks account.
|
|
2440
|
+
"""Deletes a group from the Databricks account.
|
|
2460
2441
|
|
|
2461
2442
|
:param id: str
|
|
2462
2443
|
Unique ID for a group in the Databricks account.
|
|
@@ -2469,9 +2450,7 @@ class AccountGroupsAPI:
|
|
|
2469
2450
|
self._api.do("DELETE", f"/api/2.0/accounts/{self._api.account_id}/scim/v2/Groups/{id}", headers=headers)
|
|
2470
2451
|
|
|
2471
2452
|
def get(self, id: str) -> Group:
|
|
2472
|
-
"""
|
|
2473
|
-
|
|
2474
|
-
Gets the information for a specific group in the Databricks account.
|
|
2453
|
+
"""Gets the information for a specific group in the Databricks account.
|
|
2475
2454
|
|
|
2476
2455
|
:param id: str
|
|
2477
2456
|
Unique ID for a group in the Databricks account.
|
|
@@ -2497,9 +2476,7 @@ class AccountGroupsAPI:
|
|
|
2497
2476
|
sort_order: Optional[ListSortOrder] = None,
|
|
2498
2477
|
start_index: Optional[int] = None,
|
|
2499
2478
|
) -> Iterator[Group]:
|
|
2500
|
-
"""
|
|
2501
|
-
|
|
2502
|
-
Gets all details of the groups associated with the Databricks account.
|
|
2479
|
+
"""Gets all details of the groups associated with the Databricks account.
|
|
2503
2480
|
|
|
2504
2481
|
:param attributes: str (optional)
|
|
2505
2482
|
Comma-separated list of attributes to return in response.
|
|
@@ -2564,9 +2541,7 @@ class AccountGroupsAPI:
|
|
|
2564
2541
|
query["startIndex"] += len(json["Resources"])
|
|
2565
2542
|
|
|
2566
2543
|
def patch(self, id: str, *, operations: Optional[List[Patch]] = None, schemas: Optional[List[PatchSchema]] = None):
|
|
2567
|
-
"""
|
|
2568
|
-
|
|
2569
|
-
Partially updates the details of a group.
|
|
2544
|
+
"""Partially updates the details of a group.
|
|
2570
2545
|
|
|
2571
2546
|
:param id: str
|
|
2572
2547
|
Unique ID in the Databricks workspace.
|
|
@@ -2602,9 +2577,7 @@ class AccountGroupsAPI:
|
|
|
2602
2577
|
roles: Optional[List[ComplexValue]] = None,
|
|
2603
2578
|
schemas: Optional[List[GroupSchema]] = None,
|
|
2604
2579
|
):
|
|
2605
|
-
"""
|
|
2606
|
-
|
|
2607
|
-
Updates the details of a group by replacing the entire group entity.
|
|
2580
|
+
"""Updates the details of a group by replacing the entire group entity.
|
|
2608
2581
|
|
|
2609
2582
|
:param id: str
|
|
2610
2583
|
Databricks group ID
|
|
@@ -2674,9 +2647,7 @@ class AccountServicePrincipalsAPI:
|
|
|
2674
2647
|
roles: Optional[List[ComplexValue]] = None,
|
|
2675
2648
|
schemas: Optional[List[ServicePrincipalSchema]] = None,
|
|
2676
2649
|
) -> ServicePrincipal:
|
|
2677
|
-
"""
|
|
2678
|
-
|
|
2679
|
-
Creates a new service principal in the Databricks account.
|
|
2650
|
+
"""Creates a new service principal in the Databricks account.
|
|
2680
2651
|
|
|
2681
2652
|
:param active: bool (optional)
|
|
2682
2653
|
If this user is active
|
|
@@ -2730,9 +2701,7 @@ class AccountServicePrincipalsAPI:
|
|
|
2730
2701
|
return ServicePrincipal.from_dict(res)
|
|
2731
2702
|
|
|
2732
2703
|
def delete(self, id: str):
|
|
2733
|
-
"""Delete a service principal.
|
|
2734
|
-
|
|
2735
|
-
Delete a single service principal in the Databricks account.
|
|
2704
|
+
"""Delete a single service principal in the Databricks account.
|
|
2736
2705
|
|
|
2737
2706
|
:param id: str
|
|
2738
2707
|
Unique ID for a service principal in the Databricks account.
|
|
@@ -2747,9 +2716,7 @@ class AccountServicePrincipalsAPI:
|
|
|
2747
2716
|
)
|
|
2748
2717
|
|
|
2749
2718
|
def get(self, id: str) -> ServicePrincipal:
|
|
2750
|
-
"""
|
|
2751
|
-
|
|
2752
|
-
Gets the details for a single service principal define in the Databricks account.
|
|
2719
|
+
"""Gets the details for a single service principal define in the Databricks account.
|
|
2753
2720
|
|
|
2754
2721
|
:param id: str
|
|
2755
2722
|
Unique ID for a service principal in the Databricks account.
|
|
@@ -2777,9 +2744,7 @@ class AccountServicePrincipalsAPI:
|
|
|
2777
2744
|
sort_order: Optional[ListSortOrder] = None,
|
|
2778
2745
|
start_index: Optional[int] = None,
|
|
2779
2746
|
) -> Iterator[ServicePrincipal]:
|
|
2780
|
-
"""
|
|
2781
|
-
|
|
2782
|
-
Gets the set of service principals associated with a Databricks account.
|
|
2747
|
+
"""Gets the set of service principals associated with a Databricks account.
|
|
2783
2748
|
|
|
2784
2749
|
:param attributes: str (optional)
|
|
2785
2750
|
Comma-separated list of attributes to return in response.
|
|
@@ -2847,9 +2812,7 @@ class AccountServicePrincipalsAPI:
|
|
|
2847
2812
|
query["startIndex"] += len(json["Resources"])
|
|
2848
2813
|
|
|
2849
2814
|
def patch(self, id: str, *, operations: Optional[List[Patch]] = None, schemas: Optional[List[PatchSchema]] = None):
|
|
2850
|
-
"""
|
|
2851
|
-
|
|
2852
|
-
Partially updates the details of a single service principal in the Databricks account.
|
|
2815
|
+
"""Partially updates the details of a single service principal in the Databricks account.
|
|
2853
2816
|
|
|
2854
2817
|
:param id: str
|
|
2855
2818
|
Unique ID in the Databricks workspace.
|
|
@@ -2888,9 +2851,7 @@ class AccountServicePrincipalsAPI:
|
|
|
2888
2851
|
roles: Optional[List[ComplexValue]] = None,
|
|
2889
2852
|
schemas: Optional[List[ServicePrincipalSchema]] = None,
|
|
2890
2853
|
):
|
|
2891
|
-
"""
|
|
2892
|
-
|
|
2893
|
-
Updates the details of a single service principal.
|
|
2854
|
+
"""Updates the details of a single service principal.
|
|
2894
2855
|
|
|
2895
2856
|
This action replaces the existing service principal with the same name.
|
|
2896
2857
|
|
|
@@ -2974,9 +2935,7 @@ class AccountUsersAPI:
|
|
|
2974
2935
|
schemas: Optional[List[UserSchema]] = None,
|
|
2975
2936
|
user_name: Optional[str] = None,
|
|
2976
2937
|
) -> User:
|
|
2977
|
-
"""
|
|
2978
|
-
|
|
2979
|
-
Creates a new user in the Databricks account. This new user will also be added to the Databricks
|
|
2938
|
+
"""Creates a new user in the Databricks account. This new user will also be added to the Databricks
|
|
2980
2939
|
account.
|
|
2981
2940
|
|
|
2982
2941
|
:param active: bool (optional)
|
|
@@ -3042,9 +3001,7 @@ class AccountUsersAPI:
|
|
|
3042
3001
|
return User.from_dict(res)
|
|
3043
3002
|
|
|
3044
3003
|
def delete(self, id: str):
|
|
3045
|
-
"""
|
|
3046
|
-
|
|
3047
|
-
Deletes a user. Deleting a user from a Databricks account also removes objects associated with the
|
|
3004
|
+
"""Deletes a user. Deleting a user from a Databricks account also removes objects associated with the
|
|
3048
3005
|
user.
|
|
3049
3006
|
|
|
3050
3007
|
:param id: str
|
|
@@ -3069,9 +3026,7 @@ class AccountUsersAPI:
|
|
|
3069
3026
|
sort_order: Optional[GetSortOrder] = None,
|
|
3070
3027
|
start_index: Optional[int] = None,
|
|
3071
3028
|
) -> User:
|
|
3072
|
-
"""
|
|
3073
|
-
|
|
3074
|
-
Gets information for a specific user in Databricks account.
|
|
3029
|
+
"""Gets information for a specific user in Databricks account.
|
|
3075
3030
|
|
|
3076
3031
|
:param id: str
|
|
3077
3032
|
Unique ID for a user in the Databricks account.
|
|
@@ -3134,9 +3089,7 @@ class AccountUsersAPI:
|
|
|
3134
3089
|
sort_order: Optional[ListSortOrder] = None,
|
|
3135
3090
|
start_index: Optional[int] = None,
|
|
3136
3091
|
) -> Iterator[User]:
|
|
3137
|
-
"""
|
|
3138
|
-
|
|
3139
|
-
Gets details for all the users associated with a Databricks account.
|
|
3092
|
+
"""Gets details for all the users associated with a Databricks account.
|
|
3140
3093
|
|
|
3141
3094
|
:param attributes: str (optional)
|
|
3142
3095
|
Comma-separated list of attributes to return in response.
|
|
@@ -3202,9 +3155,7 @@ class AccountUsersAPI:
|
|
|
3202
3155
|
query["startIndex"] += len(json["Resources"])
|
|
3203
3156
|
|
|
3204
3157
|
def patch(self, id: str, *, operations: Optional[List[Patch]] = None, schemas: Optional[List[PatchSchema]] = None):
|
|
3205
|
-
"""
|
|
3206
|
-
|
|
3207
|
-
Partially updates a user resource by applying the supplied operations on specific user attributes.
|
|
3158
|
+
"""Partially updates a user resource by applying the supplied operations on specific user attributes.
|
|
3208
3159
|
|
|
3209
3160
|
:param id: str
|
|
3210
3161
|
Unique ID in the Databricks workspace.
|
|
@@ -3242,9 +3193,7 @@ class AccountUsersAPI:
|
|
|
3242
3193
|
schemas: Optional[List[UserSchema]] = None,
|
|
3243
3194
|
user_name: Optional[str] = None,
|
|
3244
3195
|
):
|
|
3245
|
-
"""
|
|
3246
|
-
|
|
3247
|
-
Replaces a user's information with the data supplied in request.
|
|
3196
|
+
"""Replaces a user's information with the data supplied in request.
|
|
3248
3197
|
|
|
3249
3198
|
:param id: str
|
|
3250
3199
|
Databricks user ID.
|
|
@@ -3310,9 +3259,8 @@ class CurrentUserAPI:
|
|
|
3310
3259
|
self._api = api_client
|
|
3311
3260
|
|
|
3312
3261
|
def me(self) -> User:
|
|
3313
|
-
"""Get current
|
|
3262
|
+
"""Get details about the current method caller's identity.
|
|
3314
3263
|
|
|
3315
|
-
Get details about the current method caller's identity.
|
|
3316
3264
|
|
|
3317
3265
|
:returns: :class:`User`
|
|
3318
3266
|
"""
|
|
@@ -3349,9 +3297,7 @@ class GroupsAPI:
|
|
|
3349
3297
|
roles: Optional[List[ComplexValue]] = None,
|
|
3350
3298
|
schemas: Optional[List[GroupSchema]] = None,
|
|
3351
3299
|
) -> Group:
|
|
3352
|
-
"""
|
|
3353
|
-
|
|
3354
|
-
Creates a group in the Databricks workspace with a unique name, using the supplied group details.
|
|
3300
|
+
"""Creates a group in the Databricks workspace with a unique name, using the supplied group details.
|
|
3355
3301
|
|
|
3356
3302
|
:param display_name: str (optional)
|
|
3357
3303
|
String that represents a human-readable group name
|
|
@@ -3402,9 +3348,7 @@ class GroupsAPI:
|
|
|
3402
3348
|
return Group.from_dict(res)
|
|
3403
3349
|
|
|
3404
3350
|
def delete(self, id: str):
|
|
3405
|
-
"""
|
|
3406
|
-
|
|
3407
|
-
Deletes a group from the Databricks workspace.
|
|
3351
|
+
"""Deletes a group from the Databricks workspace.
|
|
3408
3352
|
|
|
3409
3353
|
:param id: str
|
|
3410
3354
|
Unique ID for a group in the Databricks workspace.
|
|
@@ -3417,9 +3361,7 @@ class GroupsAPI:
|
|
|
3417
3361
|
self._api.do("DELETE", f"/api/2.0/preview/scim/v2/Groups/{id}", headers=headers)
|
|
3418
3362
|
|
|
3419
3363
|
def get(self, id: str) -> Group:
|
|
3420
|
-
"""
|
|
3421
|
-
|
|
3422
|
-
Gets the information for a specific group in the Databricks workspace.
|
|
3364
|
+
"""Gets the information for a specific group in the Databricks workspace.
|
|
3423
3365
|
|
|
3424
3366
|
:param id: str
|
|
3425
3367
|
Unique ID for a group in the Databricks workspace.
|
|
@@ -3445,9 +3387,7 @@ class GroupsAPI:
|
|
|
3445
3387
|
sort_order: Optional[ListSortOrder] = None,
|
|
3446
3388
|
start_index: Optional[int] = None,
|
|
3447
3389
|
) -> Iterator[Group]:
|
|
3448
|
-
"""
|
|
3449
|
-
|
|
3450
|
-
Gets all details of the groups associated with the Databricks workspace.
|
|
3390
|
+
"""Gets all details of the groups associated with the Databricks workspace.
|
|
3451
3391
|
|
|
3452
3392
|
:param attributes: str (optional)
|
|
3453
3393
|
Comma-separated list of attributes to return in response.
|
|
@@ -3510,9 +3450,7 @@ class GroupsAPI:
|
|
|
3510
3450
|
query["startIndex"] += len(json["Resources"])
|
|
3511
3451
|
|
|
3512
3452
|
def patch(self, id: str, *, operations: Optional[List[Patch]] = None, schemas: Optional[List[PatchSchema]] = None):
|
|
3513
|
-
"""
|
|
3514
|
-
|
|
3515
|
-
Partially updates the details of a group.
|
|
3453
|
+
"""Partially updates the details of a group.
|
|
3516
3454
|
|
|
3517
3455
|
:param id: str
|
|
3518
3456
|
Unique ID in the Databricks workspace.
|
|
@@ -3546,9 +3484,7 @@ class GroupsAPI:
|
|
|
3546
3484
|
roles: Optional[List[ComplexValue]] = None,
|
|
3547
3485
|
schemas: Optional[List[GroupSchema]] = None,
|
|
3548
3486
|
):
|
|
3549
|
-
"""
|
|
3550
|
-
|
|
3551
|
-
Updates the details of a group by replacing the entire group entity.
|
|
3487
|
+
"""Updates the details of a group by replacing the entire group entity.
|
|
3552
3488
|
|
|
3553
3489
|
:param id: str
|
|
3554
3490
|
Databricks group ID
|
|
@@ -3668,9 +3604,7 @@ class PermissionsAPI:
|
|
|
3668
3604
|
self._api = api_client
|
|
3669
3605
|
|
|
3670
3606
|
def get(self, request_object_type: str, request_object_id: str) -> ObjectPermissions:
|
|
3671
|
-
"""
|
|
3672
|
-
|
|
3673
|
-
Gets the permissions of an object. Objects can inherit permissions from their parent objects or root
|
|
3607
|
+
"""Gets the permissions of an object. Objects can inherit permissions from their parent objects or root
|
|
3674
3608
|
object.
|
|
3675
3609
|
|
|
3676
3610
|
:param request_object_type: str
|
|
@@ -3691,9 +3625,7 @@ class PermissionsAPI:
|
|
|
3691
3625
|
return ObjectPermissions.from_dict(res)
|
|
3692
3626
|
|
|
3693
3627
|
def get_permission_levels(self, request_object_type: str, request_object_id: str) -> GetPermissionLevelsResponse:
|
|
3694
|
-
"""
|
|
3695
|
-
|
|
3696
|
-
Gets the permission levels that a user can have on an object.
|
|
3628
|
+
"""Gets the permission levels that a user can have on an object.
|
|
3697
3629
|
|
|
3698
3630
|
:param request_object_type: str
|
|
3699
3631
|
The type of the request object. Can be one of the following: alerts, authorization, clusters,
|
|
@@ -3720,9 +3652,7 @@ class PermissionsAPI:
|
|
|
3720
3652
|
*,
|
|
3721
3653
|
access_control_list: Optional[List[AccessControlRequest]] = None,
|
|
3722
3654
|
) -> ObjectPermissions:
|
|
3723
|
-
"""
|
|
3724
|
-
|
|
3725
|
-
Sets permissions on an object, replacing existing permissions if they exist. Deletes all direct
|
|
3655
|
+
"""Sets permissions on an object, replacing existing permissions if they exist. Deletes all direct
|
|
3726
3656
|
permissions if none are specified. Objects can inherit permissions from their parent objects or root
|
|
3727
3657
|
object.
|
|
3728
3658
|
|
|
@@ -3756,9 +3686,7 @@ class PermissionsAPI:
|
|
|
3756
3686
|
*,
|
|
3757
3687
|
access_control_list: Optional[List[AccessControlRequest]] = None,
|
|
3758
3688
|
) -> ObjectPermissions:
|
|
3759
|
-
"""
|
|
3760
|
-
|
|
3761
|
-
Updates the permissions on an object. Objects can inherit permissions from their parent objects or
|
|
3689
|
+
"""Updates the permissions on an object. Objects can inherit permissions from their parent objects or
|
|
3762
3690
|
root object.
|
|
3763
3691
|
|
|
3764
3692
|
:param request_object_type: str
|
|
@@ -3808,9 +3736,7 @@ class ServicePrincipalsAPI:
|
|
|
3808
3736
|
roles: Optional[List[ComplexValue]] = None,
|
|
3809
3737
|
schemas: Optional[List[ServicePrincipalSchema]] = None,
|
|
3810
3738
|
) -> ServicePrincipal:
|
|
3811
|
-
"""
|
|
3812
|
-
|
|
3813
|
-
Creates a new service principal in the Databricks workspace.
|
|
3739
|
+
"""Creates a new service principal in the Databricks workspace.
|
|
3814
3740
|
|
|
3815
3741
|
:param active: bool (optional)
|
|
3816
3742
|
If this user is active
|
|
@@ -3862,9 +3788,7 @@ class ServicePrincipalsAPI:
|
|
|
3862
3788
|
return ServicePrincipal.from_dict(res)
|
|
3863
3789
|
|
|
3864
3790
|
def delete(self, id: str):
|
|
3865
|
-
"""Delete a service principal.
|
|
3866
|
-
|
|
3867
|
-
Delete a single service principal in the Databricks workspace.
|
|
3791
|
+
"""Delete a single service principal in the Databricks workspace.
|
|
3868
3792
|
|
|
3869
3793
|
:param id: str
|
|
3870
3794
|
Unique ID for a service principal in the Databricks workspace.
|
|
@@ -3877,9 +3801,7 @@ class ServicePrincipalsAPI:
|
|
|
3877
3801
|
self._api.do("DELETE", f"/api/2.0/preview/scim/v2/ServicePrincipals/{id}", headers=headers)
|
|
3878
3802
|
|
|
3879
3803
|
def get(self, id: str) -> ServicePrincipal:
|
|
3880
|
-
"""
|
|
3881
|
-
|
|
3882
|
-
Gets the details for a single service principal define in the Databricks workspace.
|
|
3804
|
+
"""Gets the details for a single service principal define in the Databricks workspace.
|
|
3883
3805
|
|
|
3884
3806
|
:param id: str
|
|
3885
3807
|
Unique ID for a service principal in the Databricks workspace.
|
|
@@ -3905,9 +3827,7 @@ class ServicePrincipalsAPI:
|
|
|
3905
3827
|
sort_order: Optional[ListSortOrder] = None,
|
|
3906
3828
|
start_index: Optional[int] = None,
|
|
3907
3829
|
) -> Iterator[ServicePrincipal]:
|
|
3908
|
-
"""
|
|
3909
|
-
|
|
3910
|
-
Gets the set of service principals associated with a Databricks workspace.
|
|
3830
|
+
"""Gets the set of service principals associated with a Databricks workspace.
|
|
3911
3831
|
|
|
3912
3832
|
:param attributes: str (optional)
|
|
3913
3833
|
Comma-separated list of attributes to return in response.
|
|
@@ -3970,9 +3890,7 @@ class ServicePrincipalsAPI:
|
|
|
3970
3890
|
query["startIndex"] += len(json["Resources"])
|
|
3971
3891
|
|
|
3972
3892
|
def patch(self, id: str, *, operations: Optional[List[Patch]] = None, schemas: Optional[List[PatchSchema]] = None):
|
|
3973
|
-
"""
|
|
3974
|
-
|
|
3975
|
-
Partially updates the details of a single service principal in the Databricks workspace.
|
|
3893
|
+
"""Partially updates the details of a single service principal in the Databricks workspace.
|
|
3976
3894
|
|
|
3977
3895
|
:param id: str
|
|
3978
3896
|
Unique ID in the Databricks workspace.
|
|
@@ -4006,9 +3924,7 @@ class ServicePrincipalsAPI:
|
|
|
4006
3924
|
roles: Optional[List[ComplexValue]] = None,
|
|
4007
3925
|
schemas: Optional[List[ServicePrincipalSchema]] = None,
|
|
4008
3926
|
):
|
|
4009
|
-
"""
|
|
4010
|
-
|
|
4011
|
-
Updates the details of a single service principal.
|
|
3927
|
+
"""Updates the details of a single service principal.
|
|
4012
3928
|
|
|
4013
3929
|
This action replaces the existing service principal with the same name.
|
|
4014
3930
|
|
|
@@ -4087,9 +4003,7 @@ class UsersAPI:
|
|
|
4087
4003
|
schemas: Optional[List[UserSchema]] = None,
|
|
4088
4004
|
user_name: Optional[str] = None,
|
|
4089
4005
|
) -> User:
|
|
4090
|
-
"""
|
|
4091
|
-
|
|
4092
|
-
Creates a new user in the Databricks workspace. This new user will also be added to the Databricks
|
|
4006
|
+
"""Creates a new user in the Databricks workspace. This new user will also be added to the Databricks
|
|
4093
4007
|
account.
|
|
4094
4008
|
|
|
4095
4009
|
:param active: bool (optional)
|
|
@@ -4153,9 +4067,7 @@ class UsersAPI:
|
|
|
4153
4067
|
return User.from_dict(res)
|
|
4154
4068
|
|
|
4155
4069
|
def delete(self, id: str):
|
|
4156
|
-
"""
|
|
4157
|
-
|
|
4158
|
-
Deletes a user. Deleting a user from a Databricks workspace also removes objects associated with the
|
|
4070
|
+
"""Deletes a user. Deleting a user from a Databricks workspace also removes objects associated with the
|
|
4159
4071
|
user.
|
|
4160
4072
|
|
|
4161
4073
|
:param id: str
|
|
@@ -4180,9 +4092,7 @@ class UsersAPI:
|
|
|
4180
4092
|
sort_order: Optional[GetSortOrder] = None,
|
|
4181
4093
|
start_index: Optional[int] = None,
|
|
4182
4094
|
) -> User:
|
|
4183
|
-
"""
|
|
4184
|
-
|
|
4185
|
-
Gets information for a specific user in Databricks workspace.
|
|
4095
|
+
"""Gets information for a specific user in Databricks workspace.
|
|
4186
4096
|
|
|
4187
4097
|
:param id: str
|
|
4188
4098
|
Unique ID for a user in the Databricks workspace.
|
|
@@ -4233,9 +4143,8 @@ class UsersAPI:
|
|
|
4233
4143
|
return User.from_dict(res)
|
|
4234
4144
|
|
|
4235
4145
|
def get_permission_levels(self) -> GetPasswordPermissionLevelsResponse:
|
|
4236
|
-
"""
|
|
4146
|
+
"""Gets the permission levels that a user can have on an object.
|
|
4237
4147
|
|
|
4238
|
-
Gets the permission levels that a user can have on an object.
|
|
4239
4148
|
|
|
4240
4149
|
:returns: :class:`GetPasswordPermissionLevelsResponse`
|
|
4241
4150
|
"""
|
|
@@ -4248,9 +4157,8 @@ class UsersAPI:
|
|
|
4248
4157
|
return GetPasswordPermissionLevelsResponse.from_dict(res)
|
|
4249
4158
|
|
|
4250
4159
|
def get_permissions(self) -> PasswordPermissions:
|
|
4251
|
-
"""
|
|
4160
|
+
"""Gets the permissions of all passwords. Passwords can inherit permissions from their root object.
|
|
4252
4161
|
|
|
4253
|
-
Gets the permissions of all passwords. Passwords can inherit permissions from their root object.
|
|
4254
4162
|
|
|
4255
4163
|
:returns: :class:`PasswordPermissions`
|
|
4256
4164
|
"""
|
|
@@ -4273,9 +4181,7 @@ class UsersAPI:
|
|
|
4273
4181
|
sort_order: Optional[ListSortOrder] = None,
|
|
4274
4182
|
start_index: Optional[int] = None,
|
|
4275
4183
|
) -> Iterator[User]:
|
|
4276
|
-
"""
|
|
4277
|
-
|
|
4278
|
-
Gets details for all the users associated with a Databricks workspace.
|
|
4184
|
+
"""Gets details for all the users associated with a Databricks workspace.
|
|
4279
4185
|
|
|
4280
4186
|
:param attributes: str (optional)
|
|
4281
4187
|
Comma-separated list of attributes to return in response.
|
|
@@ -4339,9 +4245,7 @@ class UsersAPI:
|
|
|
4339
4245
|
query["startIndex"] += len(json["Resources"])
|
|
4340
4246
|
|
|
4341
4247
|
def patch(self, id: str, *, operations: Optional[List[Patch]] = None, schemas: Optional[List[PatchSchema]] = None):
|
|
4342
|
-
"""
|
|
4343
|
-
|
|
4344
|
-
Partially updates a user resource by applying the supplied operations on specific user attributes.
|
|
4248
|
+
"""Partially updates a user resource by applying the supplied operations on specific user attributes.
|
|
4345
4249
|
|
|
4346
4250
|
:param id: str
|
|
4347
4251
|
Unique ID in the Databricks workspace.
|
|
@@ -4365,9 +4269,7 @@ class UsersAPI:
|
|
|
4365
4269
|
def set_permissions(
|
|
4366
4270
|
self, *, access_control_list: Optional[List[PasswordAccessControlRequest]] = None
|
|
4367
4271
|
) -> PasswordPermissions:
|
|
4368
|
-
"""
|
|
4369
|
-
|
|
4370
|
-
Sets permissions on an object, replacing existing permissions if they exist. Deletes all direct
|
|
4272
|
+
"""Sets permissions on an object, replacing existing permissions if they exist. Deletes all direct
|
|
4371
4273
|
permissions if none are specified. Objects can inherit permissions from their root object.
|
|
4372
4274
|
|
|
4373
4275
|
:param access_control_list: List[:class:`PasswordAccessControlRequest`] (optional)
|
|
@@ -4400,9 +4302,7 @@ class UsersAPI:
|
|
|
4400
4302
|
schemas: Optional[List[UserSchema]] = None,
|
|
4401
4303
|
user_name: Optional[str] = None,
|
|
4402
4304
|
):
|
|
4403
|
-
"""
|
|
4404
|
-
|
|
4405
|
-
Replaces a user's information with the data supplied in request.
|
|
4305
|
+
"""Replaces a user's information with the data supplied in request.
|
|
4406
4306
|
|
|
4407
4307
|
:param id: str
|
|
4408
4308
|
Databricks user ID.
|
|
@@ -4463,9 +4363,7 @@ class UsersAPI:
|
|
|
4463
4363
|
def update_permissions(
|
|
4464
4364
|
self, *, access_control_list: Optional[List[PasswordAccessControlRequest]] = None
|
|
4465
4365
|
) -> PasswordPermissions:
|
|
4466
|
-
"""
|
|
4467
|
-
|
|
4468
|
-
Updates the permissions on all passwords. Passwords can inherit permissions from their root object.
|
|
4366
|
+
"""Updates the permissions on all passwords. Passwords can inherit permissions from their root object.
|
|
4469
4367
|
|
|
4470
4368
|
:param access_control_list: List[:class:`PasswordAccessControlRequest`] (optional)
|
|
4471
4369
|
|
|
@@ -4491,9 +4389,7 @@ class WorkspaceAssignmentAPI:
|
|
|
4491
4389
|
self._api = api_client
|
|
4492
4390
|
|
|
4493
4391
|
def delete(self, workspace_id: int, principal_id: int):
|
|
4494
|
-
"""
|
|
4495
|
-
|
|
4496
|
-
Deletes the workspace permissions assignment in a given account and workspace for the specified
|
|
4392
|
+
"""Deletes the workspace permissions assignment in a given account and workspace for the specified
|
|
4497
4393
|
principal.
|
|
4498
4394
|
|
|
4499
4395
|
:param workspace_id: int
|
|
@@ -4515,9 +4411,7 @@ class WorkspaceAssignmentAPI:
|
|
|
4515
4411
|
)
|
|
4516
4412
|
|
|
4517
4413
|
def get(self, workspace_id: int) -> WorkspacePermissions:
|
|
4518
|
-
"""
|
|
4519
|
-
|
|
4520
|
-
Get an array of workspace permissions for the specified account and workspace.
|
|
4414
|
+
"""Get an array of workspace permissions for the specified account and workspace.
|
|
4521
4415
|
|
|
4522
4416
|
:param workspace_id: int
|
|
4523
4417
|
The workspace ID.
|
|
@@ -4537,9 +4431,7 @@ class WorkspaceAssignmentAPI:
|
|
|
4537
4431
|
return WorkspacePermissions.from_dict(res)
|
|
4538
4432
|
|
|
4539
4433
|
def list(self, workspace_id: int) -> Iterator[PermissionAssignment]:
|
|
4540
|
-
"""Get permission assignments.
|
|
4541
|
-
|
|
4542
|
-
Get the permission assignments for the specified Databricks account and Databricks workspace.
|
|
4434
|
+
"""Get the permission assignments for the specified Databricks account and Databricks workspace.
|
|
4543
4435
|
|
|
4544
4436
|
:param workspace_id: int
|
|
4545
4437
|
The workspace ID for the account.
|
|
@@ -4562,9 +4454,7 @@ class WorkspaceAssignmentAPI:
|
|
|
4562
4454
|
def update(
|
|
4563
4455
|
self, workspace_id: int, principal_id: int, *, permissions: Optional[List[WorkspacePermission]] = None
|
|
4564
4456
|
) -> PermissionAssignment:
|
|
4565
|
-
"""
|
|
4566
|
-
|
|
4567
|
-
Creates or updates the workspace permissions assignment in a given account and workspace for the
|
|
4457
|
+
"""Creates or updates the workspace permissions assignment in a given account and workspace for the
|
|
4568
4458
|
specified principal.
|
|
4569
4459
|
|
|
4570
4460
|
:param workspace_id: int
|