databricks-sdk 0.55.0__py3-none-any.whl → 0.57.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.

Files changed (31) hide show
  1. databricks/sdk/__init__.py +41 -24
  2. databricks/sdk/service/aibuilder.py +505 -0
  3. databricks/sdk/service/apps.py +14 -42
  4. databricks/sdk/service/billing.py +167 -220
  5. databricks/sdk/service/catalog.py +462 -1235
  6. databricks/sdk/service/cleanrooms.py +26 -43
  7. databricks/sdk/service/compute.py +75 -211
  8. databricks/sdk/service/dashboards.py +77 -511
  9. databricks/sdk/service/database.py +1271 -0
  10. databricks/sdk/service/files.py +20 -54
  11. databricks/sdk/service/iam.py +61 -171
  12. databricks/sdk/service/jobs.py +453 -68
  13. databricks/sdk/service/marketplace.py +46 -146
  14. databricks/sdk/service/ml.py +453 -477
  15. databricks/sdk/service/oauth2.py +17 -45
  16. databricks/sdk/service/pipelines.py +125 -40
  17. databricks/sdk/service/provisioning.py +30 -93
  18. databricks/sdk/service/qualitymonitorv2.py +265 -0
  19. databricks/sdk/service/serving.py +106 -46
  20. databricks/sdk/service/settings.py +1062 -390
  21. databricks/sdk/service/sharing.py +33 -88
  22. databricks/sdk/service/sql.py +292 -185
  23. databricks/sdk/service/vectorsearch.py +13 -43
  24. databricks/sdk/service/workspace.py +35 -105
  25. databricks/sdk/version.py +1 -1
  26. {databricks_sdk-0.55.0.dist-info → databricks_sdk-0.57.0.dist-info}/METADATA +1 -1
  27. {databricks_sdk-0.55.0.dist-info → databricks_sdk-0.57.0.dist-info}/RECORD +31 -28
  28. {databricks_sdk-0.55.0.dist-info → databricks_sdk-0.57.0.dist-info}/WHEEL +0 -0
  29. {databricks_sdk-0.55.0.dist-info → databricks_sdk-0.57.0.dist-info}/licenses/LICENSE +0 -0
  30. {databricks_sdk-0.55.0.dist-info → databricks_sdk-0.57.0.dist-info}/licenses/NOTICE +0 -0
  31. {databricks_sdk-0.55.0.dist-info → databricks_sdk-0.57.0.dist-info}/top_level.txt +0 -0
@@ -3528,16 +3528,10 @@ class CustomPolicyTag:
3528
3528
  key: str
3529
3529
  """The key of the tag. - Must be unique among all custom tags of the same policy - Cannot be
3530
3530
  “budget-policy-name”, “budget-policy-id” or "budget-policy-resolution-result" - these
3531
- tags are preserved.
3532
-
3533
- - Follows the regex pattern defined in cluster-common/conf/src/ClusterTagConstraints.scala
3534
- (https://src.dev.databricks.com/databricks/universe@1647196627c8dc7b4152ad098a94b86484b93a6c/-/blob/cluster-common/conf/src/ClusterTagConstraints.scala?L17)"""
3531
+ tags are preserved."""
3535
3532
 
3536
3533
  value: Optional[str] = None
3537
- """The value of the tag.
3538
-
3539
- - Follows the regex pattern defined in cluster-common/conf/src/ClusterTagConstraints.scala
3540
- (https://src.dev.databricks.com/databricks/universe@1647196627c8dc7b4152ad098a94b86484b93a6c/-/blob/cluster-common/conf/src/ClusterTagConstraints.scala?L24)"""
3534
+ """The value of the tag."""
3541
3535
 
3542
3536
  def as_dict(self) -> dict:
3543
3537
  """Serializes the CustomPolicyTag into a dictionary suitable for use as a JSON request body."""
@@ -4781,25 +4775,19 @@ class Environment:
4781
4775
  non-notebook task, and DLT's environment for classic and serverless pipelines. In this minimal
4782
4776
  environment spec, only pip dependencies are supported."""
4783
4777
 
4784
- client: str
4785
- """Client version used by the environment The client is the user-facing environment of the runtime.
4786
- Each client comes with a specific set of pre-installed libraries. The version is a string,
4787
- consisting of the major client version."""
4778
+ client: Optional[str] = None
4779
+ """Use `environment_version` instead."""
4788
4780
 
4789
4781
  dependencies: Optional[List[str]] = None
4790
4782
  """List of pip dependencies, as supported by the version of pip in this environment. Each
4791
- dependency is a pip requirement file line
4792
- https://pip.pypa.io/en/stable/reference/requirements-file-format/ Allowed dependency could be
4793
- <requirement specifier>, <archive url/path>, <local project path>(WSFS or Volumes in
4794
- Databricks), <vcs project url> E.g. dependencies: ["foo==0.0.1", "-r
4795
- /Workspace/test/requirements.txt"]"""
4783
+ dependency is a valid pip requirements file line per
4784
+ https://pip.pypa.io/en/stable/reference/requirements-file-format/. Allowed dependencies include
4785
+ a requirement specifier, an archive URL, a local project path (such as WSFS or UC Volumes in
4786
+ Databricks), or a VCS project URL."""
4796
4787
 
4797
4788
  environment_version: Optional[str] = None
4798
- """We renamed `client` to `environment_version` in notebook exports. This field is meant solely so
4799
- that imported notebooks with `environment_version` can be deserialized correctly, in a
4800
- backwards-compatible way (i.e. if `client` is specified instead of `environment_version`, it
4801
- will be deserialized correctly). Do NOT use this field for any other purpose, e.g. notebook
4802
- storage. This field is not yet exposed to customers (e.g. in the jobs API)."""
4789
+ """Required. Environment version used by the environment. Each version comes with a specific Python
4790
+ version and a set of Python packages. The version is a string, consisting of an integer."""
4803
4791
 
4804
4792
  jar_dependencies: Optional[List[str]] = None
4805
4793
  """List of jar dependencies, should be string representing volume paths. For example:
@@ -5038,6 +5026,7 @@ class EventType(Enum):
5038
5026
  AUTOSCALING_BACKOFF = "AUTOSCALING_BACKOFF"
5039
5027
  AUTOSCALING_FAILED = "AUTOSCALING_FAILED"
5040
5028
  AUTOSCALING_STATS_REPORT = "AUTOSCALING_STATS_REPORT"
5029
+ CLUSTER_MIGRATED = "CLUSTER_MIGRATED"
5041
5030
  CREATING = "CREATING"
5042
5031
  DBFS_DOWN = "DBFS_DOWN"
5043
5032
  DID_NOT_EXPAND_DISK = "DID_NOT_EXPAND_DISK"
@@ -9082,6 +9071,7 @@ class TerminationReasonCode(Enum):
9082
9071
  DRIVER_OUT_OF_MEMORY = "DRIVER_OUT_OF_MEMORY"
9083
9072
  DRIVER_POD_CREATION_FAILURE = "DRIVER_POD_CREATION_FAILURE"
9084
9073
  DRIVER_UNEXPECTED_FAILURE = "DRIVER_UNEXPECTED_FAILURE"
9074
+ DRIVER_UNHEALTHY = "DRIVER_UNHEALTHY"
9085
9075
  DRIVER_UNREACHABLE = "DRIVER_UNREACHABLE"
9086
9076
  DRIVER_UNRESPONSIVE = "DRIVER_UNRESPONSIVE"
9087
9077
  DYNAMIC_SPARK_CONF_SIZE_EXCEEDED = "DYNAMIC_SPARK_CONF_SIZE_EXCEEDED"
@@ -9844,9 +9834,7 @@ class ClusterPoliciesAPI:
9844
9834
  policy_family_definition_overrides: Optional[str] = None,
9845
9835
  policy_family_id: Optional[str] = None,
9846
9836
  ) -> CreatePolicyResponse:
9847
- """Create a new policy.
9848
-
9849
- Creates a new policy with prescribed settings.
9837
+ """Creates a new policy with prescribed settings.
9850
9838
 
9851
9839
  :param definition: str (optional)
9852
9840
  Policy definition document expressed in [Databricks Cluster Policy Definition Language].
@@ -9904,9 +9892,7 @@ class ClusterPoliciesAPI:
9904
9892
  return CreatePolicyResponse.from_dict(res)
9905
9893
 
9906
9894
  def delete(self, policy_id: str):
9907
- """Delete a cluster policy.
9908
-
9909
- Delete a policy for a cluster. Clusters governed by this policy can still run, but cannot be edited.
9895
+ """Delete a policy for a cluster. Clusters governed by this policy can still run, but cannot be edited.
9910
9896
 
9911
9897
  :param policy_id: str
9912
9898
  The ID of the policy to delete.
@@ -9935,9 +9921,7 @@ class ClusterPoliciesAPI:
9935
9921
  policy_family_definition_overrides: Optional[str] = None,
9936
9922
  policy_family_id: Optional[str] = None,
9937
9923
  ):
9938
- """Update a cluster policy.
9939
-
9940
- Update an existing policy for cluster. This operation may make some clusters governed by the previous
9924
+ """Update an existing policy for cluster. This operation may make some clusters governed by the previous
9941
9925
  policy invalid.
9942
9926
 
9943
9927
  :param policy_id: str
@@ -9999,9 +9983,7 @@ class ClusterPoliciesAPI:
9999
9983
  self._api.do("POST", "/api/2.0/policies/clusters/edit", body=body, headers=headers)
10000
9984
 
10001
9985
  def get(self, policy_id: str) -> Policy:
10002
- """Get a cluster policy.
10003
-
10004
- Get a cluster policy entity. Creation and editing is available to admins only.
9986
+ """Get a cluster policy entity. Creation and editing is available to admins only.
10005
9987
 
10006
9988
  :param policy_id: str
10007
9989
  Canonical unique identifier for the Cluster Policy.
@@ -10020,9 +10002,7 @@ class ClusterPoliciesAPI:
10020
10002
  return Policy.from_dict(res)
10021
10003
 
10022
10004
  def get_permission_levels(self, cluster_policy_id: str) -> GetClusterPolicyPermissionLevelsResponse:
10023
- """Get cluster policy permission levels.
10024
-
10025
- Gets the permission levels that a user can have on an object.
10005
+ """Gets the permission levels that a user can have on an object.
10026
10006
 
10027
10007
  :param cluster_policy_id: str
10028
10008
  The cluster policy for which to get or manage permissions.
@@ -10040,9 +10020,7 @@ class ClusterPoliciesAPI:
10040
10020
  return GetClusterPolicyPermissionLevelsResponse.from_dict(res)
10041
10021
 
10042
10022
  def get_permissions(self, cluster_policy_id: str) -> ClusterPolicyPermissions:
10043
- """Get cluster policy permissions.
10044
-
10045
- Gets the permissions of a cluster policy. Cluster policies can inherit permissions from their root
10023
+ """Gets the permissions of a cluster policy. Cluster policies can inherit permissions from their root
10046
10024
  object.
10047
10025
 
10048
10026
  :param cluster_policy_id: str
@@ -10061,9 +10039,7 @@ class ClusterPoliciesAPI:
10061
10039
  def list(
10062
10040
  self, *, sort_column: Optional[ListSortColumn] = None, sort_order: Optional[ListSortOrder] = None
10063
10041
  ) -> Iterator[Policy]:
10064
- """List cluster policies.
10065
-
10066
- Returns a list of policies accessible by the requesting user.
10042
+ """Returns a list of policies accessible by the requesting user.
10067
10043
 
10068
10044
  :param sort_column: :class:`ListSortColumn` (optional)
10069
10045
  The cluster policy attribute to sort by. * `POLICY_CREATION_TIME` - Sort result list by policy
@@ -10091,9 +10067,7 @@ class ClusterPoliciesAPI:
10091
10067
  def set_permissions(
10092
10068
  self, cluster_policy_id: str, *, access_control_list: Optional[List[ClusterPolicyAccessControlRequest]] = None
10093
10069
  ) -> ClusterPolicyPermissions:
10094
- """Set cluster policy permissions.
10095
-
10096
- Sets permissions on an object, replacing existing permissions if they exist. Deletes all direct
10070
+ """Sets permissions on an object, replacing existing permissions if they exist. Deletes all direct
10097
10071
  permissions if none are specified. Objects can inherit permissions from their root object.
10098
10072
 
10099
10073
  :param cluster_policy_id: str
@@ -10118,9 +10092,7 @@ class ClusterPoliciesAPI:
10118
10092
  def update_permissions(
10119
10093
  self, cluster_policy_id: str, *, access_control_list: Optional[List[ClusterPolicyAccessControlRequest]] = None
10120
10094
  ) -> ClusterPolicyPermissions:
10121
- """Update cluster policy permissions.
10122
-
10123
- Updates the permissions on a cluster policy. Cluster policies can inherit permissions from their root
10095
+ """Updates the permissions on a cluster policy. Cluster policies can inherit permissions from their root
10124
10096
  object.
10125
10097
 
10126
10098
  :param cluster_policy_id: str
@@ -10236,9 +10208,7 @@ class ClustersAPI:
10236
10208
  raise TimeoutError(f"timed out after {timeout}: {status_message}")
10237
10209
 
10238
10210
  def change_owner(self, cluster_id: str, owner_username: str):
10239
- """Change cluster owner.
10240
-
10241
- Change the owner of the cluster. You must be an admin and the cluster must be terminated to perform
10211
+ """Change the owner of the cluster. You must be an admin and the cluster must be terminated to perform
10242
10212
  this operation. The service principal application ID can be supplied as an argument to
10243
10213
  `owner_username`.
10244
10214
 
@@ -10295,9 +10265,7 @@ class ClustersAPI:
10295
10265
  use_ml_runtime: Optional[bool] = None,
10296
10266
  workload_type: Optional[WorkloadType] = None,
10297
10267
  ) -> Wait[ClusterDetails]:
10298
- """Create new cluster.
10299
-
10300
- Creates a new Spark cluster. This method will acquire new instances from the cloud provider if
10268
+ """Creates a new Spark cluster. This method will acquire new instances from the cloud provider if
10301
10269
  necessary. This method is asynchronous; the returned ``cluster_id`` can be used to poll the cluster
10302
10270
  status. When this method returns, the cluster will be in a ``PENDING`` state. The cluster will be
10303
10271
  usable once it enters a ``RUNNING`` state. Note: Databricks may not be able to acquire some of the
@@ -10625,9 +10593,7 @@ class ClustersAPI:
10625
10593
  ).result(timeout=timeout)
10626
10594
 
10627
10595
  def delete(self, cluster_id: str) -> Wait[ClusterDetails]:
10628
- """Terminate cluster.
10629
-
10630
- Terminates the Spark cluster with the specified ID. The cluster is removed asynchronously. Once the
10596
+ """Terminates the Spark cluster with the specified ID. The cluster is removed asynchronously. Once the
10631
10597
  termination has completed, the cluster will be in a `TERMINATED` state. If the cluster is already in a
10632
10598
  `TERMINATING` or `TERMINATED` state, nothing will happen.
10633
10599
 
@@ -10691,9 +10657,7 @@ class ClustersAPI:
10691
10657
  use_ml_runtime: Optional[bool] = None,
10692
10658
  workload_type: Optional[WorkloadType] = None,
10693
10659
  ) -> Wait[ClusterDetails]:
10694
- """Update cluster configuration.
10695
-
10696
- Updates the configuration of a cluster to match the provided attributes and size. A cluster can be
10660
+ """Updates the configuration of a cluster to match the provided attributes and size. A cluster can be
10697
10661
  updated if it is in a `RUNNING` or `TERMINATED` state.
10698
10662
 
10699
10663
  If a cluster is updated while in a `RUNNING` state, it will be restarted so that the new attributes
@@ -11028,9 +10992,7 @@ class ClustersAPI:
11028
10992
  page_token: Optional[str] = None,
11029
10993
  start_time: Optional[int] = None,
11030
10994
  ) -> Iterator[ClusterEvent]:
11031
- """List cluster activity events.
11032
-
11033
- Retrieves a list of events about the activity of a cluster. This API is paginated. If there are more
10995
+ """Retrieves a list of events about the activity of a cluster. This API is paginated. If there are more
11034
10996
  events to read, the response includes all the parameters necessary to request the next page of events.
11035
10997
 
11036
10998
  :param cluster_id: str
@@ -11098,9 +11060,7 @@ class ClustersAPI:
11098
11060
  body = json["next_page"]
11099
11061
 
11100
11062
  def get(self, cluster_id: str) -> ClusterDetails:
11101
- """Get cluster info.
11102
-
11103
- Retrieves the information for a cluster given its identifier. Clusters can be described while they are
11063
+ """Retrieves the information for a cluster given its identifier. Clusters can be described while they are
11104
11064
  running, or up to 60 days after they are terminated.
11105
11065
 
11106
11066
  :param cluster_id: str
@@ -11120,9 +11080,7 @@ class ClustersAPI:
11120
11080
  return ClusterDetails.from_dict(res)
11121
11081
 
11122
11082
  def get_permission_levels(self, cluster_id: str) -> GetClusterPermissionLevelsResponse:
11123
- """Get cluster permission levels.
11124
-
11125
- Gets the permission levels that a user can have on an object.
11083
+ """Gets the permission levels that a user can have on an object.
11126
11084
 
11127
11085
  :param cluster_id: str
11128
11086
  The cluster for which to get or manage permissions.
@@ -11138,9 +11096,7 @@ class ClustersAPI:
11138
11096
  return GetClusterPermissionLevelsResponse.from_dict(res)
11139
11097
 
11140
11098
  def get_permissions(self, cluster_id: str) -> ClusterPermissions:
11141
- """Get cluster permissions.
11142
-
11143
- Gets the permissions of a cluster. Clusters can inherit permissions from their root object.
11099
+ """Gets the permissions of a cluster. Clusters can inherit permissions from their root object.
11144
11100
 
11145
11101
  :param cluster_id: str
11146
11102
  The cluster for which to get or manage permissions.
@@ -11163,9 +11119,7 @@ class ClustersAPI:
11163
11119
  page_token: Optional[str] = None,
11164
11120
  sort_by: Optional[ListClustersSortBy] = None,
11165
11121
  ) -> Iterator[ClusterDetails]:
11166
- """List clusters.
11167
-
11168
- Return information about all pinned and active clusters, and all clusters terminated within the last
11122
+ """Return information about all pinned and active clusters, and all clusters terminated within the last
11169
11123
  30 days. Clusters terminated prior to this period are not included.
11170
11124
 
11171
11125
  :param filter_by: :class:`ListClustersFilterBy` (optional)
@@ -11205,9 +11159,7 @@ class ClustersAPI:
11205
11159
  query["page_token"] = json["next_page_token"]
11206
11160
 
11207
11161
  def list_node_types(self) -> ListNodeTypesResponse:
11208
- """List node types.
11209
-
11210
- Returns a list of supported Spark node types. These node types can be used to launch a cluster.
11162
+ """Returns a list of supported Spark node types. These node types can be used to launch a cluster.
11211
11163
 
11212
11164
  :returns: :class:`ListNodeTypesResponse`
11213
11165
  """
@@ -11220,9 +11172,7 @@ class ClustersAPI:
11220
11172
  return ListNodeTypesResponse.from_dict(res)
11221
11173
 
11222
11174
  def list_zones(self) -> ListAvailableZonesResponse:
11223
- """List availability zones.
11224
-
11225
- Returns a list of availability zones where clusters can be created in (For example, us-west-2a). These
11175
+ """Returns a list of availability zones where clusters can be created in (For example, us-west-2a). These
11226
11176
  zones can be used to launch a cluster.
11227
11177
 
11228
11178
  :returns: :class:`ListAvailableZonesResponse`
@@ -11236,9 +11186,7 @@ class ClustersAPI:
11236
11186
  return ListAvailableZonesResponse.from_dict(res)
11237
11187
 
11238
11188
  def permanent_delete(self, cluster_id: str):
11239
- """Permanently delete cluster.
11240
-
11241
- Permanently deletes a Spark cluster. This cluster is terminated and resources are asynchronously
11189
+ """Permanently deletes a Spark cluster. This cluster is terminated and resources are asynchronously
11242
11190
  removed.
11243
11191
 
11244
11192
  In addition, users will no longer see permanently deleted clusters in the cluster list, and API users
@@ -11260,9 +11208,7 @@ class ClustersAPI:
11260
11208
  self._api.do("POST", "/api/2.1/clusters/permanent-delete", body=body, headers=headers)
11261
11209
 
11262
11210
  def pin(self, cluster_id: str):
11263
- """Pin cluster.
11264
-
11265
- Pinning a cluster ensures that the cluster will always be returned by the ListClusters API. Pinning a
11211
+ """Pinning a cluster ensures that the cluster will always be returned by the ListClusters API. Pinning a
11266
11212
  cluster that is already pinned will have no effect. This API can only be called by workspace admins.
11267
11213
 
11268
11214
  :param cluster_id: str
@@ -11282,9 +11228,7 @@ class ClustersAPI:
11282
11228
  def resize(
11283
11229
  self, cluster_id: str, *, autoscale: Optional[AutoScale] = None, num_workers: Optional[int] = None
11284
11230
  ) -> Wait[ClusterDetails]:
11285
- """Resize cluster.
11286
-
11287
- Resizes a cluster to have a desired number of workers. This will fail unless the cluster is in a
11231
+ """Resizes a cluster to have a desired number of workers. This will fail unless the cluster is in a
11288
11232
  `RUNNING` state.
11289
11233
 
11290
11234
  :param cluster_id: str
@@ -11334,9 +11278,7 @@ class ClustersAPI:
11334
11278
  return self.resize(autoscale=autoscale, cluster_id=cluster_id, num_workers=num_workers).result(timeout=timeout)
11335
11279
 
11336
11280
  def restart(self, cluster_id: str, *, restart_user: Optional[str] = None) -> Wait[ClusterDetails]:
11337
- """Restart cluster.
11338
-
11339
- Restarts a Spark cluster with the supplied ID. If the cluster is not currently in a `RUNNING` state,
11281
+ """Restarts a Spark cluster with the supplied ID. If the cluster is not currently in a `RUNNING` state,
11340
11282
  nothing will happen.
11341
11283
 
11342
11284
  :param cluster_id: str
@@ -11370,9 +11312,7 @@ class ClustersAPI:
11370
11312
  def set_permissions(
11371
11313
  self, cluster_id: str, *, access_control_list: Optional[List[ClusterAccessControlRequest]] = None
11372
11314
  ) -> ClusterPermissions:
11373
- """Set cluster permissions.
11374
-
11375
- Sets permissions on an object, replacing existing permissions if they exist. Deletes all direct
11315
+ """Sets permissions on an object, replacing existing permissions if they exist. Deletes all direct
11376
11316
  permissions if none are specified. Objects can inherit permissions from their root object.
11377
11317
 
11378
11318
  :param cluster_id: str
@@ -11393,9 +11333,7 @@ class ClustersAPI:
11393
11333
  return ClusterPermissions.from_dict(res)
11394
11334
 
11395
11335
  def spark_versions(self) -> GetSparkVersionsResponse:
11396
- """List available Spark versions.
11397
-
11398
- Returns the list of available Spark versions. These versions can be used to launch a cluster.
11336
+ """Returns the list of available Spark versions. These versions can be used to launch a cluster.
11399
11337
 
11400
11338
  :returns: :class:`GetSparkVersionsResponse`
11401
11339
  """
@@ -11408,9 +11346,7 @@ class ClustersAPI:
11408
11346
  return GetSparkVersionsResponse.from_dict(res)
11409
11347
 
11410
11348
  def start(self, cluster_id: str) -> Wait[ClusterDetails]:
11411
- """Start terminated cluster.
11412
-
11413
- Starts a terminated Spark cluster with the supplied ID. This works similar to `createCluster` except:
11349
+ """Starts a terminated Spark cluster with the supplied ID. This works similar to `createCluster` except:
11414
11350
  - The previous cluster id and attributes are preserved. - The cluster starts with the last specified
11415
11351
  cluster size. - If the previous cluster was an autoscaling cluster, the current cluster starts with
11416
11352
  the minimum number of nodes. - If the cluster is not currently in a ``TERMINATED`` state, nothing will
@@ -11440,9 +11376,7 @@ class ClustersAPI:
11440
11376
  return self.start(cluster_id=cluster_id).result(timeout=timeout)
11441
11377
 
11442
11378
  def unpin(self, cluster_id: str):
11443
- """Unpin cluster.
11444
-
11445
- Unpinning a cluster will allow the cluster to eventually be removed from the ListClusters API.
11379
+ """Unpinning a cluster will allow the cluster to eventually be removed from the ListClusters API.
11446
11380
  Unpinning a cluster that is not pinned will have no effect. This API can only be called by workspace
11447
11381
  admins.
11448
11382
 
@@ -11463,9 +11397,7 @@ class ClustersAPI:
11463
11397
  def update(
11464
11398
  self, cluster_id: str, update_mask: str, *, cluster: Optional[UpdateClusterResource] = None
11465
11399
  ) -> Wait[ClusterDetails]:
11466
- """Update cluster configuration (partial).
11467
-
11468
- Updates the configuration of a cluster to match the partial set of attributes and size. Denote which
11400
+ """Updates the configuration of a cluster to match the partial set of attributes and size. Denote which
11469
11401
  fields to update using the `update_mask` field in the request body. A cluster can be updated if it is
11470
11402
  in a `RUNNING` or `TERMINATED` state. If a cluster is updated while in a `RUNNING` state, it will be
11471
11403
  restarted so that the new attributes can take effect. If a cluster is updated while in a `TERMINATED`
@@ -11526,9 +11458,7 @@ class ClustersAPI:
11526
11458
  def update_permissions(
11527
11459
  self, cluster_id: str, *, access_control_list: Optional[List[ClusterAccessControlRequest]] = None
11528
11460
  ) -> ClusterPermissions:
11529
- """Update cluster permissions.
11530
-
11531
- Updates the permissions on a cluster. Clusters can inherit permissions from their root object.
11461
+ """Updates the permissions on a cluster. Clusters can inherit permissions from their root object.
11532
11462
 
11533
11463
  :param cluster_id: str
11534
11464
  The cluster for which to get or manage permissions.
@@ -11667,9 +11597,7 @@ class CommandExecutionAPI:
11667
11597
  def cancel(
11668
11598
  self, *, cluster_id: Optional[str] = None, command_id: Optional[str] = None, context_id: Optional[str] = None
11669
11599
  ) -> Wait[CommandStatusResponse]:
11670
- """Cancel a command.
11671
-
11672
- Cancels a currently running command within an execution context.
11600
+ """Cancels a currently running command within an execution context.
11673
11601
 
11674
11602
  The command ID is obtained from a prior successful call to __execute__.
11675
11603
 
@@ -11713,9 +11641,7 @@ class CommandExecutionAPI:
11713
11641
  return self.cancel(cluster_id=cluster_id, command_id=command_id, context_id=context_id).result(timeout=timeout)
11714
11642
 
11715
11643
  def command_status(self, cluster_id: str, context_id: str, command_id: str) -> CommandStatusResponse:
11716
- """Get command info.
11717
-
11718
- Gets the status of and, if available, the results from a currently executing command.
11644
+ """Gets the status of and, if available, the results from a currently executing command.
11719
11645
 
11720
11646
  The command ID is obtained from a prior successful call to __execute__.
11721
11647
 
@@ -11741,9 +11667,7 @@ class CommandExecutionAPI:
11741
11667
  return CommandStatusResponse.from_dict(res)
11742
11668
 
11743
11669
  def context_status(self, cluster_id: str, context_id: str) -> ContextStatusResponse:
11744
- """Get status.
11745
-
11746
- Gets the status for an execution context.
11670
+ """Gets the status for an execution context.
11747
11671
 
11748
11672
  :param cluster_id: str
11749
11673
  :param context_id: str
@@ -11766,9 +11690,7 @@ class CommandExecutionAPI:
11766
11690
  def create(
11767
11691
  self, *, cluster_id: Optional[str] = None, language: Optional[Language] = None
11768
11692
  ) -> Wait[ContextStatusResponse]:
11769
- """Create an execution context.
11770
-
11771
- Creates an execution context for running cluster commands.
11693
+ """Creates an execution context for running cluster commands.
11772
11694
 
11773
11695
  If successful, this method returns the ID of the new execution context.
11774
11696
 
@@ -11804,9 +11726,7 @@ class CommandExecutionAPI:
11804
11726
  return self.create(cluster_id=cluster_id, language=language).result(timeout=timeout)
11805
11727
 
11806
11728
  def destroy(self, cluster_id: str, context_id: str):
11807
- """Delete an execution context.
11808
-
11809
- Deletes an execution context.
11729
+ """Deletes an execution context.
11810
11730
 
11811
11731
  :param cluster_id: str
11812
11732
  :param context_id: str
@@ -11833,9 +11753,7 @@ class CommandExecutionAPI:
11833
11753
  context_id: Optional[str] = None,
11834
11754
  language: Optional[Language] = None,
11835
11755
  ) -> Wait[CommandStatusResponse]:
11836
- """Run a command.
11837
-
11838
- Runs a cluster command in the given execution context, using the provided language.
11756
+ """Runs a cluster command in the given execution context, using the provided language.
11839
11757
 
11840
11758
  If successful, it returns an ID for tracking the status of the command's execution.
11841
11759
 
@@ -11903,9 +11821,7 @@ class GlobalInitScriptsAPI:
11903
11821
  def create(
11904
11822
  self, name: str, script: str, *, enabled: Optional[bool] = None, position: Optional[int] = None
11905
11823
  ) -> CreateResponse:
11906
- """Create init script.
11907
-
11908
- Creates a new global init script in this workspace.
11824
+ """Creates a new global init script in this workspace.
11909
11825
 
11910
11826
  :param name: str
11911
11827
  The name of the script
@@ -11944,9 +11860,7 @@ class GlobalInitScriptsAPI:
11944
11860
  return CreateResponse.from_dict(res)
11945
11861
 
11946
11862
  def delete(self, script_id: str):
11947
- """Delete init script.
11948
-
11949
- Deletes a global init script.
11863
+ """Deletes a global init script.
11950
11864
 
11951
11865
  :param script_id: str
11952
11866
  The ID of the global init script.
@@ -11961,9 +11875,7 @@ class GlobalInitScriptsAPI:
11961
11875
  self._api.do("DELETE", f"/api/2.0/global-init-scripts/{script_id}", headers=headers)
11962
11876
 
11963
11877
  def get(self, script_id: str) -> GlobalInitScriptDetailsWithContent:
11964
- """Get an init script.
11965
-
11966
- Gets all the details of a script, including its Base64-encoded contents.
11878
+ """Gets all the details of a script, including its Base64-encoded contents.
11967
11879
 
11968
11880
  :param script_id: str
11969
11881
  The ID of the global init script.
@@ -11979,9 +11891,7 @@ class GlobalInitScriptsAPI:
11979
11891
  return GlobalInitScriptDetailsWithContent.from_dict(res)
11980
11892
 
11981
11893
  def list(self) -> Iterator[GlobalInitScriptDetails]:
11982
- """Get init scripts.
11983
-
11984
- Get a list of all global init scripts for this workspace. This returns all properties for each script
11894
+ """Get a list of all global init scripts for this workspace. This returns all properties for each script
11985
11895
  but **not** the script contents. To retrieve the contents of a script, use the [get a global init
11986
11896
  script](:method:globalinitscripts/get) operation.
11987
11897
 
@@ -11999,9 +11909,7 @@ class GlobalInitScriptsAPI:
11999
11909
  def update(
12000
11910
  self, script_id: str, name: str, script: str, *, enabled: Optional[bool] = None, position: Optional[int] = None
12001
11911
  ):
12002
- """Update init script.
12003
-
12004
- Updates a global init script, specifying only the fields to change. All fields are optional.
11912
+ """Updates a global init script, specifying only the fields to change. All fields are optional.
12005
11913
  Unspecified fields retain their current value.
12006
11914
 
12007
11915
  :param script_id: str
@@ -12078,9 +11986,7 @@ class InstancePoolsAPI:
12078
11986
  preloaded_docker_images: Optional[List[DockerImage]] = None,
12079
11987
  preloaded_spark_versions: Optional[List[str]] = None,
12080
11988
  ) -> CreateInstancePoolResponse:
12081
- """Create a new instance pool.
12082
-
12083
- Creates a new instance pool using idle and ready-to-use cloud instances.
11989
+ """Creates a new instance pool using idle and ready-to-use cloud instances.
12084
11990
 
12085
11991
  :param instance_pool_name: str
12086
11992
  Pool name requested by the user. Pool name must be unique. Length must be between 1 and 100
@@ -12167,9 +12073,7 @@ class InstancePoolsAPI:
12167
12073
  return CreateInstancePoolResponse.from_dict(res)
12168
12074
 
12169
12075
  def delete(self, instance_pool_id: str):
12170
- """Delete an instance pool.
12171
-
12172
- Deletes the instance pool permanently. The idle instances in the pool are terminated asynchronously.
12076
+ """Deletes the instance pool permanently. The idle instances in the pool are terminated asynchronously.
12173
12077
 
12174
12078
  :param instance_pool_id: str
12175
12079
  The instance pool to be terminated.
@@ -12197,9 +12101,7 @@ class InstancePoolsAPI:
12197
12101
  max_capacity: Optional[int] = None,
12198
12102
  min_idle_instances: Optional[int] = None,
12199
12103
  ):
12200
- """Edit an existing instance pool.
12201
-
12202
- Modifies the configuration of an existing instance pool.
12104
+ """Modifies the configuration of an existing instance pool.
12203
12105
 
12204
12106
  :param instance_pool_id: str
12205
12107
  Instance pool ID
@@ -12254,9 +12156,7 @@ class InstancePoolsAPI:
12254
12156
  self._api.do("POST", "/api/2.0/instance-pools/edit", body=body, headers=headers)
12255
12157
 
12256
12158
  def get(self, instance_pool_id: str) -> GetInstancePool:
12257
- """Get instance pool information.
12258
-
12259
- Retrieve the information for an instance pool based on its identifier.
12159
+ """Retrieve the information for an instance pool based on its identifier.
12260
12160
 
12261
12161
  :param instance_pool_id: str
12262
12162
  The canonical unique identifier for the instance pool.
@@ -12275,9 +12175,7 @@ class InstancePoolsAPI:
12275
12175
  return GetInstancePool.from_dict(res)
12276
12176
 
12277
12177
  def get_permission_levels(self, instance_pool_id: str) -> GetInstancePoolPermissionLevelsResponse:
12278
- """Get instance pool permission levels.
12279
-
12280
- Gets the permission levels that a user can have on an object.
12178
+ """Gets the permission levels that a user can have on an object.
12281
12179
 
12282
12180
  :param instance_pool_id: str
12283
12181
  The instance pool for which to get or manage permissions.
@@ -12295,9 +12193,7 @@ class InstancePoolsAPI:
12295
12193
  return GetInstancePoolPermissionLevelsResponse.from_dict(res)
12296
12194
 
12297
12195
  def get_permissions(self, instance_pool_id: str) -> InstancePoolPermissions:
12298
- """Get instance pool permissions.
12299
-
12300
- Gets the permissions of an instance pool. Instance pools can inherit permissions from their root
12196
+ """Gets the permissions of an instance pool. Instance pools can inherit permissions from their root
12301
12197
  object.
12302
12198
 
12303
12199
  :param instance_pool_id: str
@@ -12314,9 +12210,7 @@ class InstancePoolsAPI:
12314
12210
  return InstancePoolPermissions.from_dict(res)
12315
12211
 
12316
12212
  def list(self) -> Iterator[InstancePoolAndStats]:
12317
- """List instance pool info.
12318
-
12319
- Gets a list of instance pools with their statistics.
12213
+ """Gets a list of instance pools with their statistics.
12320
12214
 
12321
12215
  :returns: Iterator over :class:`InstancePoolAndStats`
12322
12216
  """
@@ -12332,9 +12226,7 @@ class InstancePoolsAPI:
12332
12226
  def set_permissions(
12333
12227
  self, instance_pool_id: str, *, access_control_list: Optional[List[InstancePoolAccessControlRequest]] = None
12334
12228
  ) -> InstancePoolPermissions:
12335
- """Set instance pool permissions.
12336
-
12337
- Sets permissions on an object, replacing existing permissions if they exist. Deletes all direct
12229
+ """Sets permissions on an object, replacing existing permissions if they exist. Deletes all direct
12338
12230
  permissions if none are specified. Objects can inherit permissions from their root object.
12339
12231
 
12340
12232
  :param instance_pool_id: str
@@ -12357,9 +12249,7 @@ class InstancePoolsAPI:
12357
12249
  def update_permissions(
12358
12250
  self, instance_pool_id: str, *, access_control_list: Optional[List[InstancePoolAccessControlRequest]] = None
12359
12251
  ) -> InstancePoolPermissions:
12360
- """Update instance pool permissions.
12361
-
12362
- Updates the permissions on an instance pool. Instance pools can inherit permissions from their root
12252
+ """Updates the permissions on an instance pool. Instance pools can inherit permissions from their root
12363
12253
  object.
12364
12254
 
12365
12255
  :param instance_pool_id: str
@@ -12401,9 +12291,7 @@ class InstanceProfilesAPI:
12401
12291
  is_meta_instance_profile: Optional[bool] = None,
12402
12292
  skip_validation: Optional[bool] = None,
12403
12293
  ):
12404
- """Register an instance profile.
12405
-
12406
- Registers an instance profile in Databricks. In the UI, you can then give users the permission to use
12294
+ """Registers an instance profile in Databricks. In the UI, you can then give users the permission to use
12407
12295
  this instance profile when launching clusters.
12408
12296
 
12409
12297
  This API is only available to admin users.
@@ -12455,9 +12343,7 @@ class InstanceProfilesAPI:
12455
12343
  iam_role_arn: Optional[str] = None,
12456
12344
  is_meta_instance_profile: Optional[bool] = None,
12457
12345
  ):
12458
- """Edit an instance profile.
12459
-
12460
- The only supported field to change is the optional IAM role ARN associated with the instance profile.
12346
+ """The only supported field to change is the optional IAM role ARN associated with the instance profile.
12461
12347
  It is required to specify the IAM role ARN if both of the following are true:
12462
12348
 
12463
12349
  * Your role name and instance profile name do not match. The name is the part after the last slash in
@@ -12503,9 +12389,7 @@ class InstanceProfilesAPI:
12503
12389
  self._api.do("POST", "/api/2.0/instance-profiles/edit", body=body, headers=headers)
12504
12390
 
12505
12391
  def list(self) -> Iterator[InstanceProfile]:
12506
- """List available instance profiles.
12507
-
12508
- List the instance profiles that the calling user can use to launch a cluster.
12392
+ """List the instance profiles that the calling user can use to launch a cluster.
12509
12393
 
12510
12394
  This API is available to all users.
12511
12395
 
@@ -12521,9 +12405,7 @@ class InstanceProfilesAPI:
12521
12405
  return parsed if parsed is not None else []
12522
12406
 
12523
12407
  def remove(self, instance_profile_arn: str):
12524
- """Remove the instance profile.
12525
-
12526
- Remove the instance profile with the provided ARN. Existing clusters with this instance profile will
12408
+ """Remove the instance profile with the provided ARN. Existing clusters with this instance profile will
12527
12409
  continue to function.
12528
12410
 
12529
12411
  This API is only accessible to admin users.
@@ -12563,9 +12445,7 @@ class LibrariesAPI:
12563
12445
  self._api = api_client
12564
12446
 
12565
12447
  def all_cluster_statuses(self) -> Iterator[ClusterLibraryStatuses]:
12566
- """Get all statuses.
12567
-
12568
- Get the status of all libraries on all clusters. A status is returned for all libraries installed on
12448
+ """Get the status of all libraries on all clusters. A status is returned for all libraries installed on
12569
12449
  this cluster via the API or the libraries UI.
12570
12450
 
12571
12451
  :returns: Iterator over :class:`ClusterLibraryStatuses`
@@ -12580,9 +12460,7 @@ class LibrariesAPI:
12580
12460
  return parsed if parsed is not None else []
12581
12461
 
12582
12462
  def cluster_status(self, cluster_id: str) -> Iterator[LibraryFullStatus]:
12583
- """Get status.
12584
-
12585
- Get the status of libraries on a cluster. A status is returned for all libraries installed on this
12463
+ """Get the status of libraries on a cluster. A status is returned for all libraries installed on this
12586
12464
  cluster via the API or the libraries UI. The order of returned libraries is as follows: 1. Libraries
12587
12465
  set to be installed on this cluster, in the order that the libraries were added to the cluster, are
12588
12466
  returned first. 2. Libraries that were previously requested to be installed on this cluster or, but
@@ -12606,9 +12484,7 @@ class LibrariesAPI:
12606
12484
  return parsed if parsed is not None else []
12607
12485
 
12608
12486
  def install(self, cluster_id: str, libraries: List[Library]):
12609
- """Add a library.
12610
-
12611
- Add libraries to install on a cluster. The installation is asynchronous; it happens in the background
12487
+ """Add libraries to install on a cluster. The installation is asynchronous; it happens in the background
12612
12488
  after the completion of this request.
12613
12489
 
12614
12490
  :param cluster_id: str
@@ -12631,9 +12507,7 @@ class LibrariesAPI:
12631
12507
  self._api.do("POST", "/api/2.0/libraries/install", body=body, headers=headers)
12632
12508
 
12633
12509
  def uninstall(self, cluster_id: str, libraries: List[Library]):
12634
- """Uninstall libraries.
12635
-
12636
- Set libraries to uninstall from a cluster. The libraries won't be uninstalled until the cluster is
12510
+ """Set libraries to uninstall from a cluster. The libraries won't be uninstalled until the cluster is
12637
12511
  restarted. A request to uninstall a library that is not currently installed is ignored.
12638
12512
 
12639
12513
  :param cluster_id: str
@@ -12672,9 +12546,7 @@ class PolicyComplianceForClustersAPI:
12672
12546
  def enforce_compliance(
12673
12547
  self, cluster_id: str, *, validate_only: Optional[bool] = None
12674
12548
  ) -> EnforceClusterComplianceResponse:
12675
- """Enforce cluster policy compliance.
12676
-
12677
- Updates a cluster to be compliant with the current version of its policy. A cluster can be updated if
12549
+ """Updates a cluster to be compliant with the current version of its policy. A cluster can be updated if
12678
12550
  it is in a `RUNNING` or `TERMINATED` state.
12679
12551
 
12680
12552
  If a cluster is updated while in a `RUNNING` state, it will be restarted so that the new attributes
@@ -12708,9 +12580,7 @@ class PolicyComplianceForClustersAPI:
12708
12580
  return EnforceClusterComplianceResponse.from_dict(res)
12709
12581
 
12710
12582
  def get_compliance(self, cluster_id: str) -> GetClusterComplianceResponse:
12711
- """Get cluster policy compliance.
12712
-
12713
- Returns the policy compliance status of a cluster. Clusters could be out of compliance if their policy
12583
+ """Returns the policy compliance status of a cluster. Clusters could be out of compliance if their policy
12714
12584
  was updated after the cluster was last edited.
12715
12585
 
12716
12586
  :param cluster_id: str
@@ -12732,9 +12602,7 @@ class PolicyComplianceForClustersAPI:
12732
12602
  def list_compliance(
12733
12603
  self, policy_id: str, *, page_size: Optional[int] = None, page_token: Optional[str] = None
12734
12604
  ) -> Iterator[ClusterCompliance]:
12735
- """List cluster policy compliance.
12736
-
12737
- Returns the policy compliance status of all clusters that use a given policy. Clusters could be out of
12605
+ """Returns the policy compliance status of all clusters that use a given policy. Clusters could be out of
12738
12606
  compliance if their policy was updated after the cluster was last edited.
12739
12607
 
12740
12608
  :param policy_id: str
@@ -12785,9 +12653,7 @@ class PolicyFamiliesAPI:
12785
12653
  self._api = api_client
12786
12654
 
12787
12655
  def get(self, policy_family_id: str, *, version: Optional[int] = None) -> PolicyFamily:
12788
- """Get policy family information.
12789
-
12790
- Retrieve the information for an policy family based on its identifier and version
12656
+ """Retrieve the information for an policy family based on its identifier and version
12791
12657
 
12792
12658
  :param policy_family_id: str
12793
12659
  The family ID about which to retrieve information.
@@ -12808,9 +12674,7 @@ class PolicyFamiliesAPI:
12808
12674
  return PolicyFamily.from_dict(res)
12809
12675
 
12810
12676
  def list(self, *, max_results: Optional[int] = None, page_token: Optional[str] = None) -> Iterator[PolicyFamily]:
12811
- """List policy families.
12812
-
12813
- Returns the list of policy definition types available to use at their latest version. This API is
12677
+ """Returns the list of policy definition types available to use at their latest version. This API is
12814
12678
  paginated.
12815
12679
 
12816
12680
  :param max_results: int (optional)