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

@@ -787,9 +787,6 @@ class CatalogInfo:
787
787
  provisioning_info: Optional[ProvisioningInfo] = None
788
788
  """Status of an asynchronously provisioned resource."""
789
789
 
790
- securable_kind: Optional[CatalogInfoSecurableKind] = None
791
- """Kind of catalog securable."""
792
-
793
790
  securable_type: Optional[str] = None
794
791
 
795
792
  share_name: Optional[str] = None
@@ -831,7 +828,6 @@ class CatalogInfo:
831
828
  if self.properties: body['properties'] = self.properties
832
829
  if self.provider_name is not None: body['provider_name'] = self.provider_name
833
830
  if self.provisioning_info: body['provisioning_info'] = self.provisioning_info.as_dict()
834
- if self.securable_kind is not None: body['securable_kind'] = self.securable_kind.value
835
831
  if self.securable_type is not None: body['securable_type'] = self.securable_type
836
832
  if self.share_name is not None: body['share_name'] = self.share_name
837
833
  if self.storage_location is not None: body['storage_location'] = self.storage_location
@@ -862,7 +858,6 @@ class CatalogInfo:
862
858
  if self.properties: body['properties'] = self.properties
863
859
  if self.provider_name is not None: body['provider_name'] = self.provider_name
864
860
  if self.provisioning_info: body['provisioning_info'] = self.provisioning_info
865
- if self.securable_kind is not None: body['securable_kind'] = self.securable_kind
866
861
  if self.securable_type is not None: body['securable_type'] = self.securable_type
867
862
  if self.share_name is not None: body['share_name'] = self.share_name
868
863
  if self.storage_location is not None: body['storage_location'] = self.storage_location
@@ -893,7 +888,6 @@ class CatalogInfo:
893
888
  properties=d.get('properties', None),
894
889
  provider_name=d.get('provider_name', None),
895
890
  provisioning_info=_from_dict(d, 'provisioning_info', ProvisioningInfo),
896
- securable_kind=_enum(d, 'securable_kind', CatalogInfoSecurableKind),
897
891
  securable_type=d.get('securable_type', None),
898
892
  share_name=d.get('share_name', None),
899
893
  storage_location=d.get('storage_location', None),
@@ -902,24 +896,6 @@ class CatalogInfo:
902
896
  updated_by=d.get('updated_by', None))
903
897
 
904
898
 
905
- class CatalogInfoSecurableKind(Enum):
906
- """Kind of catalog securable."""
907
-
908
- CATALOG_DELTASHARING = 'CATALOG_DELTASHARING'
909
- CATALOG_FOREIGN_BIGQUERY = 'CATALOG_FOREIGN_BIGQUERY'
910
- CATALOG_FOREIGN_DATABRICKS = 'CATALOG_FOREIGN_DATABRICKS'
911
- CATALOG_FOREIGN_MYSQL = 'CATALOG_FOREIGN_MYSQL'
912
- CATALOG_FOREIGN_POSTGRESQL = 'CATALOG_FOREIGN_POSTGRESQL'
913
- CATALOG_FOREIGN_REDSHIFT = 'CATALOG_FOREIGN_REDSHIFT'
914
- CATALOG_FOREIGN_SNOWFLAKE = 'CATALOG_FOREIGN_SNOWFLAKE'
915
- CATALOG_FOREIGN_SQLDW = 'CATALOG_FOREIGN_SQLDW'
916
- CATALOG_FOREIGN_SQLSERVER = 'CATALOG_FOREIGN_SQLSERVER'
917
- CATALOG_INTERNAL = 'CATALOG_INTERNAL'
918
- CATALOG_STANDARD = 'CATALOG_STANDARD'
919
- CATALOG_SYSTEM = 'CATALOG_SYSTEM'
920
- CATALOG_SYSTEM_DELTASHARING = 'CATALOG_SYSTEM_DELTASHARING'
921
-
922
-
923
899
  class CatalogIsolationMode(Enum):
924
900
  """Whether the current securable is accessible from all workspaces or a specific set of workspaces."""
925
901
 
@@ -1158,9 +1134,6 @@ class ConnectionInfo:
1158
1134
  read_only: Optional[bool] = None
1159
1135
  """If the connection is read only."""
1160
1136
 
1161
- securable_kind: Optional[ConnectionInfoSecurableKind] = None
1162
- """Kind of connection securable."""
1163
-
1164
1137
  securable_type: Optional[str] = None
1165
1138
 
1166
1139
  updated_at: Optional[int] = None
@@ -1189,7 +1162,6 @@ class ConnectionInfo:
1189
1162
  if self.properties: body['properties'] = self.properties
1190
1163
  if self.provisioning_info: body['provisioning_info'] = self.provisioning_info.as_dict()
1191
1164
  if self.read_only is not None: body['read_only'] = self.read_only
1192
- if self.securable_kind is not None: body['securable_kind'] = self.securable_kind.value
1193
1165
  if self.securable_type is not None: body['securable_type'] = self.securable_type
1194
1166
  if self.updated_at is not None: body['updated_at'] = self.updated_at
1195
1167
  if self.updated_by is not None: body['updated_by'] = self.updated_by
@@ -1213,7 +1185,6 @@ class ConnectionInfo:
1213
1185
  if self.properties: body['properties'] = self.properties
1214
1186
  if self.provisioning_info: body['provisioning_info'] = self.provisioning_info
1215
1187
  if self.read_only is not None: body['read_only'] = self.read_only
1216
- if self.securable_kind is not None: body['securable_kind'] = self.securable_kind
1217
1188
  if self.securable_type is not None: body['securable_type'] = self.securable_type
1218
1189
  if self.updated_at is not None: body['updated_at'] = self.updated_at
1219
1190
  if self.updated_by is not None: body['updated_by'] = self.updated_by
@@ -1237,31 +1208,12 @@ class ConnectionInfo:
1237
1208
  properties=d.get('properties', None),
1238
1209
  provisioning_info=_from_dict(d, 'provisioning_info', ProvisioningInfo),
1239
1210
  read_only=d.get('read_only', None),
1240
- securable_kind=_enum(d, 'securable_kind', ConnectionInfoSecurableKind),
1241
1211
  securable_type=d.get('securable_type', None),
1242
1212
  updated_at=d.get('updated_at', None),
1243
1213
  updated_by=d.get('updated_by', None),
1244
1214
  url=d.get('url', None))
1245
1215
 
1246
1216
 
1247
- class ConnectionInfoSecurableKind(Enum):
1248
- """Kind of connection securable."""
1249
-
1250
- CONNECTION_BIGQUERY = 'CONNECTION_BIGQUERY'
1251
- CONNECTION_BUILTIN_HIVE_METASTORE = 'CONNECTION_BUILTIN_HIVE_METASTORE'
1252
- CONNECTION_DATABRICKS = 'CONNECTION_DATABRICKS'
1253
- CONNECTION_EXTERNAL_HIVE_METASTORE = 'CONNECTION_EXTERNAL_HIVE_METASTORE'
1254
- CONNECTION_GLUE = 'CONNECTION_GLUE'
1255
- CONNECTION_HTTP_BEARER = 'CONNECTION_HTTP_BEARER'
1256
- CONNECTION_MYSQL = 'CONNECTION_MYSQL'
1257
- CONNECTION_ONLINE_CATALOG = 'CONNECTION_ONLINE_CATALOG'
1258
- CONNECTION_POSTGRESQL = 'CONNECTION_POSTGRESQL'
1259
- CONNECTION_REDSHIFT = 'CONNECTION_REDSHIFT'
1260
- CONNECTION_SNOWFLAKE = 'CONNECTION_SNOWFLAKE'
1261
- CONNECTION_SQLDW = 'CONNECTION_SQLDW'
1262
- CONNECTION_SQLSERVER = 'CONNECTION_SQLSERVER'
1263
-
1264
-
1265
1217
  class ConnectionType(Enum):
1266
1218
  """The type of connection."""
1267
1219
 
@@ -6269,20 +6221,21 @@ SecurablePropertiesMap = Dict[str, str]
6269
6221
  class SecurableType(Enum):
6270
6222
  """The type of Unity Catalog securable"""
6271
6223
 
6272
- CATALOG = 'catalog'
6273
- CONNECTION = 'connection'
6274
- CREDENTIAL = 'credential'
6275
- EXTERNAL_LOCATION = 'external_location'
6276
- FUNCTION = 'function'
6277
- METASTORE = 'metastore'
6278
- PIPELINE = 'pipeline'
6279
- PROVIDER = 'provider'
6280
- RECIPIENT = 'recipient'
6281
- SCHEMA = 'schema'
6282
- SHARE = 'share'
6283
- STORAGE_CREDENTIAL = 'storage_credential'
6284
- TABLE = 'table'
6285
- VOLUME = 'volume'
6224
+ CATALOG = 'CATALOG'
6225
+ CLEAN_ROOM = 'CLEAN_ROOM'
6226
+ CONNECTION = 'CONNECTION'
6227
+ CREDENTIAL = 'CREDENTIAL'
6228
+ EXTERNAL_LOCATION = 'EXTERNAL_LOCATION'
6229
+ FUNCTION = 'FUNCTION'
6230
+ METASTORE = 'METASTORE'
6231
+ PIPELINE = 'PIPELINE'
6232
+ PROVIDER = 'PROVIDER'
6233
+ RECIPIENT = 'RECIPIENT'
6234
+ SCHEMA = 'SCHEMA'
6235
+ SHARE = 'SHARE'
6236
+ STORAGE_CREDENTIAL = 'STORAGE_CREDENTIAL'
6237
+ TABLE = 'TABLE'
6238
+ VOLUME = 'VOLUME'
6286
6239
 
6287
6240
 
6288
6241
  @dataclass
@@ -289,11 +289,24 @@ class CleanRoomAssetNotebook:
289
289
  """Base 64 representation of the notebook contents. This is the same format as returned by
290
290
  :method:workspace/export with the format of **HTML**."""
291
291
 
292
+ review_state: Optional[CleanRoomNotebookReviewNotebookReviewState] = None
293
+ """top-level status derived from all reviews"""
294
+
295
+ reviews: Optional[List[CleanRoomNotebookReview]] = None
296
+ """All existing approvals or rejections"""
297
+
298
+ runner_collaborators: Optional[List[CleanRoomCollaborator]] = None
299
+ """collaborators that can run the notebook"""
300
+
292
301
  def as_dict(self) -> dict:
293
302
  """Serializes the CleanRoomAssetNotebook into a dictionary suitable for use as a JSON request body."""
294
303
  body = {}
295
304
  if self.etag is not None: body['etag'] = self.etag
296
305
  if self.notebook_content is not None: body['notebook_content'] = self.notebook_content
306
+ if self.review_state is not None: body['review_state'] = self.review_state.value
307
+ if self.reviews: body['reviews'] = [v.as_dict() for v in self.reviews]
308
+ if self.runner_collaborators:
309
+ body['runner_collaborators'] = [v.as_dict() for v in self.runner_collaborators]
297
310
  return body
298
311
 
299
312
  def as_shallow_dict(self) -> dict:
@@ -301,12 +314,19 @@ class CleanRoomAssetNotebook:
301
314
  body = {}
302
315
  if self.etag is not None: body['etag'] = self.etag
303
316
  if self.notebook_content is not None: body['notebook_content'] = self.notebook_content
317
+ if self.review_state is not None: body['review_state'] = self.review_state
318
+ if self.reviews: body['reviews'] = self.reviews
319
+ if self.runner_collaborators: body['runner_collaborators'] = self.runner_collaborators
304
320
  return body
305
321
 
306
322
  @classmethod
307
323
  def from_dict(cls, d: Dict[str, any]) -> CleanRoomAssetNotebook:
308
324
  """Deserializes the CleanRoomAssetNotebook from a dictionary."""
309
- return cls(etag=d.get('etag', None), notebook_content=d.get('notebook_content', None))
325
+ return cls(etag=d.get('etag', None),
326
+ notebook_content=d.get('notebook_content', None),
327
+ review_state=_enum(d, 'review_state', CleanRoomNotebookReviewNotebookReviewState),
328
+ reviews=_repeated_dict(d, 'reviews', CleanRoomNotebookReview),
329
+ runner_collaborators=_repeated_dict(d, 'runner_collaborators', CleanRoomCollaborator))
310
330
 
311
331
 
312
332
  class CleanRoomAssetStatusEnum(Enum):
@@ -511,6 +531,56 @@ class CleanRoomCollaborator:
511
531
  organization_name=d.get('organization_name', None))
512
532
 
513
533
 
534
+ @dataclass
535
+ class CleanRoomNotebookReview:
536
+ comment: Optional[str] = None
537
+ """review comment"""
538
+
539
+ created_at_millis: Optional[int] = None
540
+ """timestamp of when the review was submitted"""
541
+
542
+ review_state: Optional[CleanRoomNotebookReviewNotebookReviewState] = None
543
+ """review outcome"""
544
+
545
+ reviewer_collaborator_alias: Optional[str] = None
546
+ """collaborator alias of the reviewer"""
547
+
548
+ def as_dict(self) -> dict:
549
+ """Serializes the CleanRoomNotebookReview into a dictionary suitable for use as a JSON request body."""
550
+ body = {}
551
+ if self.comment is not None: body['comment'] = self.comment
552
+ if self.created_at_millis is not None: body['created_at_millis'] = self.created_at_millis
553
+ if self.review_state is not None: body['review_state'] = self.review_state.value
554
+ if self.reviewer_collaborator_alias is not None:
555
+ body['reviewer_collaborator_alias'] = self.reviewer_collaborator_alias
556
+ return body
557
+
558
+ def as_shallow_dict(self) -> dict:
559
+ """Serializes the CleanRoomNotebookReview into a shallow dictionary of its immediate attributes."""
560
+ body = {}
561
+ if self.comment is not None: body['comment'] = self.comment
562
+ if self.created_at_millis is not None: body['created_at_millis'] = self.created_at_millis
563
+ if self.review_state is not None: body['review_state'] = self.review_state
564
+ if self.reviewer_collaborator_alias is not None:
565
+ body['reviewer_collaborator_alias'] = self.reviewer_collaborator_alias
566
+ return body
567
+
568
+ @classmethod
569
+ def from_dict(cls, d: Dict[str, any]) -> CleanRoomNotebookReview:
570
+ """Deserializes the CleanRoomNotebookReview from a dictionary."""
571
+ return cls(comment=d.get('comment', None),
572
+ created_at_millis=d.get('created_at_millis', None),
573
+ review_state=_enum(d, 'review_state', CleanRoomNotebookReviewNotebookReviewState),
574
+ reviewer_collaborator_alias=d.get('reviewer_collaborator_alias', None))
575
+
576
+
577
+ class CleanRoomNotebookReviewNotebookReviewState(Enum):
578
+
579
+ APPROVED = 'APPROVED'
580
+ PENDING = 'PENDING'
581
+ REJECTED = 'REJECTED'
582
+
583
+
514
584
  @dataclass
515
585
  class CleanRoomNotebookTaskRun:
516
586
  """Stores information about a single task run."""
@@ -2937,6 +2937,42 @@ class Created:
2937
2937
  return cls(id=d.get('id', None))
2938
2938
 
2939
2939
 
2940
+ @dataclass
2941
+ class CustomPolicyTag:
2942
+ key: str
2943
+ """The key of the tag. - Must be unique among all custom tags of the same policy - Cannot be
2944
+ “budget-policy-name”, “budget-policy-id” or "budget-policy-resolution-result" - these
2945
+ tags are preserved.
2946
+
2947
+ - Follows the regex pattern defined in cluster-common/conf/src/ClusterTagConstraints.scala
2948
+ (https://src.dev.databricks.com/databricks/universe@1647196627c8dc7b4152ad098a94b86484b93a6c/-/blob/cluster-common/conf/src/ClusterTagConstraints.scala?L17)"""
2949
+
2950
+ value: Optional[str] = None
2951
+ """The value of the tag.
2952
+
2953
+ - Follows the regex pattern defined in cluster-common/conf/src/ClusterTagConstraints.scala
2954
+ (https://src.dev.databricks.com/databricks/universe@1647196627c8dc7b4152ad098a94b86484b93a6c/-/blob/cluster-common/conf/src/ClusterTagConstraints.scala?L24)"""
2955
+
2956
+ def as_dict(self) -> dict:
2957
+ """Serializes the CustomPolicyTag into a dictionary suitable for use as a JSON request body."""
2958
+ body = {}
2959
+ if self.key is not None: body['key'] = self.key
2960
+ if self.value is not None: body['value'] = self.value
2961
+ return body
2962
+
2963
+ def as_shallow_dict(self) -> dict:
2964
+ """Serializes the CustomPolicyTag into a shallow dictionary of its immediate attributes."""
2965
+ body = {}
2966
+ if self.key is not None: body['key'] = self.key
2967
+ if self.value is not None: body['value'] = self.value
2968
+ return body
2969
+
2970
+ @classmethod
2971
+ def from_dict(cls, d: Dict[str, any]) -> CustomPolicyTag:
2972
+ """Deserializes the CustomPolicyTag from a dictionary."""
2973
+ return cls(key=d.get('key', None), value=d.get('value', None))
2974
+
2975
+
2940
2976
  @dataclass
2941
2977
  class DataPlaneEventDetails:
2942
2978
  event_type: Optional[DataPlaneEventDetailsEventType] = None
@@ -846,6 +846,8 @@ class QueryAttachment:
846
846
  query: Optional[str] = None
847
847
  """AI generated SQL query"""
848
848
 
849
+ statement_id: Optional[str] = None
850
+
849
851
  title: Optional[str] = None
850
852
  """Name of the query"""
851
853
 
@@ -860,6 +862,7 @@ class QueryAttachment:
860
862
  if self.last_updated_timestamp is not None:
861
863
  body['last_updated_timestamp'] = self.last_updated_timestamp
862
864
  if self.query is not None: body['query'] = self.query
865
+ if self.statement_id is not None: body['statement_id'] = self.statement_id
863
866
  if self.title is not None: body['title'] = self.title
864
867
  return body
865
868
 
@@ -874,6 +877,7 @@ class QueryAttachment:
874
877
  if self.last_updated_timestamp is not None:
875
878
  body['last_updated_timestamp'] = self.last_updated_timestamp
876
879
  if self.query is not None: body['query'] = self.query
880
+ if self.statement_id is not None: body['statement_id'] = self.statement_id
877
881
  if self.title is not None: body['title'] = self.title
878
882
  return body
879
883
 
@@ -887,6 +891,7 @@ class QueryAttachment:
887
891
  instruction_title=d.get('instruction_title', None),
888
892
  last_updated_timestamp=d.get('last_updated_timestamp', None),
889
893
  query=d.get('query', None),
894
+ statement_id=d.get('statement_id', None),
890
895
  title=d.get('title', None))
891
896
 
892
897