Interface IWorkbooksApiClient
Interface for API client workbook operations.
Inherited Members
Namespace: Tableau.Migration.Api
Assembly: Tableau.Migration.dll
Syntax
public interface IWorkbooksApiClient : IPagedListApiClient<IWorkbook>, IPublishApiClient<IPublishableWorkbook, IWorkbookDetails>, IPullApiClient<IWorkbook, IPublishableWorkbook>, IOwnershipApiClient, ITagsContentApiClient, IApiPageAccessor<IWorkbook>, IContentApiClient, IPermissionsContentApiClient, IConnectionsApiClient
Methods
DownloadWorkbookAsync(Guid, CancellationToken)
Downloads the workbook file for the given ID.
Declaration
Task<IAsyncDisposableResult<FileDownload>> DownloadWorkbookAsync(Guid workbookId, CancellationToken cancel)
Parameters
Type | Name | Description |
---|---|---|
Guid | workbookId | The ID to download the workbook file for. |
CancellationToken | cancel | A cancellation token to obey. |
Returns
Type | Description |
---|---|
Task<IAsyncDisposableResult<FileDownload>> | The file download result. |
GetAllWorkbooksAsync(int, int, CancellationToken)
Gets all workbooks in the current site except the ones in the Personal Space.
Declaration
Task<IPagedResult<IWorkbook>> GetAllWorkbooksAsync(int pageNumber, int pageSize, CancellationToken cancel)
Parameters
Type | Name | Description |
---|---|---|
int | pageNumber | The 1-indexed page number. |
int | pageSize | The size of the page. |
CancellationToken | cancel | The cancellation token to obey. |
Returns
Type | Description |
---|---|
Task<IPagedResult<IWorkbook>> | A list of a page of workbooks in the current site. |
GetWorkbookAsync(Guid, CancellationToken)
Gets a workbook by the given ID.
Declaration
Task<IResult<IWorkbookDetails>> GetWorkbookAsync(Guid workbookId, CancellationToken cancel)
Parameters
Type | Name | Description |
---|---|---|
Guid | workbookId | The ID to get the workbook for. |
CancellationToken | cancel | The cancellation token to obey. |
Returns
Type | Description |
---|---|
Task<IResult<IWorkbookDetails>> | The data sorce result. |
PublishWorkbookAsync(IPublishWorkbookOptions, CancellationToken)
Uploads the input workbook file.
Declaration
Task<IResult<IWorkbookDetails>> PublishWorkbookAsync(IPublishWorkbookOptions options, CancellationToken cancel)
Parameters
Type | Name | Description |
---|---|---|
IPublishWorkbookOptions | options | The new workbook's details. |
CancellationToken | cancel | The cancellation token to obey. |
Returns
Type | Description |
---|---|
Task<IResult<IWorkbookDetails>> | The published workbook. |
UpdateWorkbookAsync(Guid, CancellationToken, string?, string?, Guid?, Guid?, bool?, bool?, bool?)
Updates the workbook after publishing.
Declaration
Task<IResult<IUpdateWorkbookResult>> UpdateWorkbookAsync(Guid workbookId, CancellationToken cancel, string? newName = null, string? newDescription = null, Guid? newProjectId = null, Guid? newOwnerId = null, bool? newShowTabs = null, bool? newRecentlyViewed = null, bool? newEncryptExtracts = null)
Parameters
Type | Name | Description |
---|---|---|
Guid | workbookId | The ID for the workbook to update. |
CancellationToken | cancel | The cancellation token to obey. |
string | newName | The new name of the workbook, or null to not update the name. |
string | newDescription | The new description of the workbook, or null to not update the description. |
Guid? | newProjectId | The LUID of a project to move the workbook to, or null to not update the project. |
Guid? | newOwnerId | The LUID of a user to assign the workbook to as owner, or null to not update the owner. |
bool? | newShowTabs | Whether or not to show workbook views in tabs, or null to not update the option. |
bool? | newRecentlyViewed | Whether or not to show the workbook in the recently viewed list, or null to not update the flag. |
bool? | newEncryptExtracts | Whether or not to encrypt extracts, or null to not update the option. |
Returns
Type | Description |
---|---|
Task<IResult<IUpdateWorkbookResult>> | The update result. |