Skip to content

Updating to version 1.8.0 to reflect new capabilities in the upcoming… #26

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Nov 4, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion setup.cfg
Original file line number Diff line number Diff line change
@@ -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
Expand Down
2 changes: 1 addition & 1 deletion src/thoughtspot_rest_api_v1/_version.py
Original file line number Diff line number Diff line change
@@ -1 +1 @@
__version__ = '1.7.2'
__version__ = '1.8.0'
19 changes: 19 additions & 0 deletions src/thoughtspot_rest_api_v1/tsrestapiv2.py
Original file line number Diff line number Diff line change
Expand Up @@ -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,
Expand All @@ -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,
Expand Down