databricks-sdk 0.57.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 +25 -4
- databricks/sdk/service/aibuilder.py +0 -36
- databricks/sdk/service/apps.py +1 -3
- databricks/sdk/service/billing.py +53 -23
- databricks/sdk/service/catalog.py +1692 -150
- databricks/sdk/service/cleanrooms.py +3 -22
- databricks/sdk/service/compute.py +245 -322
- databricks/sdk/service/dashboards.py +129 -162
- databricks/sdk/service/database.py +612 -97
- databricks/sdk/service/iam.py +3 -3
- databricks/sdk/service/jobs.py +6 -129
- databricks/sdk/service/marketplace.py +3 -2
- databricks/sdk/service/ml.py +713 -262
- databricks/sdk/service/oauth2.py +0 -1
- databricks/sdk/service/pipelines.py +12 -29
- databricks/sdk/service/provisioning.py +7 -125
- databricks/sdk/service/qualitymonitorv2.py +0 -18
- databricks/sdk/service/serving.py +39 -13
- databricks/sdk/service/settings.py +11 -128
- databricks/sdk/service/sharing.py +3 -9
- databricks/sdk/service/sql.py +94 -74
- databricks/sdk/service/vectorsearch.py +0 -19
- databricks/sdk/service/workspace.py +2 -6
- databricks/sdk/version.py +1 -1
- {databricks_sdk-0.57.0.dist-info → databricks_sdk-0.58.0.dist-info}/METADATA +1 -1
- {databricks_sdk-0.57.0.dist-info → databricks_sdk-0.58.0.dist-info}/RECORD +30 -30
- {databricks_sdk-0.57.0.dist-info → databricks_sdk-0.58.0.dist-info}/WHEEL +0 -0
- {databricks_sdk-0.57.0.dist-info → databricks_sdk-0.58.0.dist-info}/licenses/LICENSE +0 -0
- {databricks_sdk-0.57.0.dist-info → databricks_sdk-0.58.0.dist-info}/licenses/NOTICE +0 -0
- {databricks_sdk-0.57.0.dist-info → databricks_sdk-0.58.0.dist-info}/top_level.txt +0 -0
|
@@ -61,7 +61,6 @@ class CreateProvider:
|
|
|
61
61
|
"""The name of the Provider."""
|
|
62
62
|
|
|
63
63
|
authentication_type: AuthenticationType
|
|
64
|
-
"""The delta sharing authentication type."""
|
|
65
64
|
|
|
66
65
|
comment: Optional[str] = None
|
|
67
66
|
"""Description about the provider."""
|
|
@@ -113,7 +112,6 @@ class CreateRecipient:
|
|
|
113
112
|
"""Name of Recipient."""
|
|
114
113
|
|
|
115
114
|
authentication_type: AuthenticationType
|
|
116
|
-
"""The delta sharing authentication type."""
|
|
117
115
|
|
|
118
116
|
comment: Optional[str] = None
|
|
119
117
|
"""Description about the recipient."""
|
|
@@ -265,10 +263,8 @@ class DeltaSharingDependency:
|
|
|
265
263
|
"""Represents a UC dependency."""
|
|
266
264
|
|
|
267
265
|
function: Optional[DeltaSharingFunctionDependency] = None
|
|
268
|
-
"""A Function in UC as a dependency."""
|
|
269
266
|
|
|
270
267
|
table: Optional[DeltaSharingTableDependency] = None
|
|
271
|
-
"""A Table in UC as a dependency."""
|
|
272
268
|
|
|
273
269
|
def as_dict(self) -> dict:
|
|
274
270
|
"""Serializes the DeltaSharingDependency into a dictionary suitable for use as a JSON request body."""
|
|
@@ -1405,7 +1401,8 @@ class Privilege(Enum):
|
|
|
1405
1401
|
@dataclass
|
|
1406
1402
|
class PrivilegeAssignment:
|
|
1407
1403
|
principal: Optional[str] = None
|
|
1408
|
-
"""The principal (user email address or group name).
|
|
1404
|
+
"""The principal (user email address or group name). For deleted principals, `principal` is empty
|
|
1405
|
+
while `principal_id` is populated."""
|
|
1409
1406
|
|
|
1410
1407
|
privileges: Optional[List[Privilege]] = None
|
|
1411
1408
|
"""The privileges assigned to the principal."""
|
|
@@ -1437,7 +1434,6 @@ class PrivilegeAssignment:
|
|
|
1437
1434
|
@dataclass
|
|
1438
1435
|
class ProviderInfo:
|
|
1439
1436
|
authentication_type: Optional[AuthenticationType] = None
|
|
1440
|
-
"""The delta sharing authentication type."""
|
|
1441
1437
|
|
|
1442
1438
|
cloud: Optional[str] = None
|
|
1443
1439
|
"""Cloud vendor of the provider's UC metastore. This field is only present when the
|
|
@@ -1607,7 +1603,6 @@ class RecipientInfo:
|
|
|
1607
1603
|
retrieved."""
|
|
1608
1604
|
|
|
1609
1605
|
authentication_type: Optional[AuthenticationType] = None
|
|
1610
|
-
"""The delta sharing authentication type."""
|
|
1611
1606
|
|
|
1612
1607
|
cloud: Optional[str] = None
|
|
1613
1608
|
"""Cloud vendor of the recipient's Unity Catalog Metastore. This field is only present when the
|
|
@@ -2968,7 +2963,6 @@ class ProvidersAPI:
|
|
|
2968
2963
|
:param name: str
|
|
2969
2964
|
The name of the Provider.
|
|
2970
2965
|
:param authentication_type: :class:`AuthenticationType`
|
|
2971
|
-
The delta sharing authentication type.
|
|
2972
2966
|
:param comment: str (optional)
|
|
2973
2967
|
Description about the provider.
|
|
2974
2968
|
:param recipient_profile_str: str (optional)
|
|
@@ -3308,6 +3302,7 @@ class RecipientFederationPoliciesAPI:
|
|
|
3308
3302
|
:param recipient_name: str
|
|
3309
3303
|
Name of the recipient. This is the name of the recipient for which the policy is being created.
|
|
3310
3304
|
:param policy: :class:`FederationPolicy`
|
|
3305
|
+
Name of the policy. This is the name of the policy to be created.
|
|
3311
3306
|
|
|
3312
3307
|
:returns: :class:`FederationPolicy`
|
|
3313
3308
|
"""
|
|
@@ -3476,7 +3471,6 @@ class RecipientsAPI:
|
|
|
3476
3471
|
:param name: str
|
|
3477
3472
|
Name of Recipient.
|
|
3478
3473
|
:param authentication_type: :class:`AuthenticationType`
|
|
3479
|
-
The delta sharing authentication type.
|
|
3480
3474
|
:param comment: str (optional)
|
|
3481
3475
|
Description about the recipient.
|
|
3482
3476
|
:param data_recipient_global_metastore_id: str (optional)
|
databricks/sdk/service/sql.py
CHANGED
|
@@ -665,7 +665,10 @@ class AlertV2:
|
|
|
665
665
|
"""Text of the query to be run."""
|
|
666
666
|
|
|
667
667
|
run_as_user_name: Optional[str] = None
|
|
668
|
-
"""The run as username. This field is set to "Unavailable"
|
|
668
|
+
"""The run as username or application ID of service principal. This field is set to "Unavailable"
|
|
669
|
+
if the user has been deleted. On Create and Update, this field can be set to application ID of
|
|
670
|
+
an active service principal. Setting this field requires the servicePrincipal/user role. If not
|
|
671
|
+
specified it'll default to be request user."""
|
|
669
672
|
|
|
670
673
|
schedule: Optional[CronSchedule] = None
|
|
671
674
|
|
|
@@ -1700,16 +1703,16 @@ class CreateQueryRequestQuery:
|
|
|
1700
1703
|
class CreateQueryVisualizationsLegacyRequest:
|
|
1701
1704
|
"""Add visualization to a query"""
|
|
1702
1705
|
|
|
1706
|
+
options: Any
|
|
1707
|
+
"""The options object varies widely from one visualization type to the next and is unsupported.
|
|
1708
|
+
Databricks does not recommend modifying visualization settings in JSON."""
|
|
1709
|
+
|
|
1703
1710
|
query_id: str
|
|
1704
1711
|
"""The identifier returned by :method:queries/create"""
|
|
1705
1712
|
|
|
1706
1713
|
type: str
|
|
1707
1714
|
"""The type of visualization: chart, table, pivot table, and so on."""
|
|
1708
1715
|
|
|
1709
|
-
options: Any
|
|
1710
|
-
"""The options object varies widely from one visualization type to the next and is unsupported.
|
|
1711
|
-
Databricks does not recommend modifying visualization settings in JSON."""
|
|
1712
|
-
|
|
1713
1716
|
description: Optional[str] = None
|
|
1714
1717
|
"""A short description of this visualization. This is not displayed in the UI."""
|
|
1715
1718
|
|
|
@@ -1902,7 +1905,6 @@ class CreateWarehouseRequest:
|
|
|
1902
1905
|
Supported values: - Must be unique within an org. - Must be less than 100 characters."""
|
|
1903
1906
|
|
|
1904
1907
|
spot_instance_policy: Optional[SpotInstancePolicy] = None
|
|
1905
|
-
"""Configurations whether the warehouse should use spot instances."""
|
|
1906
1908
|
|
|
1907
1909
|
tags: Optional[EndpointTags] = None
|
|
1908
1910
|
"""A set of key-value pairs that will be tagged on all resources (e.g., AWS instances and EBS
|
|
@@ -1911,8 +1913,6 @@ class CreateWarehouseRequest:
|
|
|
1911
1913
|
Supported values: - Number of tags < 45."""
|
|
1912
1914
|
|
|
1913
1915
|
warehouse_type: Optional[CreateWarehouseRequestWarehouseType] = None
|
|
1914
|
-
"""Warehouse type: `PRO` or `CLASSIC`. If you want to use serverless compute, you must set to `PRO`
|
|
1915
|
-
and also set the field `enable_serverless_compute` to `true`."""
|
|
1916
1916
|
|
|
1917
1917
|
def as_dict(self) -> dict:
|
|
1918
1918
|
"""Serializes the CreateWarehouseRequest into a dictionary suitable for use as a JSON request body."""
|
|
@@ -2040,9 +2040,6 @@ class CreateWidget:
|
|
|
2040
2040
|
width: int
|
|
2041
2041
|
"""Width of a widget"""
|
|
2042
2042
|
|
|
2043
|
-
id: Optional[str] = None
|
|
2044
|
-
"""Widget ID returned by :method:dashboardwidgets/create"""
|
|
2045
|
-
|
|
2046
2043
|
text: Optional[str] = None
|
|
2047
2044
|
"""If this is a textbox widget, the application displays this text. This field is ignored if the
|
|
2048
2045
|
widget contains a visualization in the `visualization` field."""
|
|
@@ -2055,8 +2052,6 @@ class CreateWidget:
|
|
|
2055
2052
|
body = {}
|
|
2056
2053
|
if self.dashboard_id is not None:
|
|
2057
2054
|
body["dashboard_id"] = self.dashboard_id
|
|
2058
|
-
if self.id is not None:
|
|
2059
|
-
body["id"] = self.id
|
|
2060
2055
|
if self.options:
|
|
2061
2056
|
body["options"] = self.options.as_dict()
|
|
2062
2057
|
if self.text is not None:
|
|
@@ -2072,8 +2067,6 @@ class CreateWidget:
|
|
|
2072
2067
|
body = {}
|
|
2073
2068
|
if self.dashboard_id is not None:
|
|
2074
2069
|
body["dashboard_id"] = self.dashboard_id
|
|
2075
|
-
if self.id is not None:
|
|
2076
|
-
body["id"] = self.id
|
|
2077
2070
|
if self.options:
|
|
2078
2071
|
body["options"] = self.options
|
|
2079
2072
|
if self.text is not None:
|
|
@@ -2089,7 +2082,6 @@ class CreateWidget:
|
|
|
2089
2082
|
"""Deserializes the CreateWidget from a dictionary."""
|
|
2090
2083
|
return cls(
|
|
2091
2084
|
dashboard_id=d.get("dashboard_id", None),
|
|
2092
|
-
id=d.get("id", None),
|
|
2093
2085
|
options=_from_dict(d, "options", WidgetOptions),
|
|
2094
2086
|
text=d.get("text", None),
|
|
2095
2087
|
visualization_id=d.get("visualization_id", None),
|
|
@@ -2865,7 +2857,6 @@ class EditWarehouseRequest:
|
|
|
2865
2857
|
Supported values: - Must be unique within an org. - Must be less than 100 characters."""
|
|
2866
2858
|
|
|
2867
2859
|
spot_instance_policy: Optional[SpotInstancePolicy] = None
|
|
2868
|
-
"""Configurations whether the warehouse should use spot instances."""
|
|
2869
2860
|
|
|
2870
2861
|
tags: Optional[EndpointTags] = None
|
|
2871
2862
|
"""A set of key-value pairs that will be tagged on all resources (e.g., AWS instances and EBS
|
|
@@ -2874,8 +2865,6 @@ class EditWarehouseRequest:
|
|
|
2874
2865
|
Supported values: - Number of tags < 45."""
|
|
2875
2866
|
|
|
2876
2867
|
warehouse_type: Optional[EditWarehouseRequestWarehouseType] = None
|
|
2877
|
-
"""Warehouse type: `PRO` or `CLASSIC`. If you want to use serverless compute, you must set to `PRO`
|
|
2878
|
-
and also set the field `enable_serverless_compute` to `true`."""
|
|
2879
2868
|
|
|
2880
2869
|
def as_dict(self) -> dict:
|
|
2881
2870
|
"""Serializes the EditWarehouseRequest into a dictionary suitable for use as a JSON request body."""
|
|
@@ -3055,7 +3044,6 @@ class EndpointHealth:
|
|
|
3055
3044
|
"""Deprecated. split into summary and details for security"""
|
|
3056
3045
|
|
|
3057
3046
|
status: Optional[Status] = None
|
|
3058
|
-
"""Health status of the warehouse."""
|
|
3059
3047
|
|
|
3060
3048
|
summary: Optional[str] = None
|
|
3061
3049
|
"""A short summary of the health status in case of degraded/failed warehouses."""
|
|
@@ -3178,10 +3166,8 @@ class EndpointInfo:
|
|
|
3178
3166
|
"""ODBC parameters for the SQL warehouse"""
|
|
3179
3167
|
|
|
3180
3168
|
spot_instance_policy: Optional[SpotInstancePolicy] = None
|
|
3181
|
-
"""Configurations whether the warehouse should use spot instances."""
|
|
3182
3169
|
|
|
3183
3170
|
state: Optional[State] = None
|
|
3184
|
-
"""State of the warehouse"""
|
|
3185
3171
|
|
|
3186
3172
|
tags: Optional[EndpointTags] = None
|
|
3187
3173
|
"""A set of key-value pairs that will be tagged on all resources (e.g., AWS instances and EBS
|
|
@@ -3419,7 +3405,8 @@ class EnumValue:
|
|
|
3419
3405
|
@dataclass
|
|
3420
3406
|
class ExecuteStatementRequest:
|
|
3421
3407
|
statement: str
|
|
3422
|
-
"""The SQL statement to execute. The statement can optionally be parameterized, see `parameters`.
|
|
3408
|
+
"""The SQL statement to execute. The statement can optionally be parameterized, see `parameters`.
|
|
3409
|
+
The maximum query text size is 16 MiB."""
|
|
3423
3410
|
|
|
3424
3411
|
warehouse_id: str
|
|
3425
3412
|
"""Warehouse upon which to execute a statement. See also [What are SQL warehouses?]
|
|
@@ -3983,10 +3970,8 @@ class GetWarehouseResponse:
|
|
|
3983
3970
|
"""ODBC parameters for the SQL warehouse"""
|
|
3984
3971
|
|
|
3985
3972
|
spot_instance_policy: Optional[SpotInstancePolicy] = None
|
|
3986
|
-
"""Configurations whether the warehouse should use spot instances."""
|
|
3987
3973
|
|
|
3988
3974
|
state: Optional[State] = None
|
|
3989
|
-
"""State of the warehouse"""
|
|
3990
3975
|
|
|
3991
3976
|
tags: Optional[EndpointTags] = None
|
|
3992
3977
|
"""A set of key-value pairs that will be tagged on all resources (e.g., AWS instances and EBS
|
|
@@ -3995,8 +3980,6 @@ class GetWarehouseResponse:
|
|
|
3995
3980
|
Supported values: - Number of tags < 45."""
|
|
3996
3981
|
|
|
3997
3982
|
warehouse_type: Optional[GetWarehouseResponseWarehouseType] = None
|
|
3998
|
-
"""Warehouse type: `PRO` or `CLASSIC`. If you want to use serverless compute, you must set to `PRO`
|
|
3999
|
-
and also set the field `enable_serverless_compute` to `true`."""
|
|
4000
3983
|
|
|
4001
3984
|
def as_dict(self) -> dict:
|
|
4002
3985
|
"""Serializes the GetWarehouseResponse into a dictionary suitable for use as a JSON request body."""
|
|
@@ -4336,8 +4319,6 @@ class LegacyAlert:
|
|
|
4336
4319
|
|
|
4337
4320
|
|
|
4338
4321
|
class LegacyAlertState(Enum):
|
|
4339
|
-
"""State of the alert. Possible values are: `unknown` (yet to be evaluated), `triggered` (evaluated
|
|
4340
|
-
and fulfilled trigger conditions), or `ok` (evaluated and did not fulfill trigger conditions)."""
|
|
4341
4322
|
|
|
4342
4323
|
OK = "ok"
|
|
4343
4324
|
TRIGGERED = "triggered"
|
|
@@ -5317,7 +5298,6 @@ class OdbcParams:
|
|
|
5317
5298
|
|
|
5318
5299
|
|
|
5319
5300
|
class OwnableObjectType(Enum):
|
|
5320
|
-
"""The singular form of the type of object which can be owned."""
|
|
5321
5301
|
|
|
5322
5302
|
ALERT = "alert"
|
|
5323
5303
|
DASHBOARD = "dashboard"
|
|
@@ -5402,7 +5382,6 @@ class Parameter:
|
|
|
5402
5382
|
|
|
5403
5383
|
|
|
5404
5384
|
class ParameterType(Enum):
|
|
5405
|
-
"""Parameters can have several different types."""
|
|
5406
5385
|
|
|
5407
5386
|
DATETIME = "datetime"
|
|
5408
5387
|
ENUM = "enum"
|
|
@@ -6672,7 +6651,6 @@ class ResultManifest:
|
|
|
6672
6651
|
format: Optional[Format] = None
|
|
6673
6652
|
|
|
6674
6653
|
schema: Optional[ResultSchema] = None
|
|
6675
|
-
"""The schema is an ordered list of column descriptions."""
|
|
6676
6654
|
|
|
6677
6655
|
total_byte_count: Optional[int] = None
|
|
6678
6656
|
"""The total number of bytes in the result set. This field is not available when using `INLINE`
|
|
@@ -6778,8 +6756,6 @@ class RunAsMode(Enum):
|
|
|
6778
6756
|
|
|
6779
6757
|
|
|
6780
6758
|
class RunAsRole(Enum):
|
|
6781
|
-
"""Sets the **Run as** role for the object. Must be set to one of `"viewer"` (signifying "run as
|
|
6782
|
-
viewer" behavior) or `"owner"` (signifying "run as owner" behavior)"""
|
|
6783
6759
|
|
|
6784
6760
|
OWNER = "owner"
|
|
6785
6761
|
VIEWER = "viewer"
|
|
@@ -7132,7 +7108,6 @@ class StatementParameterListItem:
|
|
|
7132
7108
|
@dataclass
|
|
7133
7109
|
class StatementResponse:
|
|
7134
7110
|
manifest: Optional[ResultManifest] = None
|
|
7135
|
-
"""The result manifest provides schema and metadata for the result set."""
|
|
7136
7111
|
|
|
7137
7112
|
result: Optional[ResultData] = None
|
|
7138
7113
|
|
|
@@ -7141,7 +7116,6 @@ class StatementResponse:
|
|
|
7141
7116
|
reference for all subsequent calls."""
|
|
7142
7117
|
|
|
7143
7118
|
status: Optional[StatementStatus] = None
|
|
7144
|
-
"""The status response includes execution state and if relevant, error information."""
|
|
7145
7119
|
|
|
7146
7120
|
def as_dict(self) -> dict:
|
|
7147
7121
|
"""Serializes the StatementResponse into a dictionary suitable for use as a JSON request body."""
|
|
@@ -7202,11 +7176,6 @@ class StatementStatus:
|
|
|
7202
7176
|
error: Optional[ServiceError] = None
|
|
7203
7177
|
|
|
7204
7178
|
state: Optional[StatementState] = None
|
|
7205
|
-
"""Statement execution state: - `PENDING`: waiting for warehouse - `RUNNING`: running -
|
|
7206
|
-
`SUCCEEDED`: execution was successful, result data available for fetch - `FAILED`: execution
|
|
7207
|
-
failed; reason for failure described in accomanying error message - `CANCELED`: user canceled;
|
|
7208
|
-
can come from explicit cancel call, or timeout with `on_wait_timeout=CANCEL` - `CLOSED`:
|
|
7209
|
-
execution successful, and statement closed; result no longer available for fetch"""
|
|
7210
7179
|
|
|
7211
7180
|
def as_dict(self) -> dict:
|
|
7212
7181
|
"""Serializes the StatementStatus into a dictionary suitable for use as a JSON request body."""
|
|
@@ -7564,8 +7533,6 @@ class TransferOwnershipObjectId:
|
|
|
7564
7533
|
|
|
7565
7534
|
@dataclass
|
|
7566
7535
|
class TransferOwnershipRequest:
|
|
7567
|
-
"""Transfer object ownership"""
|
|
7568
|
-
|
|
7569
7536
|
new_owner: Optional[str] = None
|
|
7570
7537
|
"""Email address for the new owner, who must exist in the workspace."""
|
|
7571
7538
|
|
|
@@ -8038,6 +8005,73 @@ class UpdateVisualizationRequestVisualization:
|
|
|
8038
8005
|
)
|
|
8039
8006
|
|
|
8040
8007
|
|
|
8008
|
+
@dataclass
|
|
8009
|
+
class UpdateWidgetRequest:
|
|
8010
|
+
dashboard_id: str
|
|
8011
|
+
"""Dashboard ID returned by :method:dashboards/create."""
|
|
8012
|
+
|
|
8013
|
+
options: WidgetOptions
|
|
8014
|
+
|
|
8015
|
+
width: int
|
|
8016
|
+
"""Width of a widget"""
|
|
8017
|
+
|
|
8018
|
+
id: Optional[str] = None
|
|
8019
|
+
"""Widget ID returned by :method:dashboardwidgets/create"""
|
|
8020
|
+
|
|
8021
|
+
text: Optional[str] = None
|
|
8022
|
+
"""If this is a textbox widget, the application displays this text. This field is ignored if the
|
|
8023
|
+
widget contains a visualization in the `visualization` field."""
|
|
8024
|
+
|
|
8025
|
+
visualization_id: Optional[str] = None
|
|
8026
|
+
"""Query Vizualization ID returned by :method:queryvisualizations/create."""
|
|
8027
|
+
|
|
8028
|
+
def as_dict(self) -> dict:
|
|
8029
|
+
"""Serializes the UpdateWidgetRequest into a dictionary suitable for use as a JSON request body."""
|
|
8030
|
+
body = {}
|
|
8031
|
+
if self.dashboard_id is not None:
|
|
8032
|
+
body["dashboard_id"] = self.dashboard_id
|
|
8033
|
+
if self.id is not None:
|
|
8034
|
+
body["id"] = self.id
|
|
8035
|
+
if self.options:
|
|
8036
|
+
body["options"] = self.options.as_dict()
|
|
8037
|
+
if self.text is not None:
|
|
8038
|
+
body["text"] = self.text
|
|
8039
|
+
if self.visualization_id is not None:
|
|
8040
|
+
body["visualization_id"] = self.visualization_id
|
|
8041
|
+
if self.width is not None:
|
|
8042
|
+
body["width"] = self.width
|
|
8043
|
+
return body
|
|
8044
|
+
|
|
8045
|
+
def as_shallow_dict(self) -> dict:
|
|
8046
|
+
"""Serializes the UpdateWidgetRequest into a shallow dictionary of its immediate attributes."""
|
|
8047
|
+
body = {}
|
|
8048
|
+
if self.dashboard_id is not None:
|
|
8049
|
+
body["dashboard_id"] = self.dashboard_id
|
|
8050
|
+
if self.id is not None:
|
|
8051
|
+
body["id"] = self.id
|
|
8052
|
+
if self.options:
|
|
8053
|
+
body["options"] = self.options
|
|
8054
|
+
if self.text is not None:
|
|
8055
|
+
body["text"] = self.text
|
|
8056
|
+
if self.visualization_id is not None:
|
|
8057
|
+
body["visualization_id"] = self.visualization_id
|
|
8058
|
+
if self.width is not None:
|
|
8059
|
+
body["width"] = self.width
|
|
8060
|
+
return body
|
|
8061
|
+
|
|
8062
|
+
@classmethod
|
|
8063
|
+
def from_dict(cls, d: Dict[str, Any]) -> UpdateWidgetRequest:
|
|
8064
|
+
"""Deserializes the UpdateWidgetRequest from a dictionary."""
|
|
8065
|
+
return cls(
|
|
8066
|
+
dashboard_id=d.get("dashboard_id", None),
|
|
8067
|
+
id=d.get("id", None),
|
|
8068
|
+
options=_from_dict(d, "options", WidgetOptions),
|
|
8069
|
+
text=d.get("text", None),
|
|
8070
|
+
visualization_id=d.get("visualization_id", None),
|
|
8071
|
+
width=d.get("width", None),
|
|
8072
|
+
)
|
|
8073
|
+
|
|
8074
|
+
|
|
8041
8075
|
@dataclass
|
|
8042
8076
|
class User:
|
|
8043
8077
|
email: Optional[str] = None
|
|
@@ -8165,7 +8199,6 @@ class WarehouseAccessControlRequest:
|
|
|
8165
8199
|
"""name of the group"""
|
|
8166
8200
|
|
|
8167
8201
|
permission_level: Optional[WarehousePermissionLevel] = None
|
|
8168
|
-
"""Permission level"""
|
|
8169
8202
|
|
|
8170
8203
|
service_principal_name: Optional[str] = None
|
|
8171
8204
|
"""application ID of a service principal"""
|
|
@@ -8276,7 +8309,6 @@ class WarehousePermission:
|
|
|
8276
8309
|
inherited_from_object: Optional[List[str]] = None
|
|
8277
8310
|
|
|
8278
8311
|
permission_level: Optional[WarehousePermissionLevel] = None
|
|
8279
|
-
"""Permission level"""
|
|
8280
8312
|
|
|
8281
8313
|
def as_dict(self) -> dict:
|
|
8282
8314
|
"""Serializes the WarehousePermission into a dictionary suitable for use as a JSON request body."""
|
|
@@ -8365,7 +8397,6 @@ class WarehousePermissionsDescription:
|
|
|
8365
8397
|
description: Optional[str] = None
|
|
8366
8398
|
|
|
8367
8399
|
permission_level: Optional[WarehousePermissionLevel] = None
|
|
8368
|
-
"""Permission level"""
|
|
8369
8400
|
|
|
8370
8401
|
def as_dict(self) -> dict:
|
|
8371
8402
|
"""Serializes the WarehousePermissionsDescription into a dictionary suitable for use as a JSON request body."""
|
|
@@ -8914,6 +8945,7 @@ class AlertsLegacyAPI:
|
|
|
8914
8945
|
|
|
8915
8946
|
[Learn more]: https://docs.databricks.com/en/sql/dbsql-api-latest.html
|
|
8916
8947
|
|
|
8948
|
+
|
|
8917
8949
|
:returns: Iterator over :class:`LegacyAlert`
|
|
8918
8950
|
"""
|
|
8919
8951
|
|
|
@@ -9090,7 +9122,7 @@ class DashboardWidgetsAPI:
|
|
|
9090
9122
|
text: Optional[str] = None,
|
|
9091
9123
|
visualization_id: Optional[str] = None,
|
|
9092
9124
|
) -> Widget:
|
|
9093
|
-
"""
|
|
9125
|
+
"""Adds a widget to a dashboard
|
|
9094
9126
|
|
|
9095
9127
|
:param dashboard_id: str
|
|
9096
9128
|
Dashboard ID returned by :method:dashboards/create.
|
|
@@ -9125,7 +9157,7 @@ class DashboardWidgetsAPI:
|
|
|
9125
9157
|
return Widget.from_dict(res)
|
|
9126
9158
|
|
|
9127
9159
|
def delete(self, id: str):
|
|
9128
|
-
"""
|
|
9160
|
+
"""Removes a widget from a dashboard
|
|
9129
9161
|
|
|
9130
9162
|
:param id: str
|
|
9131
9163
|
Widget ID returned by :method:dashboardwidgets/create
|
|
@@ -9149,7 +9181,7 @@ class DashboardWidgetsAPI:
|
|
|
9149
9181
|
text: Optional[str] = None,
|
|
9150
9182
|
visualization_id: Optional[str] = None,
|
|
9151
9183
|
) -> Widget:
|
|
9152
|
-
"""
|
|
9184
|
+
"""Updates an existing widget
|
|
9153
9185
|
|
|
9154
9186
|
:param id: str
|
|
9155
9187
|
Widget ID returned by :method:dashboardwidgets/create
|
|
@@ -9206,7 +9238,9 @@ class DashboardsAPI:
|
|
|
9206
9238
|
run_as_role: Optional[RunAsRole] = None,
|
|
9207
9239
|
tags: Optional[List[str]] = None,
|
|
9208
9240
|
) -> Dashboard:
|
|
9209
|
-
"""
|
|
9241
|
+
"""Creates a new dashboard object. Only the name parameter is required in the POST request JSON body.
|
|
9242
|
+
Other fields can be included when duplicating dashboards with this API. Databricks does not recommend
|
|
9243
|
+
designing dashboards exclusively using this API.',
|
|
9210
9244
|
|
|
9211
9245
|
:param name: str
|
|
9212
9246
|
The title of this dashboard that appears in list views and at the top of the dashboard page.
|
|
@@ -9312,17 +9346,11 @@ class DashboardsAPI:
|
|
|
9312
9346
|
"Accept": "application/json",
|
|
9313
9347
|
}
|
|
9314
9348
|
|
|
9315
|
-
# deduplicate items that may have been added during iteration
|
|
9316
|
-
seen = set()
|
|
9317
9349
|
query["page"] = 1
|
|
9318
9350
|
while True:
|
|
9319
9351
|
json = self._api.do("GET", "/api/2.0/preview/sql/dashboards", query=query, headers=headers)
|
|
9320
9352
|
if "results" in json:
|
|
9321
9353
|
for v in json["results"]:
|
|
9322
|
-
i = v["id"]
|
|
9323
|
-
if i in seen:
|
|
9324
|
-
continue
|
|
9325
|
-
seen.add(i)
|
|
9326
9354
|
yield Dashboard.from_dict(v)
|
|
9327
9355
|
if "results" not in json or not json["results"]:
|
|
9328
9356
|
return
|
|
@@ -9407,6 +9435,7 @@ class DataSourcesAPI:
|
|
|
9407
9435
|
|
|
9408
9436
|
[Learn more]: https://docs.databricks.com/en/sql/dbsql-api-latest.html
|
|
9409
9437
|
|
|
9438
|
+
|
|
9410
9439
|
:returns: Iterator over :class:`DataSource`
|
|
9411
9440
|
"""
|
|
9412
9441
|
|
|
@@ -9885,17 +9914,11 @@ class QueriesLegacyAPI:
|
|
|
9885
9914
|
"Accept": "application/json",
|
|
9886
9915
|
}
|
|
9887
9916
|
|
|
9888
|
-
# deduplicate items that may have been added during iteration
|
|
9889
|
-
seen = set()
|
|
9890
9917
|
query["page"] = 1
|
|
9891
9918
|
while True:
|
|
9892
9919
|
json = self._api.do("GET", "/api/2.0/preview/sql/queries", query=query, headers=headers)
|
|
9893
9920
|
if "results" in json:
|
|
9894
9921
|
for v in json["results"]:
|
|
9895
|
-
i = v["id"]
|
|
9896
|
-
if i in seen:
|
|
9897
|
-
continue
|
|
9898
|
-
seen.add(i)
|
|
9899
9922
|
yield LegacyQuery.from_dict(v)
|
|
9900
9923
|
if "results" not in json or not json["results"]:
|
|
9901
9924
|
return
|
|
@@ -10130,7 +10153,7 @@ class QueryVisualizationsLegacyAPI:
|
|
|
10130
10153
|
self._api = api_client
|
|
10131
10154
|
|
|
10132
10155
|
def create(
|
|
10133
|
-
self,
|
|
10156
|
+
self, options: Any, query_id: str, type: str, *, description: Optional[str] = None, name: Optional[str] = None
|
|
10134
10157
|
) -> LegacyVisualization:
|
|
10135
10158
|
"""Creates visualization in the query.
|
|
10136
10159
|
|
|
@@ -10139,13 +10162,13 @@ class QueryVisualizationsLegacyAPI:
|
|
|
10139
10162
|
|
|
10140
10163
|
[Learn more]: https://docs.databricks.com/en/sql/dbsql-api-latest.html
|
|
10141
10164
|
|
|
10165
|
+
:param options: Any
|
|
10166
|
+
The options object varies widely from one visualization type to the next and is unsupported.
|
|
10167
|
+
Databricks does not recommend modifying visualization settings in JSON.
|
|
10142
10168
|
:param query_id: str
|
|
10143
10169
|
The identifier returned by :method:queries/create
|
|
10144
10170
|
:param type: str
|
|
10145
10171
|
The type of visualization: chart, table, pivot table, and so on.
|
|
10146
|
-
:param options: Any
|
|
10147
|
-
The options object varies widely from one visualization type to the next and is unsupported.
|
|
10148
|
-
Databricks does not recommend modifying visualization settings in JSON.
|
|
10149
10172
|
:param description: str (optional)
|
|
10150
10173
|
A short description of this visualization. This is not displayed in the UI.
|
|
10151
10174
|
:param name: str (optional)
|
|
@@ -10181,7 +10204,7 @@ class QueryVisualizationsLegacyAPI:
|
|
|
10181
10204
|
[Learn more]: https://docs.databricks.com/en/sql/dbsql-api-latest.html
|
|
10182
10205
|
|
|
10183
10206
|
:param id: str
|
|
10184
|
-
Widget ID returned by :method:
|
|
10207
|
+
Widget ID returned by :method:queryvisualizations/create
|
|
10185
10208
|
|
|
10186
10209
|
|
|
10187
10210
|
"""
|
|
@@ -10261,6 +10284,7 @@ class RedashConfigAPI:
|
|
|
10261
10284
|
def get_config(self) -> ClientConfig:
|
|
10262
10285
|
"""Read workspace configuration for Redash-v2.
|
|
10263
10286
|
|
|
10287
|
+
|
|
10264
10288
|
:returns: :class:`ClientConfig`
|
|
10265
10289
|
"""
|
|
10266
10290
|
|
|
@@ -10394,7 +10418,8 @@ class StatementExecutionAPI:
|
|
|
10394
10418
|
"""Execute a SQL statement
|
|
10395
10419
|
|
|
10396
10420
|
:param statement: str
|
|
10397
|
-
The SQL statement to execute. The statement can optionally be parameterized, see `parameters`.
|
|
10421
|
+
The SQL statement to execute. The statement can optionally be parameterized, see `parameters`. The
|
|
10422
|
+
maximum query text size is 16 MiB.
|
|
10398
10423
|
:param warehouse_id: str
|
|
10399
10424
|
Warehouse upon which to execute a statement. See also [What are SQL warehouses?]
|
|
10400
10425
|
|
|
@@ -10712,15 +10737,12 @@ class WarehousesAPI:
|
|
|
10712
10737
|
|
|
10713
10738
|
Supported values: - Must be unique within an org. - Must be less than 100 characters.
|
|
10714
10739
|
:param spot_instance_policy: :class:`SpotInstancePolicy` (optional)
|
|
10715
|
-
Configurations whether the warehouse should use spot instances.
|
|
10716
10740
|
:param tags: :class:`EndpointTags` (optional)
|
|
10717
10741
|
A set of key-value pairs that will be tagged on all resources (e.g., AWS instances and EBS volumes)
|
|
10718
10742
|
associated with this SQL warehouse.
|
|
10719
10743
|
|
|
10720
10744
|
Supported values: - Number of tags < 45.
|
|
10721
10745
|
:param warehouse_type: :class:`CreateWarehouseRequestWarehouseType` (optional)
|
|
10722
|
-
Warehouse type: `PRO` or `CLASSIC`. If you want to use serverless compute, you must set to `PRO` and
|
|
10723
|
-
also set the field `enable_serverless_compute` to `true`.
|
|
10724
10746
|
|
|
10725
10747
|
:returns:
|
|
10726
10748
|
Long-running operation waiter for :class:`GetWarehouseResponse`.
|
|
@@ -10881,15 +10903,12 @@ class WarehousesAPI:
|
|
|
10881
10903
|
|
|
10882
10904
|
Supported values: - Must be unique within an org. - Must be less than 100 characters.
|
|
10883
10905
|
:param spot_instance_policy: :class:`SpotInstancePolicy` (optional)
|
|
10884
|
-
Configurations whether the warehouse should use spot instances.
|
|
10885
10906
|
:param tags: :class:`EndpointTags` (optional)
|
|
10886
10907
|
A set of key-value pairs that will be tagged on all resources (e.g., AWS instances and EBS volumes)
|
|
10887
10908
|
associated with this SQL warehouse.
|
|
10888
10909
|
|
|
10889
10910
|
Supported values: - Number of tags < 45.
|
|
10890
10911
|
:param warehouse_type: :class:`EditWarehouseRequestWarehouseType` (optional)
|
|
10891
|
-
Warehouse type: `PRO` or `CLASSIC`. If you want to use serverless compute, you must set to `PRO` and
|
|
10892
|
-
also set the field `enable_serverless_compute` to `true`.
|
|
10893
10912
|
|
|
10894
10913
|
:returns:
|
|
10895
10914
|
Long-running operation waiter for :class:`GetWarehouseResponse`.
|
|
@@ -11018,6 +11037,7 @@ class WarehousesAPI:
|
|
|
11018
11037
|
def get_workspace_warehouse_config(self) -> GetWorkspaceWarehouseConfigResponse:
|
|
11019
11038
|
"""Gets the workspace level configuration that is shared by all SQL warehouses in a workspace.
|
|
11020
11039
|
|
|
11040
|
+
|
|
11021
11041
|
:returns: :class:`GetWorkspaceWarehouseConfigResponse`
|
|
11022
11042
|
"""
|
|
11023
11043
|
|
|
@@ -99,11 +99,6 @@ class CreateVectorIndexRequest:
|
|
|
99
99
|
"""Primary key of the index"""
|
|
100
100
|
|
|
101
101
|
index_type: VectorIndexType
|
|
102
|
-
"""There are 2 types of Vector Search indexes: - `DELTA_SYNC`: An index that automatically syncs
|
|
103
|
-
with a source Delta Table, automatically and incrementally updating the index as the underlying
|
|
104
|
-
data in the Delta Table changes. - `DIRECT_ACCESS`: An index that supports direct read and write
|
|
105
|
-
of vectors and metadata through our REST and SDK APIs. With this model, the user manages index
|
|
106
|
-
updates."""
|
|
107
102
|
|
|
108
103
|
delta_sync_index_spec: Optional[DeltaSyncVectorIndexSpecRequest] = None
|
|
109
104
|
"""Specification for Delta Sync Index. Required if `index_type` is `DELTA_SYNC`."""
|
|
@@ -845,11 +840,6 @@ class MiniVectorIndex:
|
|
|
845
840
|
"""Name of the endpoint associated with the index"""
|
|
846
841
|
|
|
847
842
|
index_type: Optional[VectorIndexType] = None
|
|
848
|
-
"""There are 2 types of Vector Search indexes: - `DELTA_SYNC`: An index that automatically syncs
|
|
849
|
-
with a source Delta Table, automatically and incrementally updating the index as the underlying
|
|
850
|
-
data in the Delta Table changes. - `DIRECT_ACCESS`: An index that supports direct read and write
|
|
851
|
-
of vectors and metadata through our REST and SDK APIs. With this model, the user manages index
|
|
852
|
-
updates."""
|
|
853
843
|
|
|
854
844
|
name: Optional[str] = None
|
|
855
845
|
"""Name of the index"""
|
|
@@ -1579,11 +1569,6 @@ class VectorIndex:
|
|
|
1579
1569
|
"""Name of the endpoint associated with the index"""
|
|
1580
1570
|
|
|
1581
1571
|
index_type: Optional[VectorIndexType] = None
|
|
1582
|
-
"""There are 2 types of Vector Search indexes: - `DELTA_SYNC`: An index that automatically syncs
|
|
1583
|
-
with a source Delta Table, automatically and incrementally updating the index as the underlying
|
|
1584
|
-
data in the Delta Table changes. - `DIRECT_ACCESS`: An index that supports direct read and write
|
|
1585
|
-
of vectors and metadata through our REST and SDK APIs. With this model, the user manages index
|
|
1586
|
-
updates."""
|
|
1587
1572
|
|
|
1588
1573
|
name: Optional[str] = None
|
|
1589
1574
|
"""Name of the index"""
|
|
@@ -1937,10 +1922,6 @@ class VectorSearchIndexesAPI:
|
|
|
1937
1922
|
:param primary_key: str
|
|
1938
1923
|
Primary key of the index
|
|
1939
1924
|
:param index_type: :class:`VectorIndexType`
|
|
1940
|
-
There are 2 types of Vector Search indexes: - `DELTA_SYNC`: An index that automatically syncs with a
|
|
1941
|
-
source Delta Table, automatically and incrementally updating the index as the underlying data in the
|
|
1942
|
-
Delta Table changes. - `DIRECT_ACCESS`: An index that supports direct read and write of vectors and
|
|
1943
|
-
metadata through our REST and SDK APIs. With this model, the user manages index updates.
|
|
1944
1925
|
:param delta_sync_index_spec: :class:`DeltaSyncVectorIndexSpecRequest` (optional)
|
|
1945
1926
|
Specification for Delta Sync Index. Required if `index_type` is `DELTA_SYNC`.
|
|
1946
1927
|
:param direct_access_index_spec: :class:`DirectAccessVectorIndexSpec` (optional)
|
|
@@ -1456,7 +1456,6 @@ class RepoAccessControlRequest:
|
|
|
1456
1456
|
"""name of the group"""
|
|
1457
1457
|
|
|
1458
1458
|
permission_level: Optional[RepoPermissionLevel] = None
|
|
1459
|
-
"""Permission level"""
|
|
1460
1459
|
|
|
1461
1460
|
service_principal_name: Optional[str] = None
|
|
1462
1461
|
"""application ID of a service principal"""
|
|
@@ -1644,7 +1643,6 @@ class RepoPermission:
|
|
|
1644
1643
|
inherited_from_object: Optional[List[str]] = None
|
|
1645
1644
|
|
|
1646
1645
|
permission_level: Optional[RepoPermissionLevel] = None
|
|
1647
|
-
"""Permission level"""
|
|
1648
1646
|
|
|
1649
1647
|
def as_dict(self) -> dict:
|
|
1650
1648
|
"""Serializes the RepoPermission into a dictionary suitable for use as a JSON request body."""
|
|
@@ -1732,7 +1730,6 @@ class RepoPermissionsDescription:
|
|
|
1732
1730
|
description: Optional[str] = None
|
|
1733
1731
|
|
|
1734
1732
|
permission_level: Optional[RepoPermissionLevel] = None
|
|
1735
|
-
"""Permission level"""
|
|
1736
1733
|
|
|
1737
1734
|
def as_dict(self) -> dict:
|
|
1738
1735
|
"""Serializes the RepoPermissionsDescription into a dictionary suitable for use as a JSON request body."""
|
|
@@ -2089,7 +2086,6 @@ class WorkspaceObjectAccessControlRequest:
|
|
|
2089
2086
|
"""name of the group"""
|
|
2090
2087
|
|
|
2091
2088
|
permission_level: Optional[WorkspaceObjectPermissionLevel] = None
|
|
2092
|
-
"""Permission level"""
|
|
2093
2089
|
|
|
2094
2090
|
service_principal_name: Optional[str] = None
|
|
2095
2091
|
"""application ID of a service principal"""
|
|
@@ -2200,7 +2196,6 @@ class WorkspaceObjectPermission:
|
|
|
2200
2196
|
inherited_from_object: Optional[List[str]] = None
|
|
2201
2197
|
|
|
2202
2198
|
permission_level: Optional[WorkspaceObjectPermissionLevel] = None
|
|
2203
|
-
"""Permission level"""
|
|
2204
2199
|
|
|
2205
2200
|
def as_dict(self) -> dict:
|
|
2206
2201
|
"""Serializes the WorkspaceObjectPermission into a dictionary suitable for use as a JSON request body."""
|
|
@@ -2288,7 +2283,6 @@ class WorkspaceObjectPermissionsDescription:
|
|
|
2288
2283
|
description: Optional[str] = None
|
|
2289
2284
|
|
|
2290
2285
|
permission_level: Optional[WorkspaceObjectPermissionLevel] = None
|
|
2291
|
-
"""Permission level"""
|
|
2292
2286
|
|
|
2293
2287
|
def as_dict(self) -> dict:
|
|
2294
2288
|
"""Serializes the WorkspaceObjectPermissionsDescription into a dictionary suitable for use as a JSON request body."""
|
|
@@ -2443,6 +2437,7 @@ class GitCredentialsAPI:
|
|
|
2443
2437
|
def list(self) -> Iterator[CredentialInfo]:
|
|
2444
2438
|
"""Lists the calling user's Git credentials. One credential per user is supported.
|
|
2445
2439
|
|
|
2440
|
+
|
|
2446
2441
|
:returns: Iterator over :class:`CredentialInfo`
|
|
2447
2442
|
"""
|
|
2448
2443
|
|
|
@@ -2943,6 +2938,7 @@ class SecretsAPI:
|
|
|
2943
2938
|
|
|
2944
2939
|
Throws `PERMISSION_DENIED` if the user does not have permission to make this API call.
|
|
2945
2940
|
|
|
2941
|
+
|
|
2946
2942
|
:returns: Iterator over :class:`SecretScope`
|
|
2947
2943
|
"""
|
|
2948
2944
|
|