databricks-sdk 0.52.0__py3-none-any.whl → 0.54.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 +31 -3
- databricks/sdk/errors/base.py +1 -30
- databricks/sdk/service/apps.py +58 -0
- databricks/sdk/service/catalog.py +1198 -181
- databricks/sdk/service/cleanrooms.py +116 -1
- databricks/sdk/service/compute.py +33 -68
- databricks/sdk/service/dashboards.py +7 -0
- databricks/sdk/service/iam.py +167 -103
- databricks/sdk/service/jobs.py +7 -6
- databricks/sdk/service/ml.py +1230 -55
- databricks/sdk/service/oauth2.py +17 -0
- databricks/sdk/service/pipelines.py +105 -0
- databricks/sdk/service/serving.py +314 -0
- databricks/sdk/service/settings.py +1284 -59
- databricks/sdk/service/sharing.py +388 -2
- databricks/sdk/service/sql.py +53 -84
- databricks/sdk/service/vectorsearch.py +3 -31
- databricks/sdk/version.py +1 -1
- {databricks_sdk-0.52.0.dist-info → databricks_sdk-0.54.0.dist-info}/METADATA +1 -1
- {databricks_sdk-0.52.0.dist-info → databricks_sdk-0.54.0.dist-info}/RECORD +24 -24
- {databricks_sdk-0.52.0.dist-info → databricks_sdk-0.54.0.dist-info}/WHEEL +1 -1
- {databricks_sdk-0.52.0.dist-info → databricks_sdk-0.54.0.dist-info}/licenses/LICENSE +0 -0
- {databricks_sdk-0.52.0.dist-info → databricks_sdk-0.54.0.dist-info}/licenses/NOTICE +0 -0
- {databricks_sdk-0.52.0.dist-info → databricks_sdk-0.54.0.dist-info}/top_level.txt +0 -0
|
@@ -65,6 +65,49 @@ class AccountIpAccessEnable:
|
|
|
65
65
|
)
|
|
66
66
|
|
|
67
67
|
|
|
68
|
+
@dataclass
|
|
69
|
+
class AccountNetworkPolicy:
|
|
70
|
+
account_id: Optional[str] = None
|
|
71
|
+
"""The associated account ID for this Network Policy object."""
|
|
72
|
+
|
|
73
|
+
egress: Optional[NetworkPolicyEgress] = None
|
|
74
|
+
"""The network policies applying for egress traffic."""
|
|
75
|
+
|
|
76
|
+
network_policy_id: Optional[str] = None
|
|
77
|
+
"""The unique identifier for the network policy."""
|
|
78
|
+
|
|
79
|
+
def as_dict(self) -> dict:
|
|
80
|
+
"""Serializes the AccountNetworkPolicy into a dictionary suitable for use as a JSON request body."""
|
|
81
|
+
body = {}
|
|
82
|
+
if self.account_id is not None:
|
|
83
|
+
body["account_id"] = self.account_id
|
|
84
|
+
if self.egress:
|
|
85
|
+
body["egress"] = self.egress.as_dict()
|
|
86
|
+
if self.network_policy_id is not None:
|
|
87
|
+
body["network_policy_id"] = self.network_policy_id
|
|
88
|
+
return body
|
|
89
|
+
|
|
90
|
+
def as_shallow_dict(self) -> dict:
|
|
91
|
+
"""Serializes the AccountNetworkPolicy into a shallow dictionary of its immediate attributes."""
|
|
92
|
+
body = {}
|
|
93
|
+
if self.account_id is not None:
|
|
94
|
+
body["account_id"] = self.account_id
|
|
95
|
+
if self.egress:
|
|
96
|
+
body["egress"] = self.egress
|
|
97
|
+
if self.network_policy_id is not None:
|
|
98
|
+
body["network_policy_id"] = self.network_policy_id
|
|
99
|
+
return body
|
|
100
|
+
|
|
101
|
+
@classmethod
|
|
102
|
+
def from_dict(cls, d: Dict[str, Any]) -> AccountNetworkPolicy:
|
|
103
|
+
"""Deserializes the AccountNetworkPolicy from a dictionary."""
|
|
104
|
+
return cls(
|
|
105
|
+
account_id=d.get("account_id", None),
|
|
106
|
+
egress=_from_dict(d, "egress", NetworkPolicyEgress),
|
|
107
|
+
network_policy_id=d.get("network_policy_id", None),
|
|
108
|
+
)
|
|
109
|
+
|
|
110
|
+
|
|
68
111
|
@dataclass
|
|
69
112
|
class AibiDashboardEmbeddingAccessPolicy:
|
|
70
113
|
access_policy_type: AibiDashboardEmbeddingAccessPolicyAccessPolicyType
|
|
@@ -1405,6 +1448,38 @@ class DeleteDisableLegacyFeaturesResponse:
|
|
|
1405
1448
|
return cls(etag=d.get("etag", None))
|
|
1406
1449
|
|
|
1407
1450
|
|
|
1451
|
+
@dataclass
|
|
1452
|
+
class DeleteLlmProxyPartnerPoweredWorkspaceResponse:
|
|
1453
|
+
"""The etag is returned."""
|
|
1454
|
+
|
|
1455
|
+
etag: str
|
|
1456
|
+
"""etag used for versioning. The response is at least as fresh as the eTag provided. This is used
|
|
1457
|
+
for optimistic concurrency control as a way to help prevent simultaneous writes of a setting
|
|
1458
|
+
overwriting each other. It is strongly suggested that systems make use of the etag in the read
|
|
1459
|
+
-> delete pattern to perform setting deletions in order to avoid race conditions. That is, get
|
|
1460
|
+
an etag from a GET request, and pass it with the DELETE request to identify the rule set version
|
|
1461
|
+
you are deleting."""
|
|
1462
|
+
|
|
1463
|
+
def as_dict(self) -> dict:
|
|
1464
|
+
"""Serializes the DeleteLlmProxyPartnerPoweredWorkspaceResponse into a dictionary suitable for use as a JSON request body."""
|
|
1465
|
+
body = {}
|
|
1466
|
+
if self.etag is not None:
|
|
1467
|
+
body["etag"] = self.etag
|
|
1468
|
+
return body
|
|
1469
|
+
|
|
1470
|
+
def as_shallow_dict(self) -> dict:
|
|
1471
|
+
"""Serializes the DeleteLlmProxyPartnerPoweredWorkspaceResponse into a shallow dictionary of its immediate attributes."""
|
|
1472
|
+
body = {}
|
|
1473
|
+
if self.etag is not None:
|
|
1474
|
+
body["etag"] = self.etag
|
|
1475
|
+
return body
|
|
1476
|
+
|
|
1477
|
+
@classmethod
|
|
1478
|
+
def from_dict(cls, d: Dict[str, Any]) -> DeleteLlmProxyPartnerPoweredWorkspaceResponse:
|
|
1479
|
+
"""Deserializes the DeleteLlmProxyPartnerPoweredWorkspaceResponse from a dictionary."""
|
|
1480
|
+
return cls(etag=d.get("etag", None))
|
|
1481
|
+
|
|
1482
|
+
|
|
1408
1483
|
@dataclass
|
|
1409
1484
|
class DeleteNetworkConnectivityConfigurationResponse:
|
|
1410
1485
|
def as_dict(self) -> dict:
|
|
@@ -1423,6 +1498,24 @@ class DeleteNetworkConnectivityConfigurationResponse:
|
|
|
1423
1498
|
return cls()
|
|
1424
1499
|
|
|
1425
1500
|
|
|
1501
|
+
@dataclass
|
|
1502
|
+
class DeleteNetworkPolicyRpcResponse:
|
|
1503
|
+
def as_dict(self) -> dict:
|
|
1504
|
+
"""Serializes the DeleteNetworkPolicyRpcResponse into a dictionary suitable for use as a JSON request body."""
|
|
1505
|
+
body = {}
|
|
1506
|
+
return body
|
|
1507
|
+
|
|
1508
|
+
def as_shallow_dict(self) -> dict:
|
|
1509
|
+
"""Serializes the DeleteNetworkPolicyRpcResponse into a shallow dictionary of its immediate attributes."""
|
|
1510
|
+
body = {}
|
|
1511
|
+
return body
|
|
1512
|
+
|
|
1513
|
+
@classmethod
|
|
1514
|
+
def from_dict(cls, d: Dict[str, Any]) -> DeleteNetworkPolicyRpcResponse:
|
|
1515
|
+
"""Deserializes the DeleteNetworkPolicyRpcResponse from a dictionary."""
|
|
1516
|
+
return cls()
|
|
1517
|
+
|
|
1518
|
+
|
|
1426
1519
|
@dataclass
|
|
1427
1520
|
class DeletePersonalComputeSettingResponse:
|
|
1428
1521
|
"""The etag is returned."""
|
|
@@ -1963,6 +2056,257 @@ class EgressNetworkPolicyInternetAccessPolicyStorageDestinationStorageDestinatio
|
|
|
1963
2056
|
GOOGLE_CLOUD_STORAGE = "GOOGLE_CLOUD_STORAGE"
|
|
1964
2057
|
|
|
1965
2058
|
|
|
2059
|
+
@dataclass
|
|
2060
|
+
class EgressNetworkPolicyNetworkAccessPolicy:
|
|
2061
|
+
restriction_mode: EgressNetworkPolicyNetworkAccessPolicyRestrictionMode
|
|
2062
|
+
"""The restriction mode that controls how serverless workloads can access the internet."""
|
|
2063
|
+
|
|
2064
|
+
allowed_internet_destinations: Optional[List[EgressNetworkPolicyNetworkAccessPolicyInternetDestination]] = None
|
|
2065
|
+
"""List of internet destinations that serverless workloads are allowed to access when in
|
|
2066
|
+
RESTRICTED_ACCESS mode."""
|
|
2067
|
+
|
|
2068
|
+
allowed_storage_destinations: Optional[List[EgressNetworkPolicyNetworkAccessPolicyStorageDestination]] = None
|
|
2069
|
+
"""List of storage destinations that serverless workloads are allowed to access when in
|
|
2070
|
+
RESTRICTED_ACCESS mode."""
|
|
2071
|
+
|
|
2072
|
+
policy_enforcement: Optional[EgressNetworkPolicyNetworkAccessPolicyPolicyEnforcement] = None
|
|
2073
|
+
"""Optional. When policy_enforcement is not provided, we default to ENFORCE_MODE_ALL_SERVICES"""
|
|
2074
|
+
|
|
2075
|
+
def as_dict(self) -> dict:
|
|
2076
|
+
"""Serializes the EgressNetworkPolicyNetworkAccessPolicy into a dictionary suitable for use as a JSON request body."""
|
|
2077
|
+
body = {}
|
|
2078
|
+
if self.allowed_internet_destinations:
|
|
2079
|
+
body["allowed_internet_destinations"] = [v.as_dict() for v in self.allowed_internet_destinations]
|
|
2080
|
+
if self.allowed_storage_destinations:
|
|
2081
|
+
body["allowed_storage_destinations"] = [v.as_dict() for v in self.allowed_storage_destinations]
|
|
2082
|
+
if self.policy_enforcement:
|
|
2083
|
+
body["policy_enforcement"] = self.policy_enforcement.as_dict()
|
|
2084
|
+
if self.restriction_mode is not None:
|
|
2085
|
+
body["restriction_mode"] = self.restriction_mode.value
|
|
2086
|
+
return body
|
|
2087
|
+
|
|
2088
|
+
def as_shallow_dict(self) -> dict:
|
|
2089
|
+
"""Serializes the EgressNetworkPolicyNetworkAccessPolicy into a shallow dictionary of its immediate attributes."""
|
|
2090
|
+
body = {}
|
|
2091
|
+
if self.allowed_internet_destinations:
|
|
2092
|
+
body["allowed_internet_destinations"] = self.allowed_internet_destinations
|
|
2093
|
+
if self.allowed_storage_destinations:
|
|
2094
|
+
body["allowed_storage_destinations"] = self.allowed_storage_destinations
|
|
2095
|
+
if self.policy_enforcement:
|
|
2096
|
+
body["policy_enforcement"] = self.policy_enforcement
|
|
2097
|
+
if self.restriction_mode is not None:
|
|
2098
|
+
body["restriction_mode"] = self.restriction_mode
|
|
2099
|
+
return body
|
|
2100
|
+
|
|
2101
|
+
@classmethod
|
|
2102
|
+
def from_dict(cls, d: Dict[str, Any]) -> EgressNetworkPolicyNetworkAccessPolicy:
|
|
2103
|
+
"""Deserializes the EgressNetworkPolicyNetworkAccessPolicy from a dictionary."""
|
|
2104
|
+
return cls(
|
|
2105
|
+
allowed_internet_destinations=_repeated_dict(
|
|
2106
|
+
d, "allowed_internet_destinations", EgressNetworkPolicyNetworkAccessPolicyInternetDestination
|
|
2107
|
+
),
|
|
2108
|
+
allowed_storage_destinations=_repeated_dict(
|
|
2109
|
+
d, "allowed_storage_destinations", EgressNetworkPolicyNetworkAccessPolicyStorageDestination
|
|
2110
|
+
),
|
|
2111
|
+
policy_enforcement=_from_dict(
|
|
2112
|
+
d, "policy_enforcement", EgressNetworkPolicyNetworkAccessPolicyPolicyEnforcement
|
|
2113
|
+
),
|
|
2114
|
+
restriction_mode=_enum(d, "restriction_mode", EgressNetworkPolicyNetworkAccessPolicyRestrictionMode),
|
|
2115
|
+
)
|
|
2116
|
+
|
|
2117
|
+
|
|
2118
|
+
@dataclass
|
|
2119
|
+
class EgressNetworkPolicyNetworkAccessPolicyInternetDestination:
|
|
2120
|
+
"""Users can specify accessible internet destinations when outbound access is restricted. We only
|
|
2121
|
+
support DNS_NAME (FQDN format) destinations for the time being. Going forward we may extend
|
|
2122
|
+
support to host names and IP addresses."""
|
|
2123
|
+
|
|
2124
|
+
destination: Optional[str] = None
|
|
2125
|
+
"""The internet destination to which access will be allowed. Format dependent on the destination
|
|
2126
|
+
type."""
|
|
2127
|
+
|
|
2128
|
+
internet_destination_type: Optional[
|
|
2129
|
+
EgressNetworkPolicyNetworkAccessPolicyInternetDestinationInternetDestinationType
|
|
2130
|
+
] = None
|
|
2131
|
+
"""The type of internet destination. Currently only DNS_NAME is supported."""
|
|
2132
|
+
|
|
2133
|
+
def as_dict(self) -> dict:
|
|
2134
|
+
"""Serializes the EgressNetworkPolicyNetworkAccessPolicyInternetDestination into a dictionary suitable for use as a JSON request body."""
|
|
2135
|
+
body = {}
|
|
2136
|
+
if self.destination is not None:
|
|
2137
|
+
body["destination"] = self.destination
|
|
2138
|
+
if self.internet_destination_type is not None:
|
|
2139
|
+
body["internet_destination_type"] = self.internet_destination_type.value
|
|
2140
|
+
return body
|
|
2141
|
+
|
|
2142
|
+
def as_shallow_dict(self) -> dict:
|
|
2143
|
+
"""Serializes the EgressNetworkPolicyNetworkAccessPolicyInternetDestination into a shallow dictionary of its immediate attributes."""
|
|
2144
|
+
body = {}
|
|
2145
|
+
if self.destination is not None:
|
|
2146
|
+
body["destination"] = self.destination
|
|
2147
|
+
if self.internet_destination_type is not None:
|
|
2148
|
+
body["internet_destination_type"] = self.internet_destination_type
|
|
2149
|
+
return body
|
|
2150
|
+
|
|
2151
|
+
@classmethod
|
|
2152
|
+
def from_dict(cls, d: Dict[str, Any]) -> EgressNetworkPolicyNetworkAccessPolicyInternetDestination:
|
|
2153
|
+
"""Deserializes the EgressNetworkPolicyNetworkAccessPolicyInternetDestination from a dictionary."""
|
|
2154
|
+
return cls(
|
|
2155
|
+
destination=d.get("destination", None),
|
|
2156
|
+
internet_destination_type=_enum(
|
|
2157
|
+
d,
|
|
2158
|
+
"internet_destination_type",
|
|
2159
|
+
EgressNetworkPolicyNetworkAccessPolicyInternetDestinationInternetDestinationType,
|
|
2160
|
+
),
|
|
2161
|
+
)
|
|
2162
|
+
|
|
2163
|
+
|
|
2164
|
+
class EgressNetworkPolicyNetworkAccessPolicyInternetDestinationInternetDestinationType(Enum):
|
|
2165
|
+
|
|
2166
|
+
DNS_NAME = "DNS_NAME"
|
|
2167
|
+
|
|
2168
|
+
|
|
2169
|
+
@dataclass
|
|
2170
|
+
class EgressNetworkPolicyNetworkAccessPolicyPolicyEnforcement:
|
|
2171
|
+
dry_run_mode_product_filter: Optional[
|
|
2172
|
+
List[EgressNetworkPolicyNetworkAccessPolicyPolicyEnforcementDryRunModeProductFilter]
|
|
2173
|
+
] = None
|
|
2174
|
+
"""When empty, it means dry run for all products. When non-empty, it means dry run for specific
|
|
2175
|
+
products and for the other products, they will run in enforced mode."""
|
|
2176
|
+
|
|
2177
|
+
enforcement_mode: Optional[EgressNetworkPolicyNetworkAccessPolicyPolicyEnforcementEnforcementMode] = None
|
|
2178
|
+
"""The mode of policy enforcement. ENFORCED blocks traffic that violates policy, while DRY_RUN only
|
|
2179
|
+
logs violations without blocking. When not specified, defaults to ENFORCED."""
|
|
2180
|
+
|
|
2181
|
+
def as_dict(self) -> dict:
|
|
2182
|
+
"""Serializes the EgressNetworkPolicyNetworkAccessPolicyPolicyEnforcement into a dictionary suitable for use as a JSON request body."""
|
|
2183
|
+
body = {}
|
|
2184
|
+
if self.dry_run_mode_product_filter:
|
|
2185
|
+
body["dry_run_mode_product_filter"] = [v.value for v in self.dry_run_mode_product_filter]
|
|
2186
|
+
if self.enforcement_mode is not None:
|
|
2187
|
+
body["enforcement_mode"] = self.enforcement_mode.value
|
|
2188
|
+
return body
|
|
2189
|
+
|
|
2190
|
+
def as_shallow_dict(self) -> dict:
|
|
2191
|
+
"""Serializes the EgressNetworkPolicyNetworkAccessPolicyPolicyEnforcement into a shallow dictionary of its immediate attributes."""
|
|
2192
|
+
body = {}
|
|
2193
|
+
if self.dry_run_mode_product_filter:
|
|
2194
|
+
body["dry_run_mode_product_filter"] = self.dry_run_mode_product_filter
|
|
2195
|
+
if self.enforcement_mode is not None:
|
|
2196
|
+
body["enforcement_mode"] = self.enforcement_mode
|
|
2197
|
+
return body
|
|
2198
|
+
|
|
2199
|
+
@classmethod
|
|
2200
|
+
def from_dict(cls, d: Dict[str, Any]) -> EgressNetworkPolicyNetworkAccessPolicyPolicyEnforcement:
|
|
2201
|
+
"""Deserializes the EgressNetworkPolicyNetworkAccessPolicyPolicyEnforcement from a dictionary."""
|
|
2202
|
+
return cls(
|
|
2203
|
+
dry_run_mode_product_filter=_repeated_enum(
|
|
2204
|
+
d,
|
|
2205
|
+
"dry_run_mode_product_filter",
|
|
2206
|
+
EgressNetworkPolicyNetworkAccessPolicyPolicyEnforcementDryRunModeProductFilter,
|
|
2207
|
+
),
|
|
2208
|
+
enforcement_mode=_enum(
|
|
2209
|
+
d, "enforcement_mode", EgressNetworkPolicyNetworkAccessPolicyPolicyEnforcementEnforcementMode
|
|
2210
|
+
),
|
|
2211
|
+
)
|
|
2212
|
+
|
|
2213
|
+
|
|
2214
|
+
class EgressNetworkPolicyNetworkAccessPolicyPolicyEnforcementDryRunModeProductFilter(Enum):
|
|
2215
|
+
"""The values should match the list of workloads used in networkconfig.proto"""
|
|
2216
|
+
|
|
2217
|
+
DBSQL = "DBSQL"
|
|
2218
|
+
ML_SERVING = "ML_SERVING"
|
|
2219
|
+
|
|
2220
|
+
|
|
2221
|
+
class EgressNetworkPolicyNetworkAccessPolicyPolicyEnforcementEnforcementMode(Enum):
|
|
2222
|
+
|
|
2223
|
+
DRY_RUN = "DRY_RUN"
|
|
2224
|
+
ENFORCED = "ENFORCED"
|
|
2225
|
+
|
|
2226
|
+
|
|
2227
|
+
class EgressNetworkPolicyNetworkAccessPolicyRestrictionMode(Enum):
|
|
2228
|
+
"""At which level can Databricks and Databricks managed compute access Internet. FULL_ACCESS:
|
|
2229
|
+
Databricks can access Internet. No blocking rules will apply. RESTRICTED_ACCESS: Databricks can
|
|
2230
|
+
only access explicitly allowed internet and storage destinations, as well as UC connections and
|
|
2231
|
+
external locations."""
|
|
2232
|
+
|
|
2233
|
+
FULL_ACCESS = "FULL_ACCESS"
|
|
2234
|
+
RESTRICTED_ACCESS = "RESTRICTED_ACCESS"
|
|
2235
|
+
|
|
2236
|
+
|
|
2237
|
+
@dataclass
|
|
2238
|
+
class EgressNetworkPolicyNetworkAccessPolicyStorageDestination:
|
|
2239
|
+
"""Users can specify accessible storage destinations."""
|
|
2240
|
+
|
|
2241
|
+
azure_storage_account: Optional[str] = None
|
|
2242
|
+
"""The Azure storage account name."""
|
|
2243
|
+
|
|
2244
|
+
azure_storage_service: Optional[str] = None
|
|
2245
|
+
"""The Azure storage service type (blob, dfs, etc.)."""
|
|
2246
|
+
|
|
2247
|
+
bucket_name: Optional[str] = None
|
|
2248
|
+
|
|
2249
|
+
region: Optional[str] = None
|
|
2250
|
+
"""The region of the S3 bucket."""
|
|
2251
|
+
|
|
2252
|
+
storage_destination_type: Optional[
|
|
2253
|
+
EgressNetworkPolicyNetworkAccessPolicyStorageDestinationStorageDestinationType
|
|
2254
|
+
] = None
|
|
2255
|
+
"""The type of storage destination."""
|
|
2256
|
+
|
|
2257
|
+
def as_dict(self) -> dict:
|
|
2258
|
+
"""Serializes the EgressNetworkPolicyNetworkAccessPolicyStorageDestination into a dictionary suitable for use as a JSON request body."""
|
|
2259
|
+
body = {}
|
|
2260
|
+
if self.azure_storage_account is not None:
|
|
2261
|
+
body["azure_storage_account"] = self.azure_storage_account
|
|
2262
|
+
if self.azure_storage_service is not None:
|
|
2263
|
+
body["azure_storage_service"] = self.azure_storage_service
|
|
2264
|
+
if self.bucket_name is not None:
|
|
2265
|
+
body["bucket_name"] = self.bucket_name
|
|
2266
|
+
if self.region is not None:
|
|
2267
|
+
body["region"] = self.region
|
|
2268
|
+
if self.storage_destination_type is not None:
|
|
2269
|
+
body["storage_destination_type"] = self.storage_destination_type.value
|
|
2270
|
+
return body
|
|
2271
|
+
|
|
2272
|
+
def as_shallow_dict(self) -> dict:
|
|
2273
|
+
"""Serializes the EgressNetworkPolicyNetworkAccessPolicyStorageDestination into a shallow dictionary of its immediate attributes."""
|
|
2274
|
+
body = {}
|
|
2275
|
+
if self.azure_storage_account is not None:
|
|
2276
|
+
body["azure_storage_account"] = self.azure_storage_account
|
|
2277
|
+
if self.azure_storage_service is not None:
|
|
2278
|
+
body["azure_storage_service"] = self.azure_storage_service
|
|
2279
|
+
if self.bucket_name is not None:
|
|
2280
|
+
body["bucket_name"] = self.bucket_name
|
|
2281
|
+
if self.region is not None:
|
|
2282
|
+
body["region"] = self.region
|
|
2283
|
+
if self.storage_destination_type is not None:
|
|
2284
|
+
body["storage_destination_type"] = self.storage_destination_type
|
|
2285
|
+
return body
|
|
2286
|
+
|
|
2287
|
+
@classmethod
|
|
2288
|
+
def from_dict(cls, d: Dict[str, Any]) -> EgressNetworkPolicyNetworkAccessPolicyStorageDestination:
|
|
2289
|
+
"""Deserializes the EgressNetworkPolicyNetworkAccessPolicyStorageDestination from a dictionary."""
|
|
2290
|
+
return cls(
|
|
2291
|
+
azure_storage_account=d.get("azure_storage_account", None),
|
|
2292
|
+
azure_storage_service=d.get("azure_storage_service", None),
|
|
2293
|
+
bucket_name=d.get("bucket_name", None),
|
|
2294
|
+
region=d.get("region", None),
|
|
2295
|
+
storage_destination_type=_enum(
|
|
2296
|
+
d,
|
|
2297
|
+
"storage_destination_type",
|
|
2298
|
+
EgressNetworkPolicyNetworkAccessPolicyStorageDestinationStorageDestinationType,
|
|
2299
|
+
),
|
|
2300
|
+
)
|
|
2301
|
+
|
|
2302
|
+
|
|
2303
|
+
class EgressNetworkPolicyNetworkAccessPolicyStorageDestinationStorageDestinationType(Enum):
|
|
2304
|
+
|
|
2305
|
+
AWS_S3 = "AWS_S3"
|
|
2306
|
+
AZURE_STORAGE = "AZURE_STORAGE"
|
|
2307
|
+
GOOGLE_CLOUD_STORAGE = "GOOGLE_CLOUD_STORAGE"
|
|
2308
|
+
|
|
2309
|
+
|
|
1966
2310
|
class EgressResourceType(Enum):
|
|
1967
2311
|
"""The target resources that are supported by Network Connectivity Config. Note: some egress types
|
|
1968
2312
|
can support general types that are not defined in EgressResourceType. E.g.: Azure private
|
|
@@ -2803,6 +3147,41 @@ class ListNetworkConnectivityConfigurationsResponse:
|
|
|
2803
3147
|
)
|
|
2804
3148
|
|
|
2805
3149
|
|
|
3150
|
+
@dataclass
|
|
3151
|
+
class ListNetworkPoliciesResponse:
|
|
3152
|
+
items: Optional[List[AccountNetworkPolicy]] = None
|
|
3153
|
+
"""List of network policies."""
|
|
3154
|
+
|
|
3155
|
+
next_page_token: Optional[str] = None
|
|
3156
|
+
"""A token that can be used to get the next page of results. If null, there are no more results to
|
|
3157
|
+
show."""
|
|
3158
|
+
|
|
3159
|
+
def as_dict(self) -> dict:
|
|
3160
|
+
"""Serializes the ListNetworkPoliciesResponse into a dictionary suitable for use as a JSON request body."""
|
|
3161
|
+
body = {}
|
|
3162
|
+
if self.items:
|
|
3163
|
+
body["items"] = [v.as_dict() for v in self.items]
|
|
3164
|
+
if self.next_page_token is not None:
|
|
3165
|
+
body["next_page_token"] = self.next_page_token
|
|
3166
|
+
return body
|
|
3167
|
+
|
|
3168
|
+
def as_shallow_dict(self) -> dict:
|
|
3169
|
+
"""Serializes the ListNetworkPoliciesResponse into a shallow dictionary of its immediate attributes."""
|
|
3170
|
+
body = {}
|
|
3171
|
+
if self.items:
|
|
3172
|
+
body["items"] = self.items
|
|
3173
|
+
if self.next_page_token is not None:
|
|
3174
|
+
body["next_page_token"] = self.next_page_token
|
|
3175
|
+
return body
|
|
3176
|
+
|
|
3177
|
+
@classmethod
|
|
3178
|
+
def from_dict(cls, d: Dict[str, Any]) -> ListNetworkPoliciesResponse:
|
|
3179
|
+
"""Deserializes the ListNetworkPoliciesResponse from a dictionary."""
|
|
3180
|
+
return cls(
|
|
3181
|
+
items=_repeated_dict(d, "items", AccountNetworkPolicy), next_page_token=d.get("next_page_token", None)
|
|
3182
|
+
)
|
|
3183
|
+
|
|
3184
|
+
|
|
2806
3185
|
@dataclass
|
|
2807
3186
|
class ListNotificationDestinationsResponse:
|
|
2808
3187
|
next_page_token: Optional[str] = None
|
|
@@ -2943,17 +3322,167 @@ class ListType(Enum):
|
|
|
2943
3322
|
|
|
2944
3323
|
|
|
2945
3324
|
@dataclass
|
|
2946
|
-
class
|
|
2947
|
-
|
|
2948
|
-
"""[Input-Only] URL for Microsoft Teams."""
|
|
2949
|
-
|
|
2950
|
-
url_set: Optional[bool] = None
|
|
2951
|
-
"""[Output-Only] Whether URL is set."""
|
|
3325
|
+
class LlmProxyPartnerPoweredAccount:
|
|
3326
|
+
boolean_val: BooleanMessage
|
|
2952
3327
|
|
|
2953
|
-
|
|
2954
|
-
|
|
2955
|
-
|
|
2956
|
-
|
|
3328
|
+
etag: Optional[str] = None
|
|
3329
|
+
"""etag used for versioning. The response is at least as fresh as the eTag provided. This is used
|
|
3330
|
+
for optimistic concurrency control as a way to help prevent simultaneous writes of a setting
|
|
3331
|
+
overwriting each other. It is strongly suggested that systems make use of the etag in the read
|
|
3332
|
+
-> update pattern to perform setting updates in order to avoid race conditions. That is, get an
|
|
3333
|
+
etag from a GET request, and pass it with the PATCH request to identify the setting version you
|
|
3334
|
+
are updating."""
|
|
3335
|
+
|
|
3336
|
+
setting_name: Optional[str] = None
|
|
3337
|
+
"""Name of the corresponding setting. This field is populated in the response, but it will not be
|
|
3338
|
+
respected even if it's set in the request body. The setting name in the path parameter will be
|
|
3339
|
+
respected instead. Setting name is required to be 'default' if the setting only has one instance
|
|
3340
|
+
per workspace."""
|
|
3341
|
+
|
|
3342
|
+
def as_dict(self) -> dict:
|
|
3343
|
+
"""Serializes the LlmProxyPartnerPoweredAccount into a dictionary suitable for use as a JSON request body."""
|
|
3344
|
+
body = {}
|
|
3345
|
+
if self.boolean_val:
|
|
3346
|
+
body["boolean_val"] = self.boolean_val.as_dict()
|
|
3347
|
+
if self.etag is not None:
|
|
3348
|
+
body["etag"] = self.etag
|
|
3349
|
+
if self.setting_name is not None:
|
|
3350
|
+
body["setting_name"] = self.setting_name
|
|
3351
|
+
return body
|
|
3352
|
+
|
|
3353
|
+
def as_shallow_dict(self) -> dict:
|
|
3354
|
+
"""Serializes the LlmProxyPartnerPoweredAccount into a shallow dictionary of its immediate attributes."""
|
|
3355
|
+
body = {}
|
|
3356
|
+
if self.boolean_val:
|
|
3357
|
+
body["boolean_val"] = self.boolean_val
|
|
3358
|
+
if self.etag is not None:
|
|
3359
|
+
body["etag"] = self.etag
|
|
3360
|
+
if self.setting_name is not None:
|
|
3361
|
+
body["setting_name"] = self.setting_name
|
|
3362
|
+
return body
|
|
3363
|
+
|
|
3364
|
+
@classmethod
|
|
3365
|
+
def from_dict(cls, d: Dict[str, Any]) -> LlmProxyPartnerPoweredAccount:
|
|
3366
|
+
"""Deserializes the LlmProxyPartnerPoweredAccount from a dictionary."""
|
|
3367
|
+
return cls(
|
|
3368
|
+
boolean_val=_from_dict(d, "boolean_val", BooleanMessage),
|
|
3369
|
+
etag=d.get("etag", None),
|
|
3370
|
+
setting_name=d.get("setting_name", None),
|
|
3371
|
+
)
|
|
3372
|
+
|
|
3373
|
+
|
|
3374
|
+
@dataclass
|
|
3375
|
+
class LlmProxyPartnerPoweredEnforce:
|
|
3376
|
+
boolean_val: BooleanMessage
|
|
3377
|
+
|
|
3378
|
+
etag: Optional[str] = None
|
|
3379
|
+
"""etag used for versioning. The response is at least as fresh as the eTag provided. This is used
|
|
3380
|
+
for optimistic concurrency control as a way to help prevent simultaneous writes of a setting
|
|
3381
|
+
overwriting each other. It is strongly suggested that systems make use of the etag in the read
|
|
3382
|
+
-> update pattern to perform setting updates in order to avoid race conditions. That is, get an
|
|
3383
|
+
etag from a GET request, and pass it with the PATCH request to identify the setting version you
|
|
3384
|
+
are updating."""
|
|
3385
|
+
|
|
3386
|
+
setting_name: Optional[str] = None
|
|
3387
|
+
"""Name of the corresponding setting. This field is populated in the response, but it will not be
|
|
3388
|
+
respected even if it's set in the request body. The setting name in the path parameter will be
|
|
3389
|
+
respected instead. Setting name is required to be 'default' if the setting only has one instance
|
|
3390
|
+
per workspace."""
|
|
3391
|
+
|
|
3392
|
+
def as_dict(self) -> dict:
|
|
3393
|
+
"""Serializes the LlmProxyPartnerPoweredEnforce into a dictionary suitable for use as a JSON request body."""
|
|
3394
|
+
body = {}
|
|
3395
|
+
if self.boolean_val:
|
|
3396
|
+
body["boolean_val"] = self.boolean_val.as_dict()
|
|
3397
|
+
if self.etag is not None:
|
|
3398
|
+
body["etag"] = self.etag
|
|
3399
|
+
if self.setting_name is not None:
|
|
3400
|
+
body["setting_name"] = self.setting_name
|
|
3401
|
+
return body
|
|
3402
|
+
|
|
3403
|
+
def as_shallow_dict(self) -> dict:
|
|
3404
|
+
"""Serializes the LlmProxyPartnerPoweredEnforce into a shallow dictionary of its immediate attributes."""
|
|
3405
|
+
body = {}
|
|
3406
|
+
if self.boolean_val:
|
|
3407
|
+
body["boolean_val"] = self.boolean_val
|
|
3408
|
+
if self.etag is not None:
|
|
3409
|
+
body["etag"] = self.etag
|
|
3410
|
+
if self.setting_name is not None:
|
|
3411
|
+
body["setting_name"] = self.setting_name
|
|
3412
|
+
return body
|
|
3413
|
+
|
|
3414
|
+
@classmethod
|
|
3415
|
+
def from_dict(cls, d: Dict[str, Any]) -> LlmProxyPartnerPoweredEnforce:
|
|
3416
|
+
"""Deserializes the LlmProxyPartnerPoweredEnforce from a dictionary."""
|
|
3417
|
+
return cls(
|
|
3418
|
+
boolean_val=_from_dict(d, "boolean_val", BooleanMessage),
|
|
3419
|
+
etag=d.get("etag", None),
|
|
3420
|
+
setting_name=d.get("setting_name", None),
|
|
3421
|
+
)
|
|
3422
|
+
|
|
3423
|
+
|
|
3424
|
+
@dataclass
|
|
3425
|
+
class LlmProxyPartnerPoweredWorkspace:
|
|
3426
|
+
boolean_val: BooleanMessage
|
|
3427
|
+
|
|
3428
|
+
etag: Optional[str] = None
|
|
3429
|
+
"""etag used for versioning. The response is at least as fresh as the eTag provided. This is used
|
|
3430
|
+
for optimistic concurrency control as a way to help prevent simultaneous writes of a setting
|
|
3431
|
+
overwriting each other. It is strongly suggested that systems make use of the etag in the read
|
|
3432
|
+
-> update pattern to perform setting updates in order to avoid race conditions. That is, get an
|
|
3433
|
+
etag from a GET request, and pass it with the PATCH request to identify the setting version you
|
|
3434
|
+
are updating."""
|
|
3435
|
+
|
|
3436
|
+
setting_name: Optional[str] = None
|
|
3437
|
+
"""Name of the corresponding setting. This field is populated in the response, but it will not be
|
|
3438
|
+
respected even if it's set in the request body. The setting name in the path parameter will be
|
|
3439
|
+
respected instead. Setting name is required to be 'default' if the setting only has one instance
|
|
3440
|
+
per workspace."""
|
|
3441
|
+
|
|
3442
|
+
def as_dict(self) -> dict:
|
|
3443
|
+
"""Serializes the LlmProxyPartnerPoweredWorkspace into a dictionary suitable for use as a JSON request body."""
|
|
3444
|
+
body = {}
|
|
3445
|
+
if self.boolean_val:
|
|
3446
|
+
body["boolean_val"] = self.boolean_val.as_dict()
|
|
3447
|
+
if self.etag is not None:
|
|
3448
|
+
body["etag"] = self.etag
|
|
3449
|
+
if self.setting_name is not None:
|
|
3450
|
+
body["setting_name"] = self.setting_name
|
|
3451
|
+
return body
|
|
3452
|
+
|
|
3453
|
+
def as_shallow_dict(self) -> dict:
|
|
3454
|
+
"""Serializes the LlmProxyPartnerPoweredWorkspace into a shallow dictionary of its immediate attributes."""
|
|
3455
|
+
body = {}
|
|
3456
|
+
if self.boolean_val:
|
|
3457
|
+
body["boolean_val"] = self.boolean_val
|
|
3458
|
+
if self.etag is not None:
|
|
3459
|
+
body["etag"] = self.etag
|
|
3460
|
+
if self.setting_name is not None:
|
|
3461
|
+
body["setting_name"] = self.setting_name
|
|
3462
|
+
return body
|
|
3463
|
+
|
|
3464
|
+
@classmethod
|
|
3465
|
+
def from_dict(cls, d: Dict[str, Any]) -> LlmProxyPartnerPoweredWorkspace:
|
|
3466
|
+
"""Deserializes the LlmProxyPartnerPoweredWorkspace from a dictionary."""
|
|
3467
|
+
return cls(
|
|
3468
|
+
boolean_val=_from_dict(d, "boolean_val", BooleanMessage),
|
|
3469
|
+
etag=d.get("etag", None),
|
|
3470
|
+
setting_name=d.get("setting_name", None),
|
|
3471
|
+
)
|
|
3472
|
+
|
|
3473
|
+
|
|
3474
|
+
@dataclass
|
|
3475
|
+
class MicrosoftTeamsConfig:
|
|
3476
|
+
url: Optional[str] = None
|
|
3477
|
+
"""[Input-Only] URL for Microsoft Teams."""
|
|
3478
|
+
|
|
3479
|
+
url_set: Optional[bool] = None
|
|
3480
|
+
"""[Output-Only] Whether URL is set."""
|
|
3481
|
+
|
|
3482
|
+
def as_dict(self) -> dict:
|
|
3483
|
+
"""Serializes the MicrosoftTeamsConfig into a dictionary suitable for use as a JSON request body."""
|
|
3484
|
+
body = {}
|
|
3485
|
+
if self.url is not None:
|
|
2957
3486
|
body["url"] = self.url
|
|
2958
3487
|
if self.url_set is not None:
|
|
2959
3488
|
body["url_set"] = self.url_set
|
|
@@ -3372,6 +3901,37 @@ class NetworkConnectivityConfiguration:
|
|
|
3372
3901
|
)
|
|
3373
3902
|
|
|
3374
3903
|
|
|
3904
|
+
@dataclass
|
|
3905
|
+
class NetworkPolicyEgress:
|
|
3906
|
+
"""The network policies applying for egress traffic. This message is used by the UI/REST API. We
|
|
3907
|
+
translate this message to the format expected by the dataplane in Lakehouse Network Manager (for
|
|
3908
|
+
the format expected by the dataplane, see networkconfig.textproto). This policy should be
|
|
3909
|
+
consistent with [[com.databricks.api.proto.settingspolicy.EgressNetworkPolicy]]. Details see
|
|
3910
|
+
API-design: https://docs.google.com/document/d/1DKWO_FpZMCY4cF2O62LpwII1lx8gsnDGG-qgE3t3TOA/"""
|
|
3911
|
+
|
|
3912
|
+
network_access: Optional[EgressNetworkPolicyNetworkAccessPolicy] = None
|
|
3913
|
+
"""The access policy enforced for egress traffic to the internet."""
|
|
3914
|
+
|
|
3915
|
+
def as_dict(self) -> dict:
|
|
3916
|
+
"""Serializes the NetworkPolicyEgress into a dictionary suitable for use as a JSON request body."""
|
|
3917
|
+
body = {}
|
|
3918
|
+
if self.network_access:
|
|
3919
|
+
body["network_access"] = self.network_access.as_dict()
|
|
3920
|
+
return body
|
|
3921
|
+
|
|
3922
|
+
def as_shallow_dict(self) -> dict:
|
|
3923
|
+
"""Serializes the NetworkPolicyEgress into a shallow dictionary of its immediate attributes."""
|
|
3924
|
+
body = {}
|
|
3925
|
+
if self.network_access:
|
|
3926
|
+
body["network_access"] = self.network_access
|
|
3927
|
+
return body
|
|
3928
|
+
|
|
3929
|
+
@classmethod
|
|
3930
|
+
def from_dict(cls, d: Dict[str, Any]) -> NetworkPolicyEgress:
|
|
3931
|
+
"""Deserializes the NetworkPolicyEgress from a dictionary."""
|
|
3932
|
+
return cls(network_access=_from_dict(d, "network_access", EgressNetworkPolicyNetworkAccessPolicy))
|
|
3933
|
+
|
|
3934
|
+
|
|
3375
3935
|
@dataclass
|
|
3376
3936
|
class NotificationDestination:
|
|
3377
3937
|
config: Optional[Config] = None
|
|
@@ -5113,54 +5673,65 @@ class UpdateIpAccessList:
|
|
|
5113
5673
|
|
|
5114
5674
|
|
|
5115
5675
|
@dataclass
|
|
5116
|
-
class
|
|
5117
|
-
|
|
5118
|
-
"""The configuration for the notification destination. Must wrap EXACTLY one of the nested configs."""
|
|
5676
|
+
class UpdateLlmProxyPartnerPoweredAccountRequest:
|
|
5677
|
+
"""Details required to update a setting."""
|
|
5119
5678
|
|
|
5120
|
-
|
|
5121
|
-
"""
|
|
5679
|
+
allow_missing: bool
|
|
5680
|
+
"""This should always be set to true for Settings API. Added for AIP compliance."""
|
|
5122
5681
|
|
|
5123
|
-
|
|
5124
|
-
|
|
5682
|
+
setting: LlmProxyPartnerPoweredAccount
|
|
5683
|
+
|
|
5684
|
+
field_mask: str
|
|
5685
|
+
"""The field mask must be a single string, with multiple fields separated by commas (no spaces).
|
|
5686
|
+
The field path is relative to the resource object, using a dot (`.`) to navigate sub-fields
|
|
5687
|
+
(e.g., `author.given_name`). Specification of elements in sequence or map fields is not allowed,
|
|
5688
|
+
as only the entire collection field can be specified. Field names must exactly match the
|
|
5689
|
+
resource field names.
|
|
5690
|
+
|
|
5691
|
+
A field mask of `*` indicates full replacement. It’s recommended to always explicitly list the
|
|
5692
|
+
fields being updated and avoid using `*` wildcards, as it can lead to unintended results if the
|
|
5693
|
+
API changes in the future."""
|
|
5125
5694
|
|
|
5126
5695
|
def as_dict(self) -> dict:
|
|
5127
|
-
"""Serializes the
|
|
5696
|
+
"""Serializes the UpdateLlmProxyPartnerPoweredAccountRequest into a dictionary suitable for use as a JSON request body."""
|
|
5128
5697
|
body = {}
|
|
5129
|
-
if self.
|
|
5130
|
-
body["
|
|
5131
|
-
if self.
|
|
5132
|
-
body["
|
|
5133
|
-
if self.
|
|
5134
|
-
body["
|
|
5698
|
+
if self.allow_missing is not None:
|
|
5699
|
+
body["allow_missing"] = self.allow_missing
|
|
5700
|
+
if self.field_mask is not None:
|
|
5701
|
+
body["field_mask"] = self.field_mask
|
|
5702
|
+
if self.setting:
|
|
5703
|
+
body["setting"] = self.setting.as_dict()
|
|
5135
5704
|
return body
|
|
5136
5705
|
|
|
5137
5706
|
def as_shallow_dict(self) -> dict:
|
|
5138
|
-
"""Serializes the
|
|
5707
|
+
"""Serializes the UpdateLlmProxyPartnerPoweredAccountRequest into a shallow dictionary of its immediate attributes."""
|
|
5139
5708
|
body = {}
|
|
5140
|
-
if self.
|
|
5141
|
-
body["
|
|
5142
|
-
if self.
|
|
5143
|
-
body["
|
|
5144
|
-
if self.
|
|
5145
|
-
body["
|
|
5709
|
+
if self.allow_missing is not None:
|
|
5710
|
+
body["allow_missing"] = self.allow_missing
|
|
5711
|
+
if self.field_mask is not None:
|
|
5712
|
+
body["field_mask"] = self.field_mask
|
|
5713
|
+
if self.setting:
|
|
5714
|
+
body["setting"] = self.setting
|
|
5146
5715
|
return body
|
|
5147
5716
|
|
|
5148
5717
|
@classmethod
|
|
5149
|
-
def from_dict(cls, d: Dict[str, Any]) ->
|
|
5150
|
-
"""Deserializes the
|
|
5718
|
+
def from_dict(cls, d: Dict[str, Any]) -> UpdateLlmProxyPartnerPoweredAccountRequest:
|
|
5719
|
+
"""Deserializes the UpdateLlmProxyPartnerPoweredAccountRequest from a dictionary."""
|
|
5151
5720
|
return cls(
|
|
5152
|
-
|
|
5721
|
+
allow_missing=d.get("allow_missing", None),
|
|
5722
|
+
field_mask=d.get("field_mask", None),
|
|
5723
|
+
setting=_from_dict(d, "setting", LlmProxyPartnerPoweredAccount),
|
|
5153
5724
|
)
|
|
5154
5725
|
|
|
5155
5726
|
|
|
5156
5727
|
@dataclass
|
|
5157
|
-
class
|
|
5728
|
+
class UpdateLlmProxyPartnerPoweredEnforceRequest:
|
|
5158
5729
|
"""Details required to update a setting."""
|
|
5159
5730
|
|
|
5160
5731
|
allow_missing: bool
|
|
5161
5732
|
"""This should always be set to true for Settings API. Added for AIP compliance."""
|
|
5162
5733
|
|
|
5163
|
-
setting:
|
|
5734
|
+
setting: LlmProxyPartnerPoweredEnforce
|
|
5164
5735
|
|
|
5165
5736
|
field_mask: str
|
|
5166
5737
|
"""The field mask must be a single string, with multiple fields separated by commas (no spaces).
|
|
@@ -5174,7 +5745,7 @@ class UpdatePersonalComputeSettingRequest:
|
|
|
5174
5745
|
API changes in the future."""
|
|
5175
5746
|
|
|
5176
5747
|
def as_dict(self) -> dict:
|
|
5177
|
-
"""Serializes the
|
|
5748
|
+
"""Serializes the UpdateLlmProxyPartnerPoweredEnforceRequest into a dictionary suitable for use as a JSON request body."""
|
|
5178
5749
|
body = {}
|
|
5179
5750
|
if self.allow_missing is not None:
|
|
5180
5751
|
body["allow_missing"] = self.allow_missing
|
|
@@ -5185,7 +5756,7 @@ class UpdatePersonalComputeSettingRequest:
|
|
|
5185
5756
|
return body
|
|
5186
5757
|
|
|
5187
5758
|
def as_shallow_dict(self) -> dict:
|
|
5188
|
-
"""Serializes the
|
|
5759
|
+
"""Serializes the UpdateLlmProxyPartnerPoweredEnforceRequest into a shallow dictionary of its immediate attributes."""
|
|
5189
5760
|
body = {}
|
|
5190
5761
|
if self.allow_missing is not None:
|
|
5191
5762
|
body["allow_missing"] = self.allow_missing
|
|
@@ -5196,43 +5767,188 @@ class UpdatePersonalComputeSettingRequest:
|
|
|
5196
5767
|
return body
|
|
5197
5768
|
|
|
5198
5769
|
@classmethod
|
|
5199
|
-
def from_dict(cls, d: Dict[str, Any]) ->
|
|
5200
|
-
"""Deserializes the
|
|
5770
|
+
def from_dict(cls, d: Dict[str, Any]) -> UpdateLlmProxyPartnerPoweredEnforceRequest:
|
|
5771
|
+
"""Deserializes the UpdateLlmProxyPartnerPoweredEnforceRequest from a dictionary."""
|
|
5201
5772
|
return cls(
|
|
5202
5773
|
allow_missing=d.get("allow_missing", None),
|
|
5203
5774
|
field_mask=d.get("field_mask", None),
|
|
5204
|
-
setting=_from_dict(d, "setting",
|
|
5775
|
+
setting=_from_dict(d, "setting", LlmProxyPartnerPoweredEnforce),
|
|
5205
5776
|
)
|
|
5206
5777
|
|
|
5207
5778
|
|
|
5208
5779
|
@dataclass
|
|
5209
|
-
class
|
|
5210
|
-
"""
|
|
5211
|
-
portal after initialization."""
|
|
5780
|
+
class UpdateLlmProxyPartnerPoweredWorkspaceRequest:
|
|
5781
|
+
"""Details required to update a setting."""
|
|
5212
5782
|
|
|
5213
|
-
|
|
5214
|
-
"""
|
|
5783
|
+
allow_missing: bool
|
|
5784
|
+
"""This should always be set to true for Settings API. Added for AIP compliance."""
|
|
5785
|
+
|
|
5786
|
+
setting: LlmProxyPartnerPoweredWorkspace
|
|
5787
|
+
|
|
5788
|
+
field_mask: str
|
|
5789
|
+
"""The field mask must be a single string, with multiple fields separated by commas (no spaces).
|
|
5790
|
+
The field path is relative to the resource object, using a dot (`.`) to navigate sub-fields
|
|
5791
|
+
(e.g., `author.given_name`). Specification of elements in sequence or map fields is not allowed,
|
|
5792
|
+
as only the entire collection field can be specified. Field names must exactly match the
|
|
5793
|
+
resource field names.
|
|
5215
5794
|
|
|
5216
|
-
|
|
5217
|
-
|
|
5795
|
+
A field mask of `*` indicates full replacement. It’s recommended to always explicitly list the
|
|
5796
|
+
fields being updated and avoid using `*` wildcards, as it can lead to unintended results if the
|
|
5797
|
+
API changes in the future."""
|
|
5218
5798
|
|
|
5219
5799
|
def as_dict(self) -> dict:
|
|
5220
|
-
"""Serializes the
|
|
5800
|
+
"""Serializes the UpdateLlmProxyPartnerPoweredWorkspaceRequest into a dictionary suitable for use as a JSON request body."""
|
|
5221
5801
|
body = {}
|
|
5222
|
-
if self.
|
|
5223
|
-
body["
|
|
5802
|
+
if self.allow_missing is not None:
|
|
5803
|
+
body["allow_missing"] = self.allow_missing
|
|
5804
|
+
if self.field_mask is not None:
|
|
5805
|
+
body["field_mask"] = self.field_mask
|
|
5806
|
+
if self.setting:
|
|
5807
|
+
body["setting"] = self.setting.as_dict()
|
|
5224
5808
|
return body
|
|
5225
5809
|
|
|
5226
5810
|
def as_shallow_dict(self) -> dict:
|
|
5227
|
-
"""Serializes the
|
|
5811
|
+
"""Serializes the UpdateLlmProxyPartnerPoweredWorkspaceRequest into a shallow dictionary of its immediate attributes."""
|
|
5228
5812
|
body = {}
|
|
5229
|
-
if self.
|
|
5230
|
-
body["
|
|
5813
|
+
if self.allow_missing is not None:
|
|
5814
|
+
body["allow_missing"] = self.allow_missing
|
|
5815
|
+
if self.field_mask is not None:
|
|
5816
|
+
body["field_mask"] = self.field_mask
|
|
5817
|
+
if self.setting:
|
|
5818
|
+
body["setting"] = self.setting
|
|
5231
5819
|
return body
|
|
5232
5820
|
|
|
5233
5821
|
@classmethod
|
|
5234
|
-
def from_dict(cls, d: Dict[str, Any]) ->
|
|
5235
|
-
"""Deserializes the
|
|
5822
|
+
def from_dict(cls, d: Dict[str, Any]) -> UpdateLlmProxyPartnerPoweredWorkspaceRequest:
|
|
5823
|
+
"""Deserializes the UpdateLlmProxyPartnerPoweredWorkspaceRequest from a dictionary."""
|
|
5824
|
+
return cls(
|
|
5825
|
+
allow_missing=d.get("allow_missing", None),
|
|
5826
|
+
field_mask=d.get("field_mask", None),
|
|
5827
|
+
setting=_from_dict(d, "setting", LlmProxyPartnerPoweredWorkspace),
|
|
5828
|
+
)
|
|
5829
|
+
|
|
5830
|
+
|
|
5831
|
+
@dataclass
|
|
5832
|
+
class UpdateNotificationDestinationRequest:
|
|
5833
|
+
config: Optional[Config] = None
|
|
5834
|
+
"""The configuration for the notification destination. Must wrap EXACTLY one of the nested configs."""
|
|
5835
|
+
|
|
5836
|
+
display_name: Optional[str] = None
|
|
5837
|
+
"""The display name for the notification destination."""
|
|
5838
|
+
|
|
5839
|
+
id: Optional[str] = None
|
|
5840
|
+
"""UUID identifying notification destination."""
|
|
5841
|
+
|
|
5842
|
+
def as_dict(self) -> dict:
|
|
5843
|
+
"""Serializes the UpdateNotificationDestinationRequest into a dictionary suitable for use as a JSON request body."""
|
|
5844
|
+
body = {}
|
|
5845
|
+
if self.config:
|
|
5846
|
+
body["config"] = self.config.as_dict()
|
|
5847
|
+
if self.display_name is not None:
|
|
5848
|
+
body["display_name"] = self.display_name
|
|
5849
|
+
if self.id is not None:
|
|
5850
|
+
body["id"] = self.id
|
|
5851
|
+
return body
|
|
5852
|
+
|
|
5853
|
+
def as_shallow_dict(self) -> dict:
|
|
5854
|
+
"""Serializes the UpdateNotificationDestinationRequest into a shallow dictionary of its immediate attributes."""
|
|
5855
|
+
body = {}
|
|
5856
|
+
if self.config:
|
|
5857
|
+
body["config"] = self.config
|
|
5858
|
+
if self.display_name is not None:
|
|
5859
|
+
body["display_name"] = self.display_name
|
|
5860
|
+
if self.id is not None:
|
|
5861
|
+
body["id"] = self.id
|
|
5862
|
+
return body
|
|
5863
|
+
|
|
5864
|
+
@classmethod
|
|
5865
|
+
def from_dict(cls, d: Dict[str, Any]) -> UpdateNotificationDestinationRequest:
|
|
5866
|
+
"""Deserializes the UpdateNotificationDestinationRequest from a dictionary."""
|
|
5867
|
+
return cls(
|
|
5868
|
+
config=_from_dict(d, "config", Config), display_name=d.get("display_name", None), id=d.get("id", None)
|
|
5869
|
+
)
|
|
5870
|
+
|
|
5871
|
+
|
|
5872
|
+
@dataclass
|
|
5873
|
+
class UpdatePersonalComputeSettingRequest:
|
|
5874
|
+
"""Details required to update a setting."""
|
|
5875
|
+
|
|
5876
|
+
allow_missing: bool
|
|
5877
|
+
"""This should always be set to true for Settings API. Added for AIP compliance."""
|
|
5878
|
+
|
|
5879
|
+
setting: PersonalComputeSetting
|
|
5880
|
+
|
|
5881
|
+
field_mask: str
|
|
5882
|
+
"""The field mask must be a single string, with multiple fields separated by commas (no spaces).
|
|
5883
|
+
The field path is relative to the resource object, using a dot (`.`) to navigate sub-fields
|
|
5884
|
+
(e.g., `author.given_name`). Specification of elements in sequence or map fields is not allowed,
|
|
5885
|
+
as only the entire collection field can be specified. Field names must exactly match the
|
|
5886
|
+
resource field names.
|
|
5887
|
+
|
|
5888
|
+
A field mask of `*` indicates full replacement. It’s recommended to always explicitly list the
|
|
5889
|
+
fields being updated and avoid using `*` wildcards, as it can lead to unintended results if the
|
|
5890
|
+
API changes in the future."""
|
|
5891
|
+
|
|
5892
|
+
def as_dict(self) -> dict:
|
|
5893
|
+
"""Serializes the UpdatePersonalComputeSettingRequest into a dictionary suitable for use as a JSON request body."""
|
|
5894
|
+
body = {}
|
|
5895
|
+
if self.allow_missing is not None:
|
|
5896
|
+
body["allow_missing"] = self.allow_missing
|
|
5897
|
+
if self.field_mask is not None:
|
|
5898
|
+
body["field_mask"] = self.field_mask
|
|
5899
|
+
if self.setting:
|
|
5900
|
+
body["setting"] = self.setting.as_dict()
|
|
5901
|
+
return body
|
|
5902
|
+
|
|
5903
|
+
def as_shallow_dict(self) -> dict:
|
|
5904
|
+
"""Serializes the UpdatePersonalComputeSettingRequest into a shallow dictionary of its immediate attributes."""
|
|
5905
|
+
body = {}
|
|
5906
|
+
if self.allow_missing is not None:
|
|
5907
|
+
body["allow_missing"] = self.allow_missing
|
|
5908
|
+
if self.field_mask is not None:
|
|
5909
|
+
body["field_mask"] = self.field_mask
|
|
5910
|
+
if self.setting:
|
|
5911
|
+
body["setting"] = self.setting
|
|
5912
|
+
return body
|
|
5913
|
+
|
|
5914
|
+
@classmethod
|
|
5915
|
+
def from_dict(cls, d: Dict[str, Any]) -> UpdatePersonalComputeSettingRequest:
|
|
5916
|
+
"""Deserializes the UpdatePersonalComputeSettingRequest from a dictionary."""
|
|
5917
|
+
return cls(
|
|
5918
|
+
allow_missing=d.get("allow_missing", None),
|
|
5919
|
+
field_mask=d.get("field_mask", None),
|
|
5920
|
+
setting=_from_dict(d, "setting", PersonalComputeSetting),
|
|
5921
|
+
)
|
|
5922
|
+
|
|
5923
|
+
|
|
5924
|
+
@dataclass
|
|
5925
|
+
class UpdatePrivateEndpointRule:
|
|
5926
|
+
"""Properties of the new private endpoint rule. Note that you must approve the endpoint in Azure
|
|
5927
|
+
portal after initialization."""
|
|
5928
|
+
|
|
5929
|
+
domain_names: Optional[List[str]] = None
|
|
5930
|
+
"""Only used by private endpoints to customer-managed resources.
|
|
5931
|
+
|
|
5932
|
+
Domain names of target private link service. When updating this field, the full list of target
|
|
5933
|
+
domain_names must be specified."""
|
|
5934
|
+
|
|
5935
|
+
def as_dict(self) -> dict:
|
|
5936
|
+
"""Serializes the UpdatePrivateEndpointRule into a dictionary suitable for use as a JSON request body."""
|
|
5937
|
+
body = {}
|
|
5938
|
+
if self.domain_names:
|
|
5939
|
+
body["domain_names"] = [v for v in self.domain_names]
|
|
5940
|
+
return body
|
|
5941
|
+
|
|
5942
|
+
def as_shallow_dict(self) -> dict:
|
|
5943
|
+
"""Serializes the UpdatePrivateEndpointRule into a shallow dictionary of its immediate attributes."""
|
|
5944
|
+
body = {}
|
|
5945
|
+
if self.domain_names:
|
|
5946
|
+
body["domain_names"] = self.domain_names
|
|
5947
|
+
return body
|
|
5948
|
+
|
|
5949
|
+
@classmethod
|
|
5950
|
+
def from_dict(cls, d: Dict[str, Any]) -> UpdatePrivateEndpointRule:
|
|
5951
|
+
"""Deserializes the UpdatePrivateEndpointRule from a dictionary."""
|
|
5236
5952
|
return cls(domain_names=d.get("domain_names", None))
|
|
5237
5953
|
|
|
5238
5954
|
|
|
@@ -5309,6 +6025,40 @@ class UpdateRestrictWorkspaceAdminsSettingRequest:
|
|
|
5309
6025
|
WorkspaceConf = Dict[str, str]
|
|
5310
6026
|
|
|
5311
6027
|
|
|
6028
|
+
@dataclass
|
|
6029
|
+
class WorkspaceNetworkOption:
|
|
6030
|
+
network_policy_id: Optional[str] = None
|
|
6031
|
+
"""The network policy ID to apply to the workspace. This controls the network access rules for all
|
|
6032
|
+
serverless compute resources in the workspace. Each workspace can only be linked to one policy
|
|
6033
|
+
at a time. If no policy is explicitly assigned, the workspace will use 'default-policy'."""
|
|
6034
|
+
|
|
6035
|
+
workspace_id: Optional[int] = None
|
|
6036
|
+
"""The workspace ID."""
|
|
6037
|
+
|
|
6038
|
+
def as_dict(self) -> dict:
|
|
6039
|
+
"""Serializes the WorkspaceNetworkOption into a dictionary suitable for use as a JSON request body."""
|
|
6040
|
+
body = {}
|
|
6041
|
+
if self.network_policy_id is not None:
|
|
6042
|
+
body["network_policy_id"] = self.network_policy_id
|
|
6043
|
+
if self.workspace_id is not None:
|
|
6044
|
+
body["workspace_id"] = self.workspace_id
|
|
6045
|
+
return body
|
|
6046
|
+
|
|
6047
|
+
def as_shallow_dict(self) -> dict:
|
|
6048
|
+
"""Serializes the WorkspaceNetworkOption into a shallow dictionary of its immediate attributes."""
|
|
6049
|
+
body = {}
|
|
6050
|
+
if self.network_policy_id is not None:
|
|
6051
|
+
body["network_policy_id"] = self.network_policy_id
|
|
6052
|
+
if self.workspace_id is not None:
|
|
6053
|
+
body["workspace_id"] = self.workspace_id
|
|
6054
|
+
return body
|
|
6055
|
+
|
|
6056
|
+
@classmethod
|
|
6057
|
+
def from_dict(cls, d: Dict[str, Any]) -> WorkspaceNetworkOption:
|
|
6058
|
+
"""Deserializes the WorkspaceNetworkOption from a dictionary."""
|
|
6059
|
+
return cls(network_policy_id=d.get("network_policy_id", None), workspace_id=d.get("workspace_id", None))
|
|
6060
|
+
|
|
6061
|
+
|
|
5312
6062
|
class AccountIpAccessListsAPI:
|
|
5313
6063
|
"""The Accounts IP Access List API enables account admins to configure IP access lists for access to the
|
|
5314
6064
|
account console.
|
|
@@ -5559,6 +6309,8 @@ class AccountSettingsAPI:
|
|
|
5559
6309
|
self._disable_legacy_features = DisableLegacyFeaturesAPI(self._api)
|
|
5560
6310
|
self._enable_ip_access_lists = EnableIpAccessListsAPI(self._api)
|
|
5561
6311
|
self._esm_enablement_account = EsmEnablementAccountAPI(self._api)
|
|
6312
|
+
self._llm_proxy_partner_powered_account = LlmProxyPartnerPoweredAccountAPI(self._api)
|
|
6313
|
+
self._llm_proxy_partner_powered_enforce = LlmProxyPartnerPoweredEnforceAPI(self._api)
|
|
5562
6314
|
self._personal_compute = PersonalComputeAPI(self._api)
|
|
5563
6315
|
|
|
5564
6316
|
@property
|
|
@@ -5581,6 +6333,16 @@ class AccountSettingsAPI:
|
|
|
5581
6333
|
"""The enhanced security monitoring setting at the account level controls whether to enable the feature on new workspaces."""
|
|
5582
6334
|
return self._esm_enablement_account
|
|
5583
6335
|
|
|
6336
|
+
@property
|
|
6337
|
+
def llm_proxy_partner_powered_account(self) -> LlmProxyPartnerPoweredAccountAPI:
|
|
6338
|
+
"""Determines if partner powered models are enabled or not for a specific account."""
|
|
6339
|
+
return self._llm_proxy_partner_powered_account
|
|
6340
|
+
|
|
6341
|
+
@property
|
|
6342
|
+
def llm_proxy_partner_powered_enforce(self) -> LlmProxyPartnerPoweredEnforceAPI:
|
|
6343
|
+
"""Determines if the account-level partner-powered setting value is enforced upon the workspace-level partner-powered setting."""
|
|
6344
|
+
return self._llm_proxy_partner_powered_enforce
|
|
6345
|
+
|
|
5584
6346
|
@property
|
|
5585
6347
|
def personal_compute(self) -> PersonalComputeAPI:
|
|
5586
6348
|
"""The Personal Compute enablement setting lets you control which users can use the Personal Compute default policy to create compute resources."""
|
|
@@ -6316,8 +7078,14 @@ class DisableLegacyAccessAPI:
|
|
|
6316
7078
|
|
|
6317
7079
|
|
|
6318
7080
|
class DisableLegacyDbfsAPI:
|
|
6319
|
-
"""
|
|
6320
|
-
|
|
7081
|
+
"""Disabling legacy DBFS has the following implications:
|
|
7082
|
+
|
|
7083
|
+
1. Access to DBFS root and DBFS mounts is disallowed (as well as the creation of new mounts). 2. Disables
|
|
7084
|
+
Databricks Runtime versions prior to 13.3LTS.
|
|
7085
|
+
|
|
7086
|
+
When the setting is off, all DBFS functionality is enabled and no restrictions are imposed on Databricks
|
|
7087
|
+
Runtime versions. This setting can take up to 20 minutes to take effect and requires a manual restart of
|
|
7088
|
+
all-purpose compute clusters and SQL warehouses."""
|
|
6321
7089
|
|
|
6322
7090
|
def __init__(self, api_client):
|
|
6323
7091
|
self._api = api_client
|
|
@@ -7219,6 +7987,268 @@ class IpAccessListsAPI:
|
|
|
7219
7987
|
self._api.do("PATCH", f"/api/2.0/ip-access-lists/{ip_access_list_id}", body=body, headers=headers)
|
|
7220
7988
|
|
|
7221
7989
|
|
|
7990
|
+
class LlmProxyPartnerPoweredAccountAPI:
|
|
7991
|
+
"""Determines if partner powered models are enabled or not for a specific account"""
|
|
7992
|
+
|
|
7993
|
+
def __init__(self, api_client):
|
|
7994
|
+
self._api = api_client
|
|
7995
|
+
|
|
7996
|
+
def get(self, *, etag: Optional[str] = None) -> LlmProxyPartnerPoweredAccount:
|
|
7997
|
+
"""Get the enable partner powered AI features account setting.
|
|
7998
|
+
|
|
7999
|
+
Gets the enable partner powered AI features account setting.
|
|
8000
|
+
|
|
8001
|
+
:param etag: str (optional)
|
|
8002
|
+
etag used for versioning. The response is at least as fresh as the eTag provided. This is used for
|
|
8003
|
+
optimistic concurrency control as a way to help prevent simultaneous writes of a setting overwriting
|
|
8004
|
+
each other. It is strongly suggested that systems make use of the etag in the read -> delete pattern
|
|
8005
|
+
to perform setting deletions in order to avoid race conditions. That is, get an etag from a GET
|
|
8006
|
+
request, and pass it with the DELETE request to identify the rule set version you are deleting.
|
|
8007
|
+
|
|
8008
|
+
:returns: :class:`LlmProxyPartnerPoweredAccount`
|
|
8009
|
+
"""
|
|
8010
|
+
|
|
8011
|
+
query = {}
|
|
8012
|
+
if etag is not None:
|
|
8013
|
+
query["etag"] = etag
|
|
8014
|
+
headers = {
|
|
8015
|
+
"Accept": "application/json",
|
|
8016
|
+
}
|
|
8017
|
+
|
|
8018
|
+
res = self._api.do(
|
|
8019
|
+
"GET",
|
|
8020
|
+
f"/api/2.0/accounts/{self._api.account_id}/settings/types/llm_proxy_partner_powered/names/default",
|
|
8021
|
+
query=query,
|
|
8022
|
+
headers=headers,
|
|
8023
|
+
)
|
|
8024
|
+
return LlmProxyPartnerPoweredAccount.from_dict(res)
|
|
8025
|
+
|
|
8026
|
+
def update(
|
|
8027
|
+
self, allow_missing: bool, setting: LlmProxyPartnerPoweredAccount, field_mask: str
|
|
8028
|
+
) -> LlmProxyPartnerPoweredAccount:
|
|
8029
|
+
"""Update the enable partner powered AI features account setting.
|
|
8030
|
+
|
|
8031
|
+
Updates the enable partner powered AI features account setting.
|
|
8032
|
+
|
|
8033
|
+
:param allow_missing: bool
|
|
8034
|
+
This should always be set to true for Settings API. Added for AIP compliance.
|
|
8035
|
+
:param setting: :class:`LlmProxyPartnerPoweredAccount`
|
|
8036
|
+
:param field_mask: str
|
|
8037
|
+
The field mask must be a single string, with multiple fields separated by commas (no spaces). The
|
|
8038
|
+
field path is relative to the resource object, using a dot (`.`) to navigate sub-fields (e.g.,
|
|
8039
|
+
`author.given_name`). Specification of elements in sequence or map fields is not allowed, as only
|
|
8040
|
+
the entire collection field can be specified. Field names must exactly match the resource field
|
|
8041
|
+
names.
|
|
8042
|
+
|
|
8043
|
+
A field mask of `*` indicates full replacement. It’s recommended to always explicitly list the
|
|
8044
|
+
fields being updated and avoid using `*` wildcards, as it can lead to unintended results if the API
|
|
8045
|
+
changes in the future.
|
|
8046
|
+
|
|
8047
|
+
:returns: :class:`LlmProxyPartnerPoweredAccount`
|
|
8048
|
+
"""
|
|
8049
|
+
body = {}
|
|
8050
|
+
if allow_missing is not None:
|
|
8051
|
+
body["allow_missing"] = allow_missing
|
|
8052
|
+
if field_mask is not None:
|
|
8053
|
+
body["field_mask"] = field_mask
|
|
8054
|
+
if setting is not None:
|
|
8055
|
+
body["setting"] = setting.as_dict()
|
|
8056
|
+
headers = {
|
|
8057
|
+
"Accept": "application/json",
|
|
8058
|
+
"Content-Type": "application/json",
|
|
8059
|
+
}
|
|
8060
|
+
|
|
8061
|
+
res = self._api.do(
|
|
8062
|
+
"PATCH",
|
|
8063
|
+
f"/api/2.0/accounts/{self._api.account_id}/settings/types/llm_proxy_partner_powered/names/default",
|
|
8064
|
+
body=body,
|
|
8065
|
+
headers=headers,
|
|
8066
|
+
)
|
|
8067
|
+
return LlmProxyPartnerPoweredAccount.from_dict(res)
|
|
8068
|
+
|
|
8069
|
+
|
|
8070
|
+
class LlmProxyPartnerPoweredEnforceAPI:
|
|
8071
|
+
"""Determines if the account-level partner-powered setting value is enforced upon the workspace-level
|
|
8072
|
+
partner-powered setting"""
|
|
8073
|
+
|
|
8074
|
+
def __init__(self, api_client):
|
|
8075
|
+
self._api = api_client
|
|
8076
|
+
|
|
8077
|
+
def get(self, *, etag: Optional[str] = None) -> LlmProxyPartnerPoweredEnforce:
|
|
8078
|
+
"""Get the enforcement status of partner powered AI features account setting.
|
|
8079
|
+
|
|
8080
|
+
Gets the enforcement status of partner powered AI features account setting.
|
|
8081
|
+
|
|
8082
|
+
:param etag: str (optional)
|
|
8083
|
+
etag used for versioning. The response is at least as fresh as the eTag provided. This is used for
|
|
8084
|
+
optimistic concurrency control as a way to help prevent simultaneous writes of a setting overwriting
|
|
8085
|
+
each other. It is strongly suggested that systems make use of the etag in the read -> delete pattern
|
|
8086
|
+
to perform setting deletions in order to avoid race conditions. That is, get an etag from a GET
|
|
8087
|
+
request, and pass it with the DELETE request to identify the rule set version you are deleting.
|
|
8088
|
+
|
|
8089
|
+
:returns: :class:`LlmProxyPartnerPoweredEnforce`
|
|
8090
|
+
"""
|
|
8091
|
+
|
|
8092
|
+
query = {}
|
|
8093
|
+
if etag is not None:
|
|
8094
|
+
query["etag"] = etag
|
|
8095
|
+
headers = {
|
|
8096
|
+
"Accept": "application/json",
|
|
8097
|
+
}
|
|
8098
|
+
|
|
8099
|
+
res = self._api.do(
|
|
8100
|
+
"GET",
|
|
8101
|
+
f"/api/2.0/accounts/{self._api.account_id}/settings/types/llm_proxy_partner_powered_enforce/names/default",
|
|
8102
|
+
query=query,
|
|
8103
|
+
headers=headers,
|
|
8104
|
+
)
|
|
8105
|
+
return LlmProxyPartnerPoweredEnforce.from_dict(res)
|
|
8106
|
+
|
|
8107
|
+
def update(
|
|
8108
|
+
self, allow_missing: bool, setting: LlmProxyPartnerPoweredEnforce, field_mask: str
|
|
8109
|
+
) -> LlmProxyPartnerPoweredEnforce:
|
|
8110
|
+
"""Update the enforcement status of partner powered AI features account setting.
|
|
8111
|
+
|
|
8112
|
+
Updates the enable enforcement status of partner powered AI features account setting.
|
|
8113
|
+
|
|
8114
|
+
:param allow_missing: bool
|
|
8115
|
+
This should always be set to true for Settings API. Added for AIP compliance.
|
|
8116
|
+
:param setting: :class:`LlmProxyPartnerPoweredEnforce`
|
|
8117
|
+
:param field_mask: str
|
|
8118
|
+
The field mask must be a single string, with multiple fields separated by commas (no spaces). The
|
|
8119
|
+
field path is relative to the resource object, using a dot (`.`) to navigate sub-fields (e.g.,
|
|
8120
|
+
`author.given_name`). Specification of elements in sequence or map fields is not allowed, as only
|
|
8121
|
+
the entire collection field can be specified. Field names must exactly match the resource field
|
|
8122
|
+
names.
|
|
8123
|
+
|
|
8124
|
+
A field mask of `*` indicates full replacement. It’s recommended to always explicitly list the
|
|
8125
|
+
fields being updated and avoid using `*` wildcards, as it can lead to unintended results if the API
|
|
8126
|
+
changes in the future.
|
|
8127
|
+
|
|
8128
|
+
:returns: :class:`LlmProxyPartnerPoweredEnforce`
|
|
8129
|
+
"""
|
|
8130
|
+
body = {}
|
|
8131
|
+
if allow_missing is not None:
|
|
8132
|
+
body["allow_missing"] = allow_missing
|
|
8133
|
+
if field_mask is not None:
|
|
8134
|
+
body["field_mask"] = field_mask
|
|
8135
|
+
if setting is not None:
|
|
8136
|
+
body["setting"] = setting.as_dict()
|
|
8137
|
+
headers = {
|
|
8138
|
+
"Accept": "application/json",
|
|
8139
|
+
"Content-Type": "application/json",
|
|
8140
|
+
}
|
|
8141
|
+
|
|
8142
|
+
res = self._api.do(
|
|
8143
|
+
"PATCH",
|
|
8144
|
+
f"/api/2.0/accounts/{self._api.account_id}/settings/types/llm_proxy_partner_powered_enforce/names/default",
|
|
8145
|
+
body=body,
|
|
8146
|
+
headers=headers,
|
|
8147
|
+
)
|
|
8148
|
+
return LlmProxyPartnerPoweredEnforce.from_dict(res)
|
|
8149
|
+
|
|
8150
|
+
|
|
8151
|
+
class LlmProxyPartnerPoweredWorkspaceAPI:
|
|
8152
|
+
"""Determines if partner powered models are enabled or not for a specific workspace"""
|
|
8153
|
+
|
|
8154
|
+
def __init__(self, api_client):
|
|
8155
|
+
self._api = api_client
|
|
8156
|
+
|
|
8157
|
+
def delete(self, *, etag: Optional[str] = None) -> DeleteLlmProxyPartnerPoweredWorkspaceResponse:
|
|
8158
|
+
"""Delete the enable partner powered AI features workspace setting.
|
|
8159
|
+
|
|
8160
|
+
Reverts the enable partner powered AI features workspace setting to its default value.
|
|
8161
|
+
|
|
8162
|
+
:param etag: str (optional)
|
|
8163
|
+
etag used for versioning. The response is at least as fresh as the eTag provided. This is used for
|
|
8164
|
+
optimistic concurrency control as a way to help prevent simultaneous writes of a setting overwriting
|
|
8165
|
+
each other. It is strongly suggested that systems make use of the etag in the read -> delete pattern
|
|
8166
|
+
to perform setting deletions in order to avoid race conditions. That is, get an etag from a GET
|
|
8167
|
+
request, and pass it with the DELETE request to identify the rule set version you are deleting.
|
|
8168
|
+
|
|
8169
|
+
:returns: :class:`DeleteLlmProxyPartnerPoweredWorkspaceResponse`
|
|
8170
|
+
"""
|
|
8171
|
+
|
|
8172
|
+
query = {}
|
|
8173
|
+
if etag is not None:
|
|
8174
|
+
query["etag"] = etag
|
|
8175
|
+
headers = {
|
|
8176
|
+
"Accept": "application/json",
|
|
8177
|
+
}
|
|
8178
|
+
|
|
8179
|
+
res = self._api.do(
|
|
8180
|
+
"DELETE", "/api/2.0/settings/types/llm_proxy_partner_powered/names/default", query=query, headers=headers
|
|
8181
|
+
)
|
|
8182
|
+
return DeleteLlmProxyPartnerPoweredWorkspaceResponse.from_dict(res)
|
|
8183
|
+
|
|
8184
|
+
def get(self, *, etag: Optional[str] = None) -> LlmProxyPartnerPoweredWorkspace:
|
|
8185
|
+
"""Get the enable partner powered AI features workspace setting.
|
|
8186
|
+
|
|
8187
|
+
Gets the enable partner powered AI features workspace setting.
|
|
8188
|
+
|
|
8189
|
+
:param etag: str (optional)
|
|
8190
|
+
etag used for versioning. The response is at least as fresh as the eTag provided. This is used for
|
|
8191
|
+
optimistic concurrency control as a way to help prevent simultaneous writes of a setting overwriting
|
|
8192
|
+
each other. It is strongly suggested that systems make use of the etag in the read -> delete pattern
|
|
8193
|
+
to perform setting deletions in order to avoid race conditions. That is, get an etag from a GET
|
|
8194
|
+
request, and pass it with the DELETE request to identify the rule set version you are deleting.
|
|
8195
|
+
|
|
8196
|
+
:returns: :class:`LlmProxyPartnerPoweredWorkspace`
|
|
8197
|
+
"""
|
|
8198
|
+
|
|
8199
|
+
query = {}
|
|
8200
|
+
if etag is not None:
|
|
8201
|
+
query["etag"] = etag
|
|
8202
|
+
headers = {
|
|
8203
|
+
"Accept": "application/json",
|
|
8204
|
+
}
|
|
8205
|
+
|
|
8206
|
+
res = self._api.do(
|
|
8207
|
+
"GET", "/api/2.0/settings/types/llm_proxy_partner_powered/names/default", query=query, headers=headers
|
|
8208
|
+
)
|
|
8209
|
+
return LlmProxyPartnerPoweredWorkspace.from_dict(res)
|
|
8210
|
+
|
|
8211
|
+
def update(
|
|
8212
|
+
self, allow_missing: bool, setting: LlmProxyPartnerPoweredWorkspace, field_mask: str
|
|
8213
|
+
) -> LlmProxyPartnerPoweredWorkspace:
|
|
8214
|
+
"""Update the enable partner powered AI features workspace setting.
|
|
8215
|
+
|
|
8216
|
+
Updates the enable partner powered AI features workspace setting.
|
|
8217
|
+
|
|
8218
|
+
:param allow_missing: bool
|
|
8219
|
+
This should always be set to true for Settings API. Added for AIP compliance.
|
|
8220
|
+
:param setting: :class:`LlmProxyPartnerPoweredWorkspace`
|
|
8221
|
+
:param field_mask: str
|
|
8222
|
+
The field mask must be a single string, with multiple fields separated by commas (no spaces). The
|
|
8223
|
+
field path is relative to the resource object, using a dot (`.`) to navigate sub-fields (e.g.,
|
|
8224
|
+
`author.given_name`). Specification of elements in sequence or map fields is not allowed, as only
|
|
8225
|
+
the entire collection field can be specified. Field names must exactly match the resource field
|
|
8226
|
+
names.
|
|
8227
|
+
|
|
8228
|
+
A field mask of `*` indicates full replacement. It’s recommended to always explicitly list the
|
|
8229
|
+
fields being updated and avoid using `*` wildcards, as it can lead to unintended results if the API
|
|
8230
|
+
changes in the future.
|
|
8231
|
+
|
|
8232
|
+
:returns: :class:`LlmProxyPartnerPoweredWorkspace`
|
|
8233
|
+
"""
|
|
8234
|
+
body = {}
|
|
8235
|
+
if allow_missing is not None:
|
|
8236
|
+
body["allow_missing"] = allow_missing
|
|
8237
|
+
if field_mask is not None:
|
|
8238
|
+
body["field_mask"] = field_mask
|
|
8239
|
+
if setting is not None:
|
|
8240
|
+
body["setting"] = setting.as_dict()
|
|
8241
|
+
headers = {
|
|
8242
|
+
"Accept": "application/json",
|
|
8243
|
+
"Content-Type": "application/json",
|
|
8244
|
+
}
|
|
8245
|
+
|
|
8246
|
+
res = self._api.do(
|
|
8247
|
+
"PATCH", "/api/2.0/settings/types/llm_proxy_partner_powered/names/default", body=body, headers=headers
|
|
8248
|
+
)
|
|
8249
|
+
return LlmProxyPartnerPoweredWorkspace.from_dict(res)
|
|
8250
|
+
|
|
8251
|
+
|
|
7222
8252
|
class NetworkConnectivityAPI:
|
|
7223
8253
|
"""These APIs provide configurations for the network connectivity of your workspaces for serverless compute
|
|
7224
8254
|
resources. This API provides stable subnets for your workspace so that you can configure your firewalls on
|
|
@@ -7519,6 +8549,134 @@ class NetworkConnectivityAPI:
|
|
|
7519
8549
|
return NccAzurePrivateEndpointRule.from_dict(res)
|
|
7520
8550
|
|
|
7521
8551
|
|
|
8552
|
+
class NetworkPoliciesAPI:
|
|
8553
|
+
"""These APIs manage network policies for this account. Network policies control which network destinations
|
|
8554
|
+
can be accessed from the Databricks environment. Each Databricks account includes a default policy named
|
|
8555
|
+
'default-policy'. 'default-policy' is associated with any workspace lacking an explicit network policy
|
|
8556
|
+
assignment, and is automatically associated with each newly created workspace. 'default-policy' is
|
|
8557
|
+
reserved and cannot be deleted, but it can be updated to customize the default network access rules for
|
|
8558
|
+
your account."""
|
|
8559
|
+
|
|
8560
|
+
def __init__(self, api_client):
|
|
8561
|
+
self._api = api_client
|
|
8562
|
+
|
|
8563
|
+
def create_network_policy_rpc(self, network_policy: AccountNetworkPolicy) -> AccountNetworkPolicy:
|
|
8564
|
+
"""Create a network policy.
|
|
8565
|
+
|
|
8566
|
+
Creates a new network policy to manage which network destinations can be accessed from the Databricks
|
|
8567
|
+
environment.
|
|
8568
|
+
|
|
8569
|
+
:param network_policy: :class:`AccountNetworkPolicy`
|
|
8570
|
+
|
|
8571
|
+
:returns: :class:`AccountNetworkPolicy`
|
|
8572
|
+
"""
|
|
8573
|
+
body = network_policy.as_dict()
|
|
8574
|
+
headers = {
|
|
8575
|
+
"Accept": "application/json",
|
|
8576
|
+
"Content-Type": "application/json",
|
|
8577
|
+
}
|
|
8578
|
+
|
|
8579
|
+
res = self._api.do(
|
|
8580
|
+
"POST", f"/api/2.0/accounts/{self._api.account_id}/network-policies", body=body, headers=headers
|
|
8581
|
+
)
|
|
8582
|
+
return AccountNetworkPolicy.from_dict(res)
|
|
8583
|
+
|
|
8584
|
+
def delete_network_policy_rpc(self, network_policy_id: str):
|
|
8585
|
+
"""Delete a network policy.
|
|
8586
|
+
|
|
8587
|
+
Deletes a network policy. Cannot be called on 'default-policy'.
|
|
8588
|
+
|
|
8589
|
+
:param network_policy_id: str
|
|
8590
|
+
The unique identifier of the network policy to delete.
|
|
8591
|
+
|
|
8592
|
+
|
|
8593
|
+
"""
|
|
8594
|
+
|
|
8595
|
+
headers = {
|
|
8596
|
+
"Accept": "application/json",
|
|
8597
|
+
}
|
|
8598
|
+
|
|
8599
|
+
self._api.do(
|
|
8600
|
+
"DELETE", f"/api/2.0/accounts/{self._api.account_id}/network-policies/{network_policy_id}", headers=headers
|
|
8601
|
+
)
|
|
8602
|
+
|
|
8603
|
+
def get_network_policy_rpc(self, network_policy_id: str) -> AccountNetworkPolicy:
|
|
8604
|
+
"""Get a network policy.
|
|
8605
|
+
|
|
8606
|
+
Gets a network policy.
|
|
8607
|
+
|
|
8608
|
+
:param network_policy_id: str
|
|
8609
|
+
The unique identifier of the network policy to retrieve.
|
|
8610
|
+
|
|
8611
|
+
:returns: :class:`AccountNetworkPolicy`
|
|
8612
|
+
"""
|
|
8613
|
+
|
|
8614
|
+
headers = {
|
|
8615
|
+
"Accept": "application/json",
|
|
8616
|
+
}
|
|
8617
|
+
|
|
8618
|
+
res = self._api.do(
|
|
8619
|
+
"GET", f"/api/2.0/accounts/{self._api.account_id}/network-policies/{network_policy_id}", headers=headers
|
|
8620
|
+
)
|
|
8621
|
+
return AccountNetworkPolicy.from_dict(res)
|
|
8622
|
+
|
|
8623
|
+
def list_network_policies_rpc(self, *, page_token: Optional[str] = None) -> Iterator[AccountNetworkPolicy]:
|
|
8624
|
+
"""List network policies.
|
|
8625
|
+
|
|
8626
|
+
Gets an array of network policies.
|
|
8627
|
+
|
|
8628
|
+
:param page_token: str (optional)
|
|
8629
|
+
Pagination token to go to next page based on previous query.
|
|
8630
|
+
|
|
8631
|
+
:returns: Iterator over :class:`AccountNetworkPolicy`
|
|
8632
|
+
"""
|
|
8633
|
+
|
|
8634
|
+
query = {}
|
|
8635
|
+
if page_token is not None:
|
|
8636
|
+
query["page_token"] = page_token
|
|
8637
|
+
headers = {
|
|
8638
|
+
"Accept": "application/json",
|
|
8639
|
+
}
|
|
8640
|
+
|
|
8641
|
+
while True:
|
|
8642
|
+
json = self._api.do(
|
|
8643
|
+
"GET", f"/api/2.0/accounts/{self._api.account_id}/network-policies", query=query, headers=headers
|
|
8644
|
+
)
|
|
8645
|
+
if "items" in json:
|
|
8646
|
+
for v in json["items"]:
|
|
8647
|
+
yield AccountNetworkPolicy.from_dict(v)
|
|
8648
|
+
if "next_page_token" not in json or not json["next_page_token"]:
|
|
8649
|
+
return
|
|
8650
|
+
query["page_token"] = json["next_page_token"]
|
|
8651
|
+
|
|
8652
|
+
def update_network_policy_rpc(
|
|
8653
|
+
self, network_policy_id: str, network_policy: AccountNetworkPolicy
|
|
8654
|
+
) -> AccountNetworkPolicy:
|
|
8655
|
+
"""Update a network policy.
|
|
8656
|
+
|
|
8657
|
+
Updates a network policy. This allows you to modify the configuration of a network policy.
|
|
8658
|
+
|
|
8659
|
+
:param network_policy_id: str
|
|
8660
|
+
The unique identifier for the network policy.
|
|
8661
|
+
:param network_policy: :class:`AccountNetworkPolicy`
|
|
8662
|
+
|
|
8663
|
+
:returns: :class:`AccountNetworkPolicy`
|
|
8664
|
+
"""
|
|
8665
|
+
body = network_policy.as_dict()
|
|
8666
|
+
headers = {
|
|
8667
|
+
"Accept": "application/json",
|
|
8668
|
+
"Content-Type": "application/json",
|
|
8669
|
+
}
|
|
8670
|
+
|
|
8671
|
+
res = self._api.do(
|
|
8672
|
+
"PUT",
|
|
8673
|
+
f"/api/2.0/accounts/{self._api.account_id}/network-policies/{network_policy_id}",
|
|
8674
|
+
body=body,
|
|
8675
|
+
headers=headers,
|
|
8676
|
+
)
|
|
8677
|
+
return AccountNetworkPolicy.from_dict(res)
|
|
8678
|
+
|
|
8679
|
+
|
|
7522
8680
|
class NotificationDestinationsAPI:
|
|
7523
8681
|
"""The notification destinations API lets you programmatically manage a workspace's notification
|
|
7524
8682
|
destinations. Notification destinations are used to send notifications for query alerts and jobs to
|
|
@@ -7894,6 +9052,7 @@ class SettingsAPI:
|
|
|
7894
9052
|
self._enable_notebook_table_clipboard = EnableNotebookTableClipboardAPI(self._api)
|
|
7895
9053
|
self._enable_results_downloading = EnableResultsDownloadingAPI(self._api)
|
|
7896
9054
|
self._enhanced_security_monitoring = EnhancedSecurityMonitoringAPI(self._api)
|
|
9055
|
+
self._llm_proxy_partner_powered_workspace = LlmProxyPartnerPoweredWorkspaceAPI(self._api)
|
|
7897
9056
|
self._restrict_workspace_admins = RestrictWorkspaceAdminsAPI(self._api)
|
|
7898
9057
|
|
|
7899
9058
|
@property
|
|
@@ -7928,7 +9087,7 @@ class SettingsAPI:
|
|
|
7928
9087
|
|
|
7929
9088
|
@property
|
|
7930
9089
|
def disable_legacy_dbfs(self) -> DisableLegacyDbfsAPI:
|
|
7931
|
-
"""
|
|
9090
|
+
"""Disabling legacy DBFS has the following implications: 1."""
|
|
7932
9091
|
return self._disable_legacy_dbfs
|
|
7933
9092
|
|
|
7934
9093
|
@property
|
|
@@ -7951,6 +9110,11 @@ class SettingsAPI:
|
|
|
7951
9110
|
"""Controls whether enhanced security monitoring is enabled for the current workspace."""
|
|
7952
9111
|
return self._enhanced_security_monitoring
|
|
7953
9112
|
|
|
9113
|
+
@property
|
|
9114
|
+
def llm_proxy_partner_powered_workspace(self) -> LlmProxyPartnerPoweredWorkspaceAPI:
|
|
9115
|
+
"""Determines if partner powered models are enabled or not for a specific workspace."""
|
|
9116
|
+
return self._llm_proxy_partner_powered_workspace
|
|
9117
|
+
|
|
7954
9118
|
@property
|
|
7955
9119
|
def restrict_workspace_admins(self) -> RestrictWorkspaceAdminsAPI:
|
|
7956
9120
|
"""The Restrict Workspace Admins setting lets you control the capabilities of workspace admins."""
|
|
@@ -8247,3 +9411,64 @@ class WorkspaceConfAPI:
|
|
|
8247
9411
|
}
|
|
8248
9412
|
|
|
8249
9413
|
self._api.do("PATCH", "/api/2.0/workspace-conf", body=contents, headers=headers)
|
|
9414
|
+
|
|
9415
|
+
|
|
9416
|
+
class WorkspaceNetworkConfigurationAPI:
|
|
9417
|
+
"""These APIs allow configuration of network settings for Databricks workspaces. Each workspace is always
|
|
9418
|
+
associated with exactly one network policy that controls which network destinations can be accessed from
|
|
9419
|
+
the Databricks environment. By default, workspaces are associated with the 'default-policy' network
|
|
9420
|
+
policy. You cannot create or delete a workspace's network configuration, only update it to associate the
|
|
9421
|
+
workspace with a different policy."""
|
|
9422
|
+
|
|
9423
|
+
def __init__(self, api_client):
|
|
9424
|
+
self._api = api_client
|
|
9425
|
+
|
|
9426
|
+
def get_workspace_network_option_rpc(self, workspace_id: int) -> WorkspaceNetworkOption:
|
|
9427
|
+
"""Get workspace network configuration.
|
|
9428
|
+
|
|
9429
|
+
Gets the network configuration for a workspace. Every workspace has exactly one network policy
|
|
9430
|
+
binding, with 'default-policy' used if no explicit assignment exists.
|
|
9431
|
+
|
|
9432
|
+
:param workspace_id: int
|
|
9433
|
+
The workspace ID.
|
|
9434
|
+
|
|
9435
|
+
:returns: :class:`WorkspaceNetworkOption`
|
|
9436
|
+
"""
|
|
9437
|
+
|
|
9438
|
+
headers = {
|
|
9439
|
+
"Accept": "application/json",
|
|
9440
|
+
}
|
|
9441
|
+
|
|
9442
|
+
res = self._api.do(
|
|
9443
|
+
"GET", f"/api/2.0/accounts/{self._api.account_id}/workspaces/{workspace_id}/network", headers=headers
|
|
9444
|
+
)
|
|
9445
|
+
return WorkspaceNetworkOption.from_dict(res)
|
|
9446
|
+
|
|
9447
|
+
def update_workspace_network_option_rpc(
|
|
9448
|
+
self, workspace_id: int, workspace_network_option: WorkspaceNetworkOption
|
|
9449
|
+
) -> WorkspaceNetworkOption:
|
|
9450
|
+
"""Update workspace network configuration.
|
|
9451
|
+
|
|
9452
|
+
Updates the network configuration for a workspace. This operation associates the workspace with the
|
|
9453
|
+
specified network policy. To revert to the default policy, specify 'default-policy' as the
|
|
9454
|
+
network_policy_id.
|
|
9455
|
+
|
|
9456
|
+
:param workspace_id: int
|
|
9457
|
+
The workspace ID.
|
|
9458
|
+
:param workspace_network_option: :class:`WorkspaceNetworkOption`
|
|
9459
|
+
|
|
9460
|
+
:returns: :class:`WorkspaceNetworkOption`
|
|
9461
|
+
"""
|
|
9462
|
+
body = workspace_network_option.as_dict()
|
|
9463
|
+
headers = {
|
|
9464
|
+
"Accept": "application/json",
|
|
9465
|
+
"Content-Type": "application/json",
|
|
9466
|
+
}
|
|
9467
|
+
|
|
9468
|
+
res = self._api.do(
|
|
9469
|
+
"PUT",
|
|
9470
|
+
f"/api/2.0/accounts/{self._api.account_id}/workspaces/{workspace_id}/network",
|
|
9471
|
+
body=body,
|
|
9472
|
+
headers=headers,
|
|
9473
|
+
)
|
|
9474
|
+
return WorkspaceNetworkOption.from_dict(res)
|