databricks-sdk 0.29.0__py3-none-any.whl → 0.31.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 +89 -21
- databricks/sdk/config.py +61 -75
- databricks/sdk/core.py +16 -9
- databricks/sdk/credentials_provider.py +15 -15
- databricks/sdk/data_plane.py +65 -0
- databricks/sdk/errors/overrides.py +8 -0
- databricks/sdk/errors/platform.py +5 -0
- databricks/sdk/mixins/files.py +12 -4
- databricks/sdk/service/apps.py +977 -0
- databricks/sdk/service/billing.py +602 -218
- databricks/sdk/service/catalog.py +324 -34
- databricks/sdk/service/compute.py +766 -81
- databricks/sdk/service/dashboards.py +628 -18
- databricks/sdk/service/iam.py +99 -88
- databricks/sdk/service/jobs.py +332 -23
- databricks/sdk/service/marketplace.py +2 -122
- databricks/sdk/service/oauth2.py +127 -70
- databricks/sdk/service/pipelines.py +72 -52
- databricks/sdk/service/serving.py +303 -750
- databricks/sdk/service/settings.py +423 -4
- databricks/sdk/service/sharing.py +235 -25
- databricks/sdk/service/sql.py +2328 -544
- databricks/sdk/useragent.py +151 -0
- databricks/sdk/version.py +1 -1
- {databricks_sdk-0.29.0.dist-info → databricks_sdk-0.31.0.dist-info}/METADATA +36 -16
- {databricks_sdk-0.29.0.dist-info → databricks_sdk-0.31.0.dist-info}/RECORD +30 -27
- {databricks_sdk-0.29.0.dist-info → databricks_sdk-0.31.0.dist-info}/WHEEL +1 -1
- {databricks_sdk-0.29.0.dist-info → databricks_sdk-0.31.0.dist-info}/LICENSE +0 -0
- {databricks_sdk-0.29.0.dist-info → databricks_sdk-0.31.0.dist-info}/NOTICE +0 -0
- {databricks_sdk-0.29.0.dist-info → databricks_sdk-0.31.0.dist-info}/top_level.txt +0 -0
|
@@ -56,7 +56,6 @@ class AssetType(Enum):
|
|
|
56
56
|
ASSET_TYPE_MEDIA = 'ASSET_TYPE_MEDIA'
|
|
57
57
|
ASSET_TYPE_MODEL = 'ASSET_TYPE_MODEL'
|
|
58
58
|
ASSET_TYPE_NOTEBOOK = 'ASSET_TYPE_NOTEBOOK'
|
|
59
|
-
ASSET_TYPE_UNSPECIFIED = 'ASSET_TYPE_UNSPECIFIED'
|
|
60
59
|
|
|
61
60
|
|
|
62
61
|
@dataclass
|
|
@@ -804,11 +803,6 @@ class FileStatus(Enum):
|
|
|
804
803
|
FILE_STATUS_STAGING = 'FILE_STATUS_STAGING'
|
|
805
804
|
|
|
806
805
|
|
|
807
|
-
class FilterType(Enum):
|
|
808
|
-
|
|
809
|
-
METASTORE = 'METASTORE'
|
|
810
|
-
|
|
811
|
-
|
|
812
806
|
class FulfillmentType(Enum):
|
|
813
807
|
|
|
814
808
|
INSTALL = 'INSTALL'
|
|
@@ -1297,16 +1291,11 @@ class Listing:
|
|
|
1297
1291
|
|
|
1298
1292
|
id: Optional[str] = None
|
|
1299
1293
|
|
|
1300
|
-
provider_summary: Optional[ProviderListingSummaryInfo] = None
|
|
1301
|
-
"""we can not use just ProviderListingSummary since we already have same name on entity side of the
|
|
1302
|
-
state"""
|
|
1303
|
-
|
|
1304
1294
|
def as_dict(self) -> dict:
|
|
1305
1295
|
"""Serializes the Listing into a dictionary suitable for use as a JSON request body."""
|
|
1306
1296
|
body = {}
|
|
1307
1297
|
if self.detail: body['detail'] = self.detail.as_dict()
|
|
1308
1298
|
if self.id is not None: body['id'] = self.id
|
|
1309
|
-
if self.provider_summary: body['provider_summary'] = self.provider_summary.as_dict()
|
|
1310
1299
|
if self.summary: body['summary'] = self.summary.as_dict()
|
|
1311
1300
|
return body
|
|
1312
1301
|
|
|
@@ -1315,7 +1304,6 @@ class Listing:
|
|
|
1315
1304
|
"""Deserializes the Listing from a dictionary."""
|
|
1316
1305
|
return cls(detail=_from_dict(d, 'detail', ListingDetail),
|
|
1317
1306
|
id=d.get('id', None),
|
|
1318
|
-
provider_summary=_from_dict(d, 'provider_summary', ProviderListingSummaryInfo),
|
|
1319
1307
|
summary=_from_dict(d, 'summary', ListingSummary))
|
|
1320
1308
|
|
|
1321
1309
|
|
|
@@ -1461,23 +1449,18 @@ class ListingFulfillment:
|
|
|
1461
1449
|
|
|
1462
1450
|
@dataclass
|
|
1463
1451
|
class ListingSetting:
|
|
1464
|
-
filters: Optional[List[VisibilityFilter]] = None
|
|
1465
|
-
"""filters are joined with `or` conjunction."""
|
|
1466
|
-
|
|
1467
1452
|
visibility: Optional[Visibility] = None
|
|
1468
1453
|
|
|
1469
1454
|
def as_dict(self) -> dict:
|
|
1470
1455
|
"""Serializes the ListingSetting into a dictionary suitable for use as a JSON request body."""
|
|
1471
1456
|
body = {}
|
|
1472
|
-
if self.filters: body['filters'] = [v.as_dict() for v in self.filters]
|
|
1473
1457
|
if self.visibility is not None: body['visibility'] = self.visibility.value
|
|
1474
1458
|
return body
|
|
1475
1459
|
|
|
1476
1460
|
@classmethod
|
|
1477
1461
|
def from_dict(cls, d: Dict[str, any]) -> ListingSetting:
|
|
1478
1462
|
"""Deserializes the ListingSetting from a dictionary."""
|
|
1479
|
-
return cls(
|
|
1480
|
-
visibility=_enum(d, 'visibility', Visibility))
|
|
1463
|
+
return cls(visibility=_enum(d, 'visibility', Visibility))
|
|
1481
1464
|
|
|
1482
1465
|
|
|
1483
1466
|
class ListingShareType(Enum):
|
|
@@ -1517,8 +1500,6 @@ class ListingSummary:
|
|
|
1517
1500
|
"""if a git repo is being created, a listing will be initialized with this field as opposed to a
|
|
1518
1501
|
share"""
|
|
1519
1502
|
|
|
1520
|
-
metastore_id: Optional[str] = None
|
|
1521
|
-
|
|
1522
1503
|
provider_id: Optional[str] = None
|
|
1523
1504
|
|
|
1524
1505
|
provider_region: Optional[RegionInfo] = None
|
|
@@ -1552,7 +1533,6 @@ class ListingSummary:
|
|
|
1552
1533
|
if self.exchange_ids: body['exchange_ids'] = [v for v in self.exchange_ids]
|
|
1553
1534
|
if self.git_repo: body['git_repo'] = self.git_repo.as_dict()
|
|
1554
1535
|
if self.listing_type is not None: body['listingType'] = self.listing_type.value
|
|
1555
|
-
if self.metastore_id is not None: body['metastore_id'] = self.metastore_id
|
|
1556
1536
|
if self.name is not None: body['name'] = self.name
|
|
1557
1537
|
if self.provider_id is not None: body['provider_id'] = self.provider_id
|
|
1558
1538
|
if self.provider_region: body['provider_region'] = self.provider_region.as_dict()
|
|
@@ -1577,7 +1557,6 @@ class ListingSummary:
|
|
|
1577
1557
|
exchange_ids=d.get('exchange_ids', None),
|
|
1578
1558
|
git_repo=_from_dict(d, 'git_repo', RepoInfo),
|
|
1579
1559
|
listing_type=_enum(d, 'listingType', ListingType),
|
|
1580
|
-
metastore_id=d.get('metastore_id', None),
|
|
1581
1560
|
name=d.get('name', None),
|
|
1582
1561
|
provider_id=d.get('provider_id', None),
|
|
1583
1562
|
provider_region=_from_dict(d, 'provider_region', RegionInfo),
|
|
@@ -1617,7 +1596,6 @@ class ListingTagType(Enum):
|
|
|
1617
1596
|
|
|
1618
1597
|
LISTING_TAG_TYPE_LANGUAGE = 'LISTING_TAG_TYPE_LANGUAGE'
|
|
1619
1598
|
LISTING_TAG_TYPE_TASK = 'LISTING_TAG_TYPE_TASK'
|
|
1620
|
-
LISTING_TAG_TYPE_UNSPECIFIED = 'LISTING_TAG_TYPE_UNSPECIFIED'
|
|
1621
1599
|
|
|
1622
1600
|
|
|
1623
1601
|
class ListingType(Enum):
|
|
@@ -1733,37 +1711,6 @@ class ProviderAnalyticsDashboard:
|
|
|
1733
1711
|
return cls(id=d.get('id', None))
|
|
1734
1712
|
|
|
1735
1713
|
|
|
1736
|
-
@dataclass
|
|
1737
|
-
class ProviderIconFile:
|
|
1738
|
-
icon_file_id: Optional[str] = None
|
|
1739
|
-
|
|
1740
|
-
icon_file_path: Optional[str] = None
|
|
1741
|
-
|
|
1742
|
-
icon_type: Optional[ProviderIconType] = None
|
|
1743
|
-
|
|
1744
|
-
def as_dict(self) -> dict:
|
|
1745
|
-
"""Serializes the ProviderIconFile into a dictionary suitable for use as a JSON request body."""
|
|
1746
|
-
body = {}
|
|
1747
|
-
if self.icon_file_id is not None: body['icon_file_id'] = self.icon_file_id
|
|
1748
|
-
if self.icon_file_path is not None: body['icon_file_path'] = self.icon_file_path
|
|
1749
|
-
if self.icon_type is not None: body['icon_type'] = self.icon_type.value
|
|
1750
|
-
return body
|
|
1751
|
-
|
|
1752
|
-
@classmethod
|
|
1753
|
-
def from_dict(cls, d: Dict[str, any]) -> ProviderIconFile:
|
|
1754
|
-
"""Deserializes the ProviderIconFile from a dictionary."""
|
|
1755
|
-
return cls(icon_file_id=d.get('icon_file_id', None),
|
|
1756
|
-
icon_file_path=d.get('icon_file_path', None),
|
|
1757
|
-
icon_type=_enum(d, 'icon_type', ProviderIconType))
|
|
1758
|
-
|
|
1759
|
-
|
|
1760
|
-
class ProviderIconType(Enum):
|
|
1761
|
-
|
|
1762
|
-
DARK = 'DARK'
|
|
1763
|
-
PRIMARY = 'PRIMARY'
|
|
1764
|
-
PROVIDER_ICON_TYPE_UNSPECIFIED = 'PROVIDER_ICON_TYPE_UNSPECIFIED'
|
|
1765
|
-
|
|
1766
|
-
|
|
1767
1714
|
@dataclass
|
|
1768
1715
|
class ProviderInfo:
|
|
1769
1716
|
name: str
|
|
@@ -1837,33 +1784,6 @@ class ProviderInfo:
|
|
|
1837
1784
|
term_of_service_link=d.get('term_of_service_link', None))
|
|
1838
1785
|
|
|
1839
1786
|
|
|
1840
|
-
@dataclass
|
|
1841
|
-
class ProviderListingSummaryInfo:
|
|
1842
|
-
"""we can not use just ProviderListingSummary since we already have same name on entity side of the
|
|
1843
|
-
state"""
|
|
1844
|
-
|
|
1845
|
-
description: Optional[str] = None
|
|
1846
|
-
|
|
1847
|
-
icon_files: Optional[List[ProviderIconFile]] = None
|
|
1848
|
-
|
|
1849
|
-
name: Optional[str] = None
|
|
1850
|
-
|
|
1851
|
-
def as_dict(self) -> dict:
|
|
1852
|
-
"""Serializes the ProviderListingSummaryInfo into a dictionary suitable for use as a JSON request body."""
|
|
1853
|
-
body = {}
|
|
1854
|
-
if self.description is not None: body['description'] = self.description
|
|
1855
|
-
if self.icon_files: body['icon_files'] = [v.as_dict() for v in self.icon_files]
|
|
1856
|
-
if self.name is not None: body['name'] = self.name
|
|
1857
|
-
return body
|
|
1858
|
-
|
|
1859
|
-
@classmethod
|
|
1860
|
-
def from_dict(cls, d: Dict[str, any]) -> ProviderListingSummaryInfo:
|
|
1861
|
-
"""Deserializes the ProviderListingSummaryInfo from a dictionary."""
|
|
1862
|
-
return cls(description=d.get('description', None),
|
|
1863
|
-
icon_files=_repeated_dict(d, 'icon_files', ProviderIconFile),
|
|
1864
|
-
name=d.get('name', None))
|
|
1865
|
-
|
|
1866
|
-
|
|
1867
1787
|
@dataclass
|
|
1868
1788
|
class RegionInfo:
|
|
1869
1789
|
cloud: Optional[str] = None
|
|
@@ -1996,14 +1916,6 @@ class SharedDataObject:
|
|
|
1996
1916
|
return cls(data_object_type=d.get('data_object_type', None), name=d.get('name', None))
|
|
1997
1917
|
|
|
1998
1918
|
|
|
1999
|
-
class SortBy(Enum):
|
|
2000
|
-
|
|
2001
|
-
SORT_BY_DATE = 'SORT_BY_DATE'
|
|
2002
|
-
SORT_BY_RELEVANCE = 'SORT_BY_RELEVANCE'
|
|
2003
|
-
SORT_BY_TITLE = 'SORT_BY_TITLE'
|
|
2004
|
-
SORT_BY_UNSPECIFIED = 'SORT_BY_UNSPECIFIED'
|
|
2005
|
-
|
|
2006
|
-
|
|
2007
1919
|
@dataclass
|
|
2008
1920
|
class TokenDetail:
|
|
2009
1921
|
bearer_token: Optional[str] = None
|
|
@@ -2369,25 +2281,6 @@ class Visibility(Enum):
|
|
|
2369
2281
|
PUBLIC = 'PUBLIC'
|
|
2370
2282
|
|
|
2371
2283
|
|
|
2372
|
-
@dataclass
|
|
2373
|
-
class VisibilityFilter:
|
|
2374
|
-
filter_type: Optional[FilterType] = None
|
|
2375
|
-
|
|
2376
|
-
filter_value: Optional[str] = None
|
|
2377
|
-
|
|
2378
|
-
def as_dict(self) -> dict:
|
|
2379
|
-
"""Serializes the VisibilityFilter into a dictionary suitable for use as a JSON request body."""
|
|
2380
|
-
body = {}
|
|
2381
|
-
if self.filter_type is not None: body['filterType'] = self.filter_type.value
|
|
2382
|
-
if self.filter_value is not None: body['filterValue'] = self.filter_value
|
|
2383
|
-
return body
|
|
2384
|
-
|
|
2385
|
-
@classmethod
|
|
2386
|
-
def from_dict(cls, d: Dict[str, any]) -> VisibilityFilter:
|
|
2387
|
-
"""Deserializes the VisibilityFilter from a dictionary."""
|
|
2388
|
-
return cls(filter_type=_enum(d, 'filterType', FilterType), filter_value=d.get('filterValue', None))
|
|
2389
|
-
|
|
2390
|
-
|
|
2391
2284
|
class ConsumerFulfillmentsAPI:
|
|
2392
2285
|
"""Fulfillments are entities that allow consumers to preview installations."""
|
|
2393
2286
|
|
|
@@ -2667,14 +2560,12 @@ class ConsumerListingsAPI:
|
|
|
2667
2560
|
*,
|
|
2668
2561
|
assets: Optional[List[AssetType]] = None,
|
|
2669
2562
|
categories: Optional[List[Category]] = None,
|
|
2670
|
-
is_ascending: Optional[bool] = None,
|
|
2671
2563
|
is_free: Optional[bool] = None,
|
|
2672
2564
|
is_private_exchange: Optional[bool] = None,
|
|
2673
2565
|
is_staff_pick: Optional[bool] = None,
|
|
2674
2566
|
page_size: Optional[int] = None,
|
|
2675
2567
|
page_token: Optional[str] = None,
|
|
2676
2568
|
provider_ids: Optional[List[str]] = None,
|
|
2677
|
-
sort_by: Optional[SortBy] = None,
|
|
2678
2569
|
tags: Optional[List[ListingTag]] = None) -> Iterator[Listing]:
|
|
2679
2570
|
"""List listings.
|
|
2680
2571
|
|
|
@@ -2684,7 +2575,6 @@ class ConsumerListingsAPI:
|
|
|
2684
2575
|
Matches any of the following asset types
|
|
2685
2576
|
:param categories: List[:class:`Category`] (optional)
|
|
2686
2577
|
Matches any of the following categories
|
|
2687
|
-
:param is_ascending: bool (optional)
|
|
2688
2578
|
:param is_free: bool (optional)
|
|
2689
2579
|
Filters each listing based on if it is free.
|
|
2690
2580
|
:param is_private_exchange: bool (optional)
|
|
@@ -2695,8 +2585,6 @@ class ConsumerListingsAPI:
|
|
|
2695
2585
|
:param page_token: str (optional)
|
|
2696
2586
|
:param provider_ids: List[str] (optional)
|
|
2697
2587
|
Matches any of the following provider ids
|
|
2698
|
-
:param sort_by: :class:`SortBy` (optional)
|
|
2699
|
-
Criteria for sorting the resulting set of listings.
|
|
2700
2588
|
:param tags: List[:class:`ListingTag`] (optional)
|
|
2701
2589
|
Matches any of the following tags
|
|
2702
2590
|
|
|
@@ -2706,14 +2594,12 @@ class ConsumerListingsAPI:
|
|
|
2706
2594
|
query = {}
|
|
2707
2595
|
if assets is not None: query['assets'] = [v.value for v in assets]
|
|
2708
2596
|
if categories is not None: query['categories'] = [v.value for v in categories]
|
|
2709
|
-
if is_ascending is not None: query['is_ascending'] = is_ascending
|
|
2710
2597
|
if is_free is not None: query['is_free'] = is_free
|
|
2711
2598
|
if is_private_exchange is not None: query['is_private_exchange'] = is_private_exchange
|
|
2712
2599
|
if is_staff_pick is not None: query['is_staff_pick'] = is_staff_pick
|
|
2713
2600
|
if page_size is not None: query['page_size'] = page_size
|
|
2714
2601
|
if page_token is not None: query['page_token'] = page_token
|
|
2715
2602
|
if provider_ids is not None: query['provider_ids'] = [v for v in provider_ids]
|
|
2716
|
-
if sort_by is not None: query['sort_by'] = sort_by.value
|
|
2717
2603
|
if tags is not None: query['tags'] = [v.as_dict() for v in tags]
|
|
2718
2604
|
headers = {'Accept': 'application/json', }
|
|
2719
2605
|
|
|
@@ -2731,13 +2617,11 @@ class ConsumerListingsAPI:
|
|
|
2731
2617
|
*,
|
|
2732
2618
|
assets: Optional[List[AssetType]] = None,
|
|
2733
2619
|
categories: Optional[List[Category]] = None,
|
|
2734
|
-
is_ascending: Optional[bool] = None,
|
|
2735
2620
|
is_free: Optional[bool] = None,
|
|
2736
2621
|
is_private_exchange: Optional[bool] = None,
|
|
2737
2622
|
page_size: Optional[int] = None,
|
|
2738
2623
|
page_token: Optional[str] = None,
|
|
2739
|
-
provider_ids: Optional[List[str]] = None
|
|
2740
|
-
sort_by: Optional[SortBy] = None) -> Iterator[Listing]:
|
|
2624
|
+
provider_ids: Optional[List[str]] = None) -> Iterator[Listing]:
|
|
2741
2625
|
"""Search listings.
|
|
2742
2626
|
|
|
2743
2627
|
Search published listings in the Databricks Marketplace that the consumer has access to. This query
|
|
@@ -2749,14 +2633,12 @@ class ConsumerListingsAPI:
|
|
|
2749
2633
|
Matches any of the following asset types
|
|
2750
2634
|
:param categories: List[:class:`Category`] (optional)
|
|
2751
2635
|
Matches any of the following categories
|
|
2752
|
-
:param is_ascending: bool (optional)
|
|
2753
2636
|
:param is_free: bool (optional)
|
|
2754
2637
|
:param is_private_exchange: bool (optional)
|
|
2755
2638
|
:param page_size: int (optional)
|
|
2756
2639
|
:param page_token: str (optional)
|
|
2757
2640
|
:param provider_ids: List[str] (optional)
|
|
2758
2641
|
Matches any of the following provider ids
|
|
2759
|
-
:param sort_by: :class:`SortBy` (optional)
|
|
2760
2642
|
|
|
2761
2643
|
:returns: Iterator over :class:`Listing`
|
|
2762
2644
|
"""
|
|
@@ -2764,14 +2646,12 @@ class ConsumerListingsAPI:
|
|
|
2764
2646
|
query = {}
|
|
2765
2647
|
if assets is not None: query['assets'] = [v.value for v in assets]
|
|
2766
2648
|
if categories is not None: query['categories'] = [v.value for v in categories]
|
|
2767
|
-
if is_ascending is not None: query['is_ascending'] = is_ascending
|
|
2768
2649
|
if is_free is not None: query['is_free'] = is_free
|
|
2769
2650
|
if is_private_exchange is not None: query['is_private_exchange'] = is_private_exchange
|
|
2770
2651
|
if page_size is not None: query['page_size'] = page_size
|
|
2771
2652
|
if page_token is not None: query['page_token'] = page_token
|
|
2772
2653
|
if provider_ids is not None: query['provider_ids'] = [v for v in provider_ids]
|
|
2773
2654
|
if query is not None: query['query'] = query
|
|
2774
|
-
if sort_by is not None: query['sort_by'] = sort_by.value
|
|
2775
2655
|
headers = {'Accept': 'application/json', }
|
|
2776
2656
|
|
|
2777
2657
|
while True:
|