diff --git a/setup.cfg b/setup.cfg index 1901ecc..18266ff 100644 --- a/setup.cfg +++ b/setup.cfg @@ -1,6 +1,6 @@ [metadata] name = thoughtspot_rest_api_v1 -version = 1.7.2 +version = 1.8.0 description = Library implementing the ThoughtSpot V1 REST API long_description = file: README.md long_description_content_type = text/markdown diff --git a/src/thoughtspot_rest_api_v1/_version.py b/src/thoughtspot_rest_api_v1/_version.py index 8adfee4..b280975 100644 --- a/src/thoughtspot_rest_api_v1/_version.py +++ b/src/thoughtspot_rest_api_v1/_version.py @@ -1 +1 @@ -__version__ = '1.7.2' +__version__ = '1.8.0' diff --git a/src/thoughtspot_rest_api_v1/tsrestapiv2.py b/src/thoughtspot_rest_api_v1/tsrestapiv2.py index b358bc7..b9c67e3 100644 --- a/src/thoughtspot_rest_api_v1/tsrestapiv2.py +++ b/src/thoughtspot_rest_api_v1/tsrestapiv2.py @@ -460,6 +460,21 @@ def metadata_tml_import(self, metadata_tmls: List[str], import_policy: str = 'PA } return self.post_request(endpoint=endpoint, request=request) + def metadata_tml_async_import(self, metadata_tmls: List[str], import_policy: str = 'PARTIAL', + create_new: bool = False, all_orgs_context: bool = False, + skip_cdw_validation_for_tables: bool = False): + endpoint = 'metadata/tml/async/import' + request = { + 'metadata_tmls': metadata_tmls, + 'import_policy': import_policy, + 'create_new': create_new + } + return self.post_request(endpoint=endpoint, request=request) + + def metadata_tml_async_status(self, request: Dict): + endpoint = 'metadata/tml/async/status' + return self.post_request(endpoint=endpoint, request=request) + # Out of convenience, providing a simple List[str] input for getting these by GUID. metadata_request will override # if you need the deeper functionality with names / types def metadata_tml_export(self, metadata_ids: List[str], export_associated: bool = False, export_fqn: bool = False, @@ -486,6 +501,10 @@ def metadata_tml_export(self, metadata_ids: List[str], export_associated: bool = request['metadata'] = metadata_list return self.post_request(endpoint=endpoint, request=request) + def metadata_tml_export_batch(self, request: Dict): + endpoint = 'metadata/tml/export/batch' + return self.post_request(endpoint=endpoint, request=request) + # Out of convenience, providing a simple List[str] input for getting these by GUID. metadata_request will override # if you need the deeper functionality with names / types def metadata_delete(self, metadata_ids: List[str], delete_disabled_objects: bool = False,