API Reference—All Methods

Using the Tableau Server REST API, you can manage and change Tableau Server resources programmatically, via HTTP. The API gives you simple access to the functionality behind the data sources, projects, workbooks, site users, and sites on a Tableau server. You can use this access to create your own custom applications or to script interactions with Tableau Server resources.

Note: For help with your code that uses the Tableau REST API, submit questions and ask for help on the Tableau developer community forums(Link opens in a new window). For potential bugs in the Tableau REST API code itself, and for any issue with unmodified sample code we provide, use the feedback widget at the bottom of API reference pages.

API Method Categories

The following table lists the Tableau Server REST API methods by category. The table also indicates which methods can be used with Tableau Online.

Analytics Extensions Settings Methods
Add analytics extension connection to site Adds a connection to an external service for analytics extensions on this site.
Delete analytics extension connection Deletes a specific connection to an external service for analytics extensions on this site.
Enable/disable analytics extensions on server Enables or disables analytics extensions on a server.
Get analytics extension details Get the details of a specified analytics extension connection to an external service.
Get current analytics extension for workbook Gets basic details, including connection type and name, of the analytics extension connection to an external service that the specified workbook is currently using.
Get enabled state of analytics extensions on server Gets the enabled/disabled state of analytics extensions on a server.
Get enabled state of analytics extensions on site Gets the enabled/disabled state of analytics extensions on a site.
List analytics extension connections of workbook Lists basic details of each analytics extension connection available for a specified workbook, including connection type and name.
List analytics extension connections on site Lists a site's analytics extension connections for external services.
Update analytics extension connection Updates a specific connection to an external service for analytics extensions on this site.
Update enabled state of analytics extensions on site Enables or disables analytics extensions on a site.
Authentication Methods
Revoke Administrator Personal Access Tokens
- Not available for Tableau Online.
Revokes all personal access tokens(Link opens in a new window) (PATs) created by server administrators.
Sign In Signs you in as a user on the specified site on Tableau Server or Tableau Online.
Sign Out Signs you out of the current session.
Switch Site
- Not available for Tableau Online.
Switches you onto another site without having to provide a user name and password again.
Dashboard Extensions Settings Methods
Allow dashboard extension on site Adds a dashboard extension to the safe list the site you are signed into.
Block dashboard extension on server Adds a dashboard extension to the block list of a server.
Disallow dashboard extension on site Deletes a specific dashboard extension from the safe list of the site you are signed into.
Get allowed dashboard extension on site Gets the details of a specific dashboard extension on the safe list of the site you are signed into.
Get blocked dashboard extension on server Gets the details of a specific dashboard extension on the blocked list of a server.
List blocked dashboard extensions on server Lists the dashboard extensions on the blocked list of a server.
List dashboard extension settings of server Lists the dashboard extension settings of a server.
List dashboard extension settings of site Lists the dashboard extension settings of the site you are signed into.
Lists allowed dashboard extensions on site Lists the dashboard extensions on the safe list of the site you are signed into.
Unblock dashboard extension on server Deletes a specific extension from the block list of a server.
Update dashboard extension settings of site Updates the settings for dashboard extensions for the site you are signed into.
Update dashboard extensions settings of server Updates the settings for dashboard extensions of a server.
Update settings for allowed dashboard extension on site Updates the settings of a specific dashboard extension in the safe list of the site you are signed into.
Data Sources Methods
Add Tags to Data Source Adds one or more tags to the specified data source.
Delete Data Source Deletes the specified data source from a site.
Delete Tag from Data Source Deletes a tag from the specified data source.
Download Data Source Downloads a data source in .tdsx format.
Download Data Source Revision Downloads a specific version of a data source prior to the current one in .tdsx format.
Get Data Source Revisions Returns a list of revision information (history) for the specified data source.
Publish Data Source Publishes a data source on the specified site, or appends data to an existing data source.
Query Data Source Returns information about the specified data source.
Query Data Source Connections Returns a list of data connections for the specified data source.
Query Data Sources Returns a list of published data sources on the specified site, with optional parameters for specifying the paging of large results. To get a list of data sources embedded in a workbook, use the Query Workbook Connections method.
Remove Data Source Revision Removes a specific version of a data source from the specified site.
Update Data Source Updates the owner, project or certification status of the specified data source.
Update Data Source Connection Updates the server address, port, username, or password for the specified data source connection.
Update Data Source Now Runs an extract refresh on the specified data source.
Update Data in Hyper Connection Modifies defined portions of published live-to-Hyper data from a specified data source.
Update Data in Hyper Data Source Modifies defined portions of published live-to-Hyper data from a specified data source.
Data-Driven Alerts Methods
Add User to Data-Driven Alert Adds a specified user to the recipients list for a data-driven alert.
Delete Data-Driven Alert Deletes the specified data-driven alert from the specified site.
Delete User from Data-Driven Alert Removes a specified user from the recipients list for a data-driven alert.
Query Data-Driven Alert Details Returns details on a specified data-driven alert, including the recipients of the alert.
Query Data-Driven Alerts Returns a list of data-driven alerts in use on the specified site.
Update Data-Driven Alert Update one or more settings for the specified data-driven alert; including the alert subject, frequency, and owner.
Extract and Encryption Methods
Create Extracts for Embedded Data Sources in a Workbook Create extracts for all embedded data sources of a workbook.
Create an Extract for a Data Source Create an extract for a data source in a site.
Decrypt Extracts in a Site Extract encryption at rest is a data security feature that allows you to encrypt .hyper extracts while they are stored on Tableau Server.
Delete Extract Refresh Task Deletes an extract refresh task.
Delete Extracts of Embedded Data Sources from a Workbook Delete all extracts of embedded data sources in a workbook.
Delete the Extract from a Data Source Delete the extract of a data source in a site.
Encrypt Extracts in a Site Extract encryption at rest is a data security feature that allows you to encrypt .hyper extracts while they are stored on Tableau Server.
Reencrypt Extracts in a Site Extract encryption at rest is a data security feature that allows you to encrypt .hyper extracts while they are stored on Tableau Server.
Favorites Methods
Add Data Source to Favorites Adds the specified data source to the user's favorites.
Add Flow to Favorites Adds the specified flow to the user's favorites.
Add Project to Favorites Adds the specified project to a user's favorites.
Add View to Favorites Adds the specified view to a user's favorites.
Add Workbook to Favorites Adds the specified workbook to a user's favorites.
Delete Data Source from Favorites Deletes the specified data source from the user's favorites.
Delete Flow from Favorites Deletes the specified flow from the user's favorites.
Delete Project from Favorites Deletes the specified project from the user's favorites.
Delete View from Favorites Deletes the specified view from user's favorites.
Delete Workbook from Favorites Deletes a workbook from a user's favorites.
Get Favorites for User Returns a list of favorite projects, data sources, views, workbooks, and flows for a user.
Organize Favorites Move an item to organize a user's favorites.
Flow Methods
Add Flow Permissions Adds permissions to the specified flow for a Tableau Server user or group.
Add Flow Task to Schedule Adds a task to run a flow to an existing schedule.
Cancel Flow Run Cancels a flow run that is in progress.
Delete Flow Deletes a flow.
Delete Flow Permission Deletes the specified permission from the specified flow for a group or user.
Download Flow Downloads a flow in .tfl or .tflx format.
Get Flow Run Gets a flow run.
Get Flow Run Task Returns information about the specified flow run task.
Get Flow Run Tasks Returns a list of scheduled flow tasks for the site.
Get Flow Runs Get flow runs.
Publish Flow Publishes a flow on the specified site.
Query Flow Returns information about the specified flow, including information about the project, owner, and output steps.
Query Flow Connections Returns a list of data connections for the specific flow.
Query Flow Permissions Returns a list of permissions for the specific flow.
Query Flows for User Returns the flows that the specified user owns in addition to those that the user has Read (view) permissions for.
Query Flows for a Site Returns the flows on a site.
Run Flow Now Runs the specified flow.
Run Flow Task Runs the specified flow run task.
Update Flow Updates the owner, project, of the specified flow.
Update Flow Connection Updates the server address, port, username, or password for the specified flow connection.
Jobs, Tasks, and Schedules Methods
Add Data Source to Schedule Adds a task to refresh a data source to an existing schedule.
Add Workbook to Schedule Adds a task to refresh or accelerate a workbook to an existing schedule.
Cancel Job Cancels a job specified by job ID.
Create Schedule Creates a new schedule on Tableau Server.
Delete Data Acceleration Task Deletes a data acceleration task.
Delete Extract Refresh Task Deletes an extract refresh task.
Delete Schedule Deletes the specified schedule.
Get Data Acceleration Tasks in a Site Returns a list of data acceleration tasks for the site.
Get Extract Refresh Task Returns information about the specified extract refresh task.
Get Extract Refresh Tasks in a Schedule Returns a list of the extract refresh tasks for a specified schedule on the specified site.
Get Extract Refresh Tasks in a Site Returns a list of extract refresh tasks for the site.
Get Schedule Returns detailed information about the specified schedule.
Query Job Returns status information about an asynchronous process that is tracked using a job.
Query Jobs Returns a list of active jobs on the specified site.
Query Schedules Returns a list of flows, extract and subscription schedules.
Run Extract Refresh Task Runs the specified extract refresh task.
Update Schedule Modifies settings for the specified schedule, including the name, priority, and frequency details.
Metadata Methods
Add (or Update) Data Quality Certifications
- Available only with the Data Management Add-on.
Create or update one or more data quality certifications for different content and asset items.
Add (or Update) Quality Warning Trigger
- Available only with the Data Management Add-on.
Create or update one or more quality warning triggers to monitor and display alerts for the following events: refresh failures on extract data sources and flow run failures on flows.
Add Data Quality Warning
- Available only with the Data Management Add-on.
Create and apply a data quality warning to a database, table, published data source, or flow.
Add Database Permissions
- Available only with the Data Management Add-on.
Add permissions to a database asset.
Add Default Database Permissions
- Available only with the Data Management Add-on.
Applying default permissions to a database functions as a permissions template for the database's children table assets.
Add Table Permissions
- Available only with the Data Management Add-on.
Add permissions to a table asset.
Add Tags to Column Add one or more tags to a column.
Add Tags to Database Add one or more tags to a database.
Add Tags to Table Add one or more tags to a table.
Batch Add (or Update) Data Quality Warnings
- Available only with the Data Management Add-on.
Add or update multiple data quality warnings (DQWs) for different content and asset items.
Batch Add Tags
- Available only with the Data Management Add-on.
Add multiple tags to items that are different content and asset types.
Batch Delete Data Quality Warnings
- Available only with the Data Management Add-on.
Permanently remove multiple data quality warning (DQW) items from different content and asset types.
Batch Delete Tags
- Available only with the Data Management Add-on.
Delete multiple tags from items that are different content and asset types.
Delete Data Quality Certification by ID
- Available only with the Data Management Add-on.
Permanently remove a data quality certification from a content or asset item using the data quality certification ID.
Delete Data Quality Certifications by Content
- Available only with the Data Management Add-on.
Permanently remove all data quality certifications from multiple content or asset items.
Delete Data Quality Warning by Content
- Available only with the Data Management Add-on.
Permanently remove the data quality warning from the database, table, published data source, or flow.
Delete Data Quality Warning by ID
- Available only with the Data Management Add-on.
Permanently remove a data quality warning.
Delete Database Permissions
- Available only with the Data Management Add-on.
Permanently remove the permissions applied to a database asset.
Delete Default Database Permissions
- Available only with the Data Management Add-on.
Permanently remove the default permissions on a database asset.
Delete Quality Warning Trigger by ID
- Available only with the Data Management Add-on.
Permanently remove a quality warning trigger using the quality warning trigger ID.
Delete Quality Warning Triggers by Content
- Available only with the Data Management Add-on.
Permanently remove all quality warning triggers for one or more data sources or flows, or both.
Delete Table Permissions
- Available only with the Data Management Add-on.
Permanently remove the permissions applied to a table asset.
Delete Tag from Column Delete a tag from a column.
Delete Tag from Database Delete a tag from a database.
Delete Tag from Table Delete a tag from a table.
Get Databases and Tables from Connection Query databases and tables from the connection information in the data source (.tds or .tdsx) or workbook (.tws or .twbx) file's XML.
Query All Quality Warning Triggers by Content Get information about all quality warning triggers for a content item.
Query Column in a Table Get information about a column in a table asset.
Query Columns in a Table Get information about the columns in a table asset.
Query Data Quality Certification by ID Get information about a data quality certification.
Query Data Quality Certifications by Content Get all data quality certifications for content or asset items.
Query Data Quality Warning by Content Get information about the data quality warning for the database, table, published data source, or flow.
Query Data Quality Warning by ID Get information about a specific data quality warning.
Query Database Get information about a database asset.
Query Database Permissions Get information about the permissions on a database asset.
Query Databases Get information about all database assets for a site.
Query Default Database Permissions Get the default permissions applied to the database asset and its children tables.
Query Quality Warning Trigger Get information about a quality warning trigger.
Query Table Get information about a table asset.
Query Table Permissions Get information about the permissions on a table asset.
Query Tables Get information about all table assets for a site.
Remove Column
- Available only with the Data Management Add-on.
Permanently remove the column from a table asset.
Remove Database
- Available only with the Data Management Add-on.
Permanently remove the database asset.
Remove Table
- Available only with the Data Management Add-on.
Permanently remove the table asset.
Update Column
- Available only with the Data Management Add-on.
Update the description of the column.
Update Data Quality Warning
- Available only with the Data Management Add-on.
Update the warning type, status, and message of a data quality warning.
Update Database
- Available only with the Data Management Add-on.
Update the database description, certify a database, or assign a contact (must be a Tableau Server or Tableau Online user) to the database asset.
Update Quality Warning Trigger
- Available only with the Data Management Add-on.
Update a quality warning trigger.
Update Table
- Available only with the Data Management Add-on.
Update the table description, certify a table, or a assign a user contact to the table asset.
Metrics Methods
Delete Metric Deletes a specified metric from a site.
Get Metric Returns the details of the specified metric.
List Metrics for Site Returns the metrics configured for a site.
Update Metric Updates the owner, project, suspended status, or name of the specified metric.
Permissions Methods
Add Data Source Permissions Adds permissions to the specified data source for a Tableau Server user or group.
Add Default Permissions Adds default permission capabilities granted to a user or group, for metric, flow, workbook, data source, data role, or lense resources in a project.
Add Project Permissions Adds permissions to the specified project for a Tableau Server user or group.
Add View Permissions Adds permissions to the specified view (also known as a sheet) for a Tableau Server user or group.
Add Workbook Permissions Adds permissions to the specified workbook for a Tableau Server user or group.
Add Workbook to Schedule Adds a task to refresh or accelerate a workbook to an existing schedule.
Delete Data Source Permission Removes the specified data source permission for the specified group or user.
Delete Default Permission Removes default permission capabilities granted to a user or group, for metric, flow, workbook, data source, data role, or lense resources in a project.
Delete Project Permission Removes the specified project permission for the specified group or user.
Delete View Permission Deletes permission to the specified view (also known as a sheet) for a Tableau Server user or group.
Delete Workbook Permission Deletes the specified permission from the specified workbook for a group or user.
Query Data Source Permissions Returns a list of permissions for a specific data source.
Query Default Permissions Returns details of default permission capabilities granted to users and groups for metric, flow, workbook, data source, data role, or lense resources in a project.
Query Project Permissions Returns information about the set of permissions allowed or denied for groups and users in a project.
Query View Permissions Returns a list of permissions for the specific view.
Query Workbook Permissions Returns a list of permissions for the specific workbook.
Projects Methods
Create Project Creates a project on the specified site.
Delete Project Deletes the specified project on a specific site.
Query Projects Returns a list of projects on the specified site, with optional parameters for specifying the paging of large results.
Update Project Updates the name, description, or project hierarchy of the specified project.
Publishing Methods
Append to File Upload Uploads a block of data and appends it to the data that is already uploaded.
Initiate File Upload Initiates the upload process for a file.
Publish Data Source Publishes a data source on the specified site, or appends data to an existing data source.
Publish Flow Publishes a flow on the specified site.
Publish Workbook Publishes a workbook on the specified site.
Revisions Methods
Download Data Source Revision Downloads a specific version of a data source prior to the current one in .tdsx format.
Download Workbook Revision Downloads a specific version of a workbook in .twb or .twbx format.
Get Data Source Revisions Returns a list of revision information (history) for the specified data source.
Get Workbook Revisions Returns a list of revision information (history) for the specified workbook.
Remove Data Source Revision Removes a specific version of a data source from the specified site.
Remove Workbook Revision Removes a specific version of a workbook from the specified site.
Server Methods
Delete Server Session Deletes a specified session.
Get Current Server Session Returns details of the current session of Tableau Server.
List Server Active Directory Domains
- Not available for Tableau Online.
Returns the details of the Active Directory domains that are in use on the server, including their full domain names, nicknames and IDs.
Server Info Returns the version of Tableau Server and the supported version of the REST API.
Update Server Active Directory Domain
- Not available for Tableau Online.
Changes the nickname or full domain name of an Active Directory domain on the server.
Site Methods
Create Site
- Not available for Tableau Online.
Creates a site on Tableau Server.
Delete Site Deletes the specified site.
Get Data Acceleration Report for a Site Returns a report about data acceleration for the site.
Get Recently Viewed for Site Gets the details of the views and workbooks on a site that have been most recently created, updated, or accessed by the signed in user.
Query Site Returns information about the specified site, with the option to return information about the storage space and user count for the site.
Query Sites Returns a list of the sites on the server that the caller of this method has access to.
Query Views for Site Returns all the views for the specified site, optionally including usage statistics.
Update Site Modifies settings for the specified site, including the content URL, administration mode, user quota, state (active or suspended), storage quota, whether flows are enabled, whether subscriptions are enabled, and whether revisions are enabled.
Subscriptions Methods
Create Subscription Creates a new, unsuspended subscription to a view or workbook for a specific user.
Delete Subscription Deletes the specified subscription.
Query Subscription Returns information about the specified subscription.
Query Subscriptions Returns a list of all the subscriptions on the specified site.
Update Subscription Modifies an existing subscription, allowing you to change the subject, schedule, and suspension state for the subscription.
Users and Groups Methods
Add User to Group Adds a user to the specified group.
Add User to Site Adds a user to Tableau Server and assigns the user to the specified site.
Create Group Creates a group.
Delete Group Deletes the group on a specific site.
Get Groups for a User Gets a list of groups of which the specified user is a member.
Get Users in Group Gets a list of users in the specified group.
Get Users on Site Returns the users associated with the specified site.
Query Groups Returns a list of groups on the specified site, with optional parameters for specifying the paging of large results.
Query User On Site Returns information about the specified user.
Remove User from Group Removes a user from the specified group.
Remove User from Site Removes a user from the specified site.
Update Group Updates a group.
Update User Modifies information about the specified user.
Webhooks Methods
Create a Webhook Creates a new webhook for a site.
Delete a Webhook Deletes the specified webhook.
Get a Webhook Returns information about the specified webhook.
List Webhooks Returns a list of all the webhooks on the specified site.
Test a Webhook Tests the specified webhook.
Update a Webhook Modify the properties of an existing webhook.
Workbooks and Views Methods
Add Tags to View Adds one or more tags to the specified view.
Add Tags to Workbook Adds one or more tags to the specified workbook.
Delete Tag from View Deletes a tag from the specified view.
Delete Tag from Workbook Deletes a tag from the specified workbook.
Delete Workbook Deletes a workbook.
Download View Crosstab Excel Downloads an Excel (.xlsx) file containing crosstab data from a view that the user has permission to access in a workbook. If a crosstab is exported from a dashboard, data from only the first view in the dashboard will appear in the .xlsx file.
Download Workbook Downloads a workbook in .twb or .twbx format.
Download Workbook Excel Downloads an Excel (.xlsx) file containing crosstab data from a view that the user has permission to access in a workbook. If a crosstab is exported from a dashboard, data from only the first view in the dashboard will appear in the .xlsx file.
Download Workbook PDF Downloads a .pdf containing images of the sheets that the user has permission to view in a workbook.
Download Workbook PowerPoint Downloads a PowerPoint (.pptx) file containing slides with images of the sheets that the user has permission to view in a workbook.
Download Workbook Revision Downloads a specific version of a workbook in .twb or .twbx format.
Get Recommendations for Views Gets a list of views that are recommended for a user.
Get View Gets the details of a specific view.
Get View by Path Gets the details of all views in a site with a specified name.
Get Workbook Downgrade Info Returns a list of the features that would be impacted, and the severity of the impact, when a workbook is exported as a downgraded version (for instance, exporting a v2019.3 workbook to a v10.5 version).
Get Workbook Revisions Returns a list of revision information (history) for the specified workbook.
Hide a Recommendation for a View Hides a view from being recommended by the server by adding it to a list of views that are dismissed for a user.
Publish Workbook Publishes a workbook on the specified site.
Query View Data Returns a specified view rendered as data in comma-separated-value (CSV) format.
Query View Image Returns an image of the specified view.
Query View PDF Returns a specified view rendered as a .pdf file.
Query View Preview Image Returns the thumbnail image for the specified view.
Query Views for Site Returns all the views for the specified site, optionally including usage statistics.
Query Views for Workbook Returns all the views for the specified workbook, optionally including usage statistics.
Query Workbook Returns information about the specified workbook, including information about views and tags.
Query Workbook Connections Returns a list of data connections for the specific workbook.
Query Workbook Preview Image Returns the thumbnail image as a PNG file for the specified workbook.
Query Workbooks for Site Returns the workbooks on a site.
Query Workbooks for User Returns the workbooks that the specified user owns in addition to those that the user has Read (view) permissions for.
Unhide a Recommendation for a View Unhides a view from being recommended by the server by removing it from the list of views that are dimissed for a user.
Update Workbook Modifies an existing workbook, allowing you to change the owner or project that the workbook belongs to and whether the workbook shows views in tabs.
Update Workbook Connection Updates the server address, port, username, or password for the specified workbook connection.
Update Workbook Now Refreshes the specified workbook.

API Method Details

The following content describes each endpoint in the Tableau REST API surface. Use the alphabetically sorted list of methods on the right, or ctrl/cmd-f to go directly to keywords you have in mind.

Add analytics extension connection to site

Adds a connection to an external service for analytics extensions on this site. Permissions - This method can be called by site and server administrators.

POST {server}/api/-/settings/site/extensions/analytics/connections

view details

Add Data Quality Warning

Create and apply a data quality warning to a database, table, published data source, or flow.

Only one data quality warning can be applied to the asset. Adding a data quality warning to the asset that already has one causes an error.

This method is available if your Tableau Online site or Tableau Server is licensed with the Data Management Add-on.

URI

POST api/api-version/sites/site-id/dataQualityWarnings/content-type/content-luid

Parameter Values

api-version The version of the API to use, such as 3.13. For more information, see REST API and Resource Versions.
site-id The unique ID of the site asset.
content-type The type of asset that the data quality warning is being attached to. To specify the type, use:
  • database
  • table
  • datasource
  • flow

These values are not case sensitive.

content-luid The unique ID of the asset (database, table, published data source, or flow). This is the same as the content ID.

Request Body

<tsRequest>
  <dataQualityWarning type="type" isActive="state" message="message" isSevere="severity"/>
</tsRequest>

Attribute Values

Any combination of attributes inside the <dataQualityWarning> element is valid, but the data quality warning type is required. If the data quality warning type is not included, an error is thrown.

type

Type of data quality warning to apply to the asset. To specify the type, use one of the following values:

  • DEPRECATED
  • WARNING
  • STALE
  • SENSITIVE_DATA
  • MAINTENANCE

These values are case sensitive.

state

(Optional) Controls whether the data quality warning displays. Value can be "true" or "false". If the state is not specified, the data quality warning is set to "true" and is visible by default. For more information about data quality warnings, see "Set a Data Quality Warning" in the Server Help or Online Help.

message A required custom message to accompany the data quality warning.
severity (Optional) Enables high visibility for the data quality warning when set to "true". Value can be "true" or "false". For more information, see "Set high visibility for data quality warning" in the Server Help or Online Help.

Permissions

If Tableau Server or Tableau Online is licensed through the Data Management Add-on, the following users have permissions to add the data quality warning:

  • Tableau Server admins or Tableau Online site admins
  • Authorized users who have been granted explicit permission to edit or "Write" to the asset metadata

Response Code

201

Response Body

Example response:

<tsResponse>
   <dataQualityWarning id="1c8ebdfc-270a-4414-812c-3306a1c95e07" userDisplayName="Steve Nguyen"
	contentId="0d7465f2-4989-417e-b88d-f787359edc63" contentType="DATABASE" message="Delayed"
	type="WARNING" isActive="true" createdAt="2020-10-08T00:00:35Z" isSevere="false">
	<site id="a946d998-2ead-4894-bb50-1054a91dcab3"/>
	<owner id="cdfe8548-84c8-418e-9b33-2c0728b1234a"/>
   </dataQualityWarning>
</tsResponse>     

Version

Version 3.5 and later. For more information, see REST API and Resource Versions.

Errors

HTTP status error Code Condition Details
400 400000 Bad request The content of the request body is missing or incomplete, or contains malformed XML.
400 400108 Generic add data quality warning error The data quality warning could not be added for some other reason than those specified in this table.
400 400109 Bad request The request body is missing the data quality warning type.
401 401000 Unauthorized access No authorization credentials were provided.
401 401002 Unauthorized access Invalid authorization credentials were provided.
403 403004 Unauthorized operation Insufficient permissions to perform the operation.
404 404000 Resource not found The site ID in the URI doesn't correspond to an existing site.
404 404029 Content not found The requested asset could not be found.
409 409004 Invalid parameter One or more values in the request body are invalid.

Add (or Update) Data Quality Certifications

Create or update one or more data quality certifications for different content and asset items.

A content or asset item can only have up to one data quality certification applied to it. Adding a data quality certification to an item that already has one will update the data quality certification with the latest specified values.

This method is available if your Tableau Online site or Tableau Server is licensed with the Data Management Add-on.

URI

POST api/api-version/sites/site-id/dataQualityCertifications

Parameter Values

api-version The version of the API to use, such as 3.13. For more information, see REST API and Resource Versions.
site-id The unique ID of the site asset.

Request Body

<tsRequest>
  <contentList>
	<content contentType="content" id="database-id" />
	<content contentType="content" id="table-id" />
	<content contentType="content" id="datasource-id" />
  </contentList>
  <dataQualityIndicator type="content" message="message"
	active="state" elevated="severity" />
</tsRequest> 

Attribute Values

Any combination of attributes inside the <dataQualityIndicator> element is valid, however type and message attributes are required.

content

The type of content or asset the data quality warning is attached to. To specify type, use one of the following values:

  • database
  • table
  • datasource
database-id The unique ID of the database asset.
table-id The unique ID of the table asset.
datasource-id The unique ID of the data source content.
type

Use the following value to apply a data quality certification: CERTIFIED.

message A custom message to accompany the data quality certification.
state (Optional) Controls whether the data quality certification displays. Value can be "true" or "false". If the state is not specified, the data quality certification is set to "true" and is visible by default.
severity (Optional) Enables high visibility for when the data quality certification is set to "true". Value can be "true" or "false". If the severity is not specified, the data quality certification is set to "false." This setting is available only through the REST API.

Permissions

If Tableau Server or Tableau Online is licensed through the Data Management Add-on, the following users have permissions to add or update data quality certifications:

  • Tableau Server admins or Tableau Online site admins
  • Authorized users who have been granted explicit permission to edit or "Write" to the asset metadata

Response Code

201

Response Body

Example response

<tsRequest>
  <dataQualityIndicatorList>
	<dataQualityIndicator id="8f58aa47-7313-4504-8537-52d869552e18"
	    userDisplayName="Mark Nguyen" contentId="7cfd2ac8-a934-4aa8-bf24-96bff08a019c" contentType="DATABASE" message="Marketing approved" type="CERTIFIED" active="true" createdAt="2021-09-26T21:34:46Z" updatedAt="2021-09-26T21:34:46Z" elevated="true">
	  <site id="1e4b3aa0-b48a-4b8e-9bdf-74b7596b9f0a" />
	  <owner id="adcc51d7-8558-4099-9f87-dc1a1615d297" />
	</dataQualityIndicator>
	<dataQualityIndicator id="c8f0b332-a1c1-48f1-b650-86f342ab937f"
	    userDisplayName="Mark Nguyen" contentId="f6dcfd24-7c65-40f4-a3f3-c29f91b7731e" contentType="DATASOURCE" message="Marketing approved" type="CERTIFIED" active="true" createdAt="2021-09-26T21:34:46Z" updatedAt="2021-09-26T21:34:46Z" elevated="true">
	  <site id="1e4b3aa0-b48a-4b8e-9bdf-74b7596b9f0a" />
	  <owner id="adcc51d7-8558-4099-9f87-dc1a1615d297" />
	<dataQualityIndicator>
  </dataQualityIndicatorList>
</tsRequest>    

Version

Version 3.13 and later. For more information, see REST API and Resource Versions.

Errors

HTTP status error Code Condition Details
400 400108 Generic data quality certification error The data quality certification could not be added for some reason other than those specified in this table.
403 403004 Unauthorized operation Insufficient permissions to perform the operation.
404 404029 Content not found The content does not exist.
409 409004 Invalid parameter One or more values in the request body are invalid.

Add Data Source Permissions

Adds permissions to the specified data source for a Tableau Server user or group. You can specify multiple sets of permissions using one call.

If a specified permission has already been granted or denied for a given user or group, the system ignores it.

If the request body includes a child workbook or <project> element, the request is invalid.

URI

PUT /api/api-version/sites/site-id/datasources/datasource-id/permissions

Parameter Values

api-version The version of the API to use, such as 3.13. For more information, see REST API and Resource Versions.
site-id The ID of the site that contains the data source.
datasource-id The ID of the data source to set permissions for.

Request Body

<tsRequest>
  <permissions>
    <datasource id="datasource-id" />
    <granteeCapabilities>
      <user id="user-id" />
      <capabilities>
        <capability name="capability-name" mode="capability-mode" />
        ... additional capabilities ...
      </capabilities>
    </granteeCapabilities>
    <granteeCapabilities>
      <group id="group-id" />
      <capabilities>
        <capability name="capability-name" mode="capability-mode" />
        ... additional capabilities ...
      </capabilities>
    </granteeCapabilities>
    ... additional grantee capability sets ...
  </permissions>
</tsRequest>
        

Attribute Values

datasource-id The <datasource> element is not required, but can be included for compatibility with earlier versions of the REST API. If the <datasource> element is included, the datasource-id value must match the data source ID in the URI. Any other attributes in the <datasource> element are ignored.
user-id The ID (not name) of the user to add permissions for.
group-id The ID (not name) of the group to add permissions for.
capability-name The capability to assign. For valid capabilities for a data source project are ChangePermissions, Connect, Delete, ExportXml, Read (view), and Write.

For more information, see Permissions.

capability-mode Allow to allow the capability, or Deny to deny it. This value is case sensitive.

Permissions

Tableau Server users who are not server administrators or site administrators can add permissions only to a data source for which they have ChangePermissions permission (either explicitly or implicitly).

Response Code

200

Response Body

<tsResponse version-and-namespace-settings>
  <permissions>
    <datasource id="datasource-id" />
    <granteeCapabilities>
      <user id="user-id" />
      <capabilities>
        <capability name="capability" mode="Allow-or-Deny" />
        <capability name="capability" mode="Allow-or-Deny" />
        ... additional capabilities ...
      </capabilities>
    </granteeCapabilities>
    <granteeCapabilities>
      <group id="group-id" />
      <capabilities>
        <capability name="capability" mode="Allow-or-Deny" />
        <capability name="capability" mode="Allow-or-Deny" />
        ... additional capabilities ...
      </capabilities>
    </granteeCapabilities>
    ... additional grantee capability sets ...
  </permissions>
</tsResponse>
        

Version

Version 2.0 and later. For more information, see REST API and Resource Versions.

Errors

HTTP status error Code Condition Details
400 400000 Bad request The content of the request body is missing or incomplete, or contains malformed XML.
400 400009 Invalid capability The specified capability is invalid for a data source. Valid capabilities for a data source are ChangePermissions, Connect, Delete, ExportXml, Read, and Write.
403 403004 No permissions to set permissions. A user attempted to add permissions to a data source, but the caller doesn't have permission to set permissions on the data source.
404 404000 Site not found The specified site doesn't correspond to an existing site.
404 404002 User not found The user specified in the request body doesn't correspond to an existing user.
404 404004 Data source not found The specified data source doesn't correspond to an existing data source.
404 404012 Group not found The group specified in the request body doesn't correspond to an existing group.
404 404013 Capability not found A capability specified in the request body doesn't correspond to a defined capability. This can apply to either an invalid capability name or to a capability other than Allow or Deny for any mode value.
405 405000 Invalid request method Request type was not PUT.

For more information, see Handling Errors.

Add Data Source to Favorites

Adds the specified data source to the user's favorites.

If the user already has the data source listed as a favorite with the same label, the operation has no effect. If the label differs, the original favorite is overwritten.

URI

PUT /api/api-version/sites/site-id/favorites/user-id

Parameter Values

api-version The version of the API to use, such as 3.13. For more information, see REST API and Resource Versions.
site-id The ID of the site that contains the data source.
user-id The ID of the user to add the favorite for.

Request Body

<tsRequest>
  <favorite label="favorite-label">
    <datasource id="datasource-id" />
  </favorite>
</tsRequest>
        

Attribute Values

favorite-label A label to assign to the favorite. This value is displayed when you search for favorites on the server.
datasource-id The ID of the data source to add as a favorite.

Permissions

Tableau Server users who are not server administrators or site administrators can call this method only if they have Read (view) permissions on the data source (either explicitly or implicitly).

Response Code

200

Response Body

<tsResponse>
  <favorites>
    <favorite label="favorite-label">
     <datasource id="datasource-id" />
    </favorite>
    <favorite label="favorite-label">
     <datasource id="datasource-id" />
    </favorite>
    ... additional favorites ...
  </favorites>
</tsResponse>
        

Version

Version 2.3 and later. For more information, see REST API and Resource Versions.

Errors

HTTP status error Code Condition Details
400 400000 Bad request The content of the request body is missing or incomplete, or contains malformed XML.
400 400005 Invalid label The favorite label is empty or consists of only white space characters.
403 403004 Forbidden favorites access A non-administrator user called this method but doesn't have permission to add a data source to the specified user's favorites. This will always be the case when the user ID in the URI represents a different user than a non-administrator user who is calling the method.
404 404000 Site not found The site ID in the URI doesn't correspond to an existing site.
404 404002 User not found The user ID in the URI doesn't correspond to an existing user.
404 404011 Data source not found The data source ID in the request body doesn't correspond to an existing data source.
405 405000 Invalid request method Request type was not PUT.
409 409007 Label conflict There is already a favorite with the same label for a different data source in the specified user's favorites.

For more information, see Handling Errors.

Add Data Source to Schedule

Adds a task to refresh a data source to an existing schedule. This method is not available for Tableau Online.

URI

PUT /api/api-version/sites/site-id/schedules/schedule-id/datasources

Parameter Values

api-version The version of the API to use, such as 3.13. For more information, see REST API and Resource Versions.
site-id The ID of the site that contains the view.
schedule-id The ID of the schedule that you are associating with the data source.

Request Body

<tsRequest>
  <task>
    <extractRefresh>
      <datasource id="datasource-id" />
    </extractRefresh>
  </task>
</tsRequest>
        

Attribute Values

datasource-id The ID of the data source to add to the schedule.

Permissions

Tableau Server users who are not server administrators or site administrators can only add a data source to a schedule if they own the data source, or are the project leader for the project that contains the data source.

Response Code

200

Response Body

<tsResponse>
  <task>
    <extractRefresh>
      <schedule id="schedule-id" />
      <datasource id="datasource-id" />
    </extractRefresh>
  </task>
</tsResponse>
        

Version

Version 2.8 and later. For more information, see REST API and Resource Versions.

Errors

HTTP status error Code Condition Details
400 400000 Bad Request The content of the request body is missing or incomplete, or contains malformed XML.
401 401002 Unauthorized Access The authentication token provided in the request header was invalid or has expired.
403 403032 Update Forbidden A non-administrator user called this method, but the caller doesn't have sufficient permissions.
404 404000 Site not found The site ID in the URI is unknown.
404 404004 Resource not found The data source ID in the request body is unknown.
405 405000 Invalid request method Request type was not PUT.
500 500000 Internal Server Error The schedule ID in the URI is unknown.

For more information, see Handling Errors.

Example

curl "http://MY-SERVER/api/3.13/sites/1edc53ac-e247-4870-9fd3-6fad0ce5f84d/schedules/9a4ebbab-9ec8-487a-9b48-47fa81d6077a/datasources" -X PUT -H "X-Tableau-Auth:12ab34cd56ef78ab90cd12ef34ab56cd" –d @add-to-schedule.xml

Content of add-to-schedule.xml:

<tsRequest>
  <task>
    <extractRefresh>
      <datasource id="89a82d78-664f-45a1-8256-d4d2961a070b" />
    </extractRefresh>
  </task>
</tsRequest>
						

Example response:

<tsResponse>
  <task>
    <extractRefresh id="9bf8aea0-e3ca-422e-b7ef-d9c4ba6cca45" priority="50" consecutiveFailedCount="0" type="RefreshExtractTask">
      <schedule id="9a4ebbab-9ec8-487a-9b48-47fa81d6077a" name="Weekday early mornings" state="Active" />
      <datasource id="89a82d78-664f-45a1-8256-d4d2961a070b" />
    </extractRefresh>
  </task>
</tsResponse>
							

Add Database Permissions

Add permissions to a database asset. To add permissions, the database asset must be associated with a published data source.

This method is available if your Tableau Online site or Tableau Server is licensed with the Data Management Add-on.

URI

PUT api/api-version/sites/site-id/databases/database-id/permissions

Parameter Values

api-version The version of the API to use, such as 3.13. For more information, see REST API and Resource Versions.
site-id The unique ID of the site asset.
database-id The unique ID of the database asset.

Request Body

<tsRequest>
  <permissions>
    <database id="database-id" />
    <granteeCapabilities>
     	<user id="user-id" />
     	<capabilities>
     	 <capability name="capability-name" mode="capability-mode" />
      	... additional capabilities ...
      </capabilities>
    </granteeCapabilities>
    <granteeCapabilities>
      <group id="group-id" />
      <capabilities>
       <capability name="capability-name" mode="capability-mode" />
       ... additional capabilities ...
       </capabilities>
     </granteeCapabilities>
     <contentPermisions="new-content-permissions" />
  </permissions>
</tsRequest>
    

Attribute Values

database-id The ID (not name) for the database asset you want to add permissions to.
user-id The ID (not name) of the user to add permissions for.
capability-name

The capability to assign. If any capability has been granted or denied for a specified user or group, that capability is ignored. Valid capabilities for a database are:

  • Read (view)
  • Write (edit)
  • ProjectLeader (set permissions)

These values are case sensitive.

capability-mode

Use one of the following capabilities: 

  • Allow
  • Deny

These values are case sensitive.

group-id The ID (not name) of the group to add permissions for.
new-content-permissions

(Optional) The new permissions setting for the database. You can specify one of the following:

  • LockedToDatabase to lock permissions so that users cannot overwrite the default permissions set for the database asset.
  • ManagedByOwner to allow users to manage permissions for the database asset used by the content that they own.

The default permissions setting is ManagedByOwner. These values are case sensitive.

Permissions

If Tableau Server or Tableau Online is licensed through the Data Management Add-on, the following authorized users have permissions to add database asset permissions:

  • Tableau Server admins or Tableau Online site admins
  • Authorized users who have been granted explicit permission to set or "ChangePermissions" to the asset metadata

Response Code

200

Response Body

Example response

<tsResponse xmlns="http://tableau.com/api" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://tableau.com/api http://tableau.com/api/ts-api-3.5.xsd">
  <permissions>
	<database id="e8d4aa9f-3d1a-4b49-8d6d-27f113cbd25e" name="oracle.test.tsi.lan:1521"/>
	<granteeCapabilities>
	  <user id="6265b714-7533-465d-b6db-6d0be92bfd07"/>
	  <capabilities>
		<capability name="Read" mode="Allow"/>
	  </capabilities>
	</granteeCapabilities>
  </permissions>
</tsResponse>
      

Version

Version 3.5 and later. For more information, see REST API and Resource Versions.

Errors

HTTP status error Code Condition Details
400 400000 Bad request The content of the request body is missing or incomplete, or contains malformed XML.
400 400120 Bad request Permissions could not be added because support for explicit permissions is available for database assets associated with published data sources only.
401 401000 Unauthorized access No authorization credentials were provided.
401 401002 Unauthorized access Invalid authorization credentials were provided.
404 404000 Resource not found The site ID in the URI doesn't correspond to an existing site.
404 404031 Database not found The requested database could not be found.
405 405000 Invalid request method Request type was not PUT.
409 409045 Database error An unknown database asset error occurred.
409 409050 Database update error An unknown error occurred and the database asset could not be updated.
409 409051 Database update forbidden A user without "write" permissions to the database asset attempted an update.

Add Default Database Permissions

Applying default permissions to a database functions as a permissions template for the database's children table assets. How default permissions are enforced depends on whether the database is locked or unlocked.

  • Locked to the database: If the permissions on a database are locked or Locked to the database, existing child table assets and new child table assets that get indexed by Catalog will inherit the default permissions applied to the parent database asset. Note: If the database is locked, explicit permissions cannot be made for individual tables.

  • Managed by the owner: If the permissions on a database are unlocked or Managed by the owner, only new child table assets that get indexed by Catalog will inherit the default permissions applied to the parent database asset. Note: If the database is unlocked, explicit permissions for the table can be made in a separate request.

This method is available if your Tableau Online site or Tableau Server is licensed with the Data Management Add-on.

URI

PUT /api/api-version/sites/site-id/databases/database-id/default-permissions/tables

Parameter Values

api-version The version of the API to use, such as 3.13. For more information, see REST API and Resource Versions.
site-id The unique ID of the site asset.
database-id The unique ID of the database asset to set default permissions for.

Request Body

<tsRequest>
  <permissions>
	<granteeCapabilities>
	  <user id="user-id" />
      <capabilities>
	    <capability name="capability-name" mode="capability-mode" />
	    < !-- ... additional capabilities ... -->
	  </capabilities>
	</granteeCapabilities>
	<granteeCapabilities>
      <group id="group-id" />
	  <capabilities>
		<capability name="capability-name" mode="capability-mode" />
		< !-- ...  additional capabilities ... -->
	  </capabilities>
	</granteeCapabilities>
    < !-- ... additional grantee capability sets ...  -->
  </permissions>
</tsRequest>
      

Attribute Values

user-id The ID (not name) of the user to add default permissions for.
group-id The ID (not name) of the group to add permissions for.
capability-name

The capability to assign. If any capability has been granted or denied for a specified user or group, that capability is ignored. Valid capabilities for a databases are the following:

  • Read (view)
  • Write (edit)
  • ChangePermissions (manage permissions)

These values are case sensitive.

capability-mode

Use one of the following capabilities:

  • Allow
  • Deny

These values are case sensitive.

Permissions

If Tableau Server or Tableau Online is licensed through the Data Management Add-on, the following authorized users set default permissions for the database asset:

  • Tableau Server admins or Tableau Online site admins
  • Authorized users who have been granted explicit permission to set or "ChangePermissions" to the asset metadata

Response Code

200

Response Body

<tsResponse xmlns="http://tableau.com/api" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://tableau.com/api http://tableau.com/api/ts-api-3.5.xsd">
  <permissions>
	<database id="e8d4aa9f-3d1a-4b49-8d6d-27f113cbd25e" name="oracle.test.tsi.lan:1521"/>
	<granteeCapabilities>
	  <user id="6265b714-7533-465d-b6db-6d0be92bfd07"/>
	  <capabilities>
		<capability name="Read" mode="Allow"/>
	  </capabilities>
	</granteeCapabilities>
  </permissions>
</tsResponse>
      

Version

Version 3.5 and later. For more information, see REST API and Resource Versions.

Errors

HTTP status error Code Condition Details
400 400000 Bad request The content of the request body is missing or incomplete, or contains malformed XML.
403 403004 Permissions setting forbidden A non-administrator user called this method but doesn't have permission to add permissions on the project.
403 403114 Permissions setting forbidden Default permissions cannot be added because the database asset is locked.
404 404000 Site not found The site ID in the URI doesn't correspond to an existing site.
404 404003 Resource not found The database ID in the URI doesn't correspond to a database asset on the site.
404 404002 User not found A user ID in the request body as the grantee doesn't correspond to an existing user.
404 404012 Group not found A group ID in the request body doesn't correspond to an existing group.
404 404013 Capability not found The capability in the request body doesn't correspond to a defined capability. This can apply to either an invalid capability name or to a capability other than Allow or Deny for any mode value.
405 405000 Invalid request method Request type was not PUT.

Add Default Permissions

Adds default permission capabilities granted to a user or group, for metric, flow, workbook, data source, data role, or lense resources in a project. After adding default permissions, resources of the type you specify that are added to a project will have those capabilities granted for a group or user. If permissions are locked to the project(Link opens in a new window), then the same is true for all existing child content of the project. For more information, see Permissions(Link opens in a new window).

Content owners can override default permissions for their content, but only if project permissions have not been locked. Project permissions can be locked for a new project when you call Create Project or for an existing project by calling Update Project. For more information, see Lock Content Permissions to the Project(Link opens in a new window).

URI

PUT /api/api-version/sites/site-id/projects/project-id/default-permissions/workbooks

PUT /api/api-version/sites/site-id/projects/project-id/default-permissions/datasources

PUT /api/api-version/sites/site-id/projects/project-id/default-permissions/flows

PUT /api/api-version/sites/site-id/projects/project-id/default-permissions/metrics

PUT /api/api-version/sites/site-id/projects/project-id/default-permissions/dataroles

PUT /api/api-version/sites/site-id/projects/project-id/default-permissions/lenses

Parameter Values

api-version The version of the API to use, such as 3.13. For more information, see REST API and Resource Versions.
site-id The ID of the site that contains the project.
project-id The ID of the project to set default permissions for.

Request Body

<tsRequest>
  <permissions>
	<granteeCapabilities>
	  <user id="user-id" />
      <capabilities>
	    <capability name="capability-name" mode="capability-mode" />
	    < !-- ... additional capabilities ... -->
	  </capabilities>
	</granteeCapabilities>
	<granteeCapabilities>
      <group id="group-id" />
	  <capabilities>
		<capability name="capability-name" mode="capability-mode" />
		< !-- ...  additional capabilities ... -->
	  </capabilities>
	</granteeCapabilities>
    < !-- ... additional grantee capability sets ...  -->
  </permissions>
</tsRequest>
        

Attribute Values

user-id The ID (not name) of the user to add default permissions for.
group-id The ID (not name) of the group to add permissions for.
capability-name The capability to assign. Valid capabilities for a workbook are

AddComment, ChangeHierarchy, ChangePermissions, Delete, ExportData, ExportImage, ExportXml, Filter, Read (view), ShareView, ViewComments, ViewUnderlyingData, WebAuthoring, and Write.

Valid capabilities for a data source are ChangePermissions, Connect, Delete, ExportXml, Read (view), and Write.

For more information, see Permissions.

capability-mode Allow to allow the capability, or Deny to deny it. This value is case sensitive.

Permissions

Tableau Server users who are not server administrators can add permissions defaults for a project only if they have the ProjectLeader permission for that project (either explicitly or implicitly).

Response Code

200

Response Body

<tsResponse xmlns="http://tableau.com/api" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://tableau.com/api http://tableau.com/api/ts-api-3.5.xsd">
  <permissions>
	<database id="e8d4aa9f-3d1a-4b49-8d6d-27f113cbd25e" name="oracle.test.tsi.lan:1521"/>
	<granteeCapabilities>
	  <user id="6265b714-7533-465d-b6db-6d0be92bfd07"/>
	  <capabilities>
		<capability name="Read" mode="Allow"/>
		</capabilities>
	</granteeCapabilities>
  </permissions>
</tsResponse>
        

Version

Version 2.1 and later. For more information, see REST API and Resource Versions.

Errors

HTTP status error Code Condition Details
400 400000 Bad request The content of the request body is missing or incomplete, or contains malformed XML.
400 400009 Invalid capability The capability in the URI is invalid for a data source.

Valid capabilities for a workbook are AddComment, ChangeHierarchy, ChangePermissions, Delete, ExportData, ExportImage, ExportXml, Filter, Read (view), ShareView, ViewComments, ViewUnderlyingData, WebAuthoring, and Write.

Valid capabilities for a data source are ChangePermissions, Connect, Delete, ExportXml, Read (view), and Write.

400 400042 Malformed permissions qualifier The request body includes a <workbook> or <datasource> element.
403 403004 Permissions setting forbidden A non-administrator user called this method but doesn't have permission to add permissions on the project.
404 404000 Site not found The site ID in the URI doesn't correspond to an existing site.
404 404002 User not found A user ID in the request body as the grantee doesn't correspond to an existing user.
404 404005 Project not found The project ID in the URI doesn't correspond to an existing project.
404 404009 Project ID mismatch A project ID specified in the URI does not match the project ID specified in the request body. (You do not have to specify a project ID in the request body.)
404 404012 Group not found A group ID in the request body doesn't correspond to an existing group.
404 404013 Capability not found The capability in the request body doesn't correspond to a defined capability. This can apply to either an invalid capability name or to a capability other than Allow or Deny for any mode value.
405 405000 Invalid request method Request type was not PUT.

For more information, see Handling Errors.

Add Flow Permissions

Adds permissions to the specified flow for a Tableau Server user or group. You can specify multiple sets of permissions using one call.

URI

PUT /api/api-version/sites/site-id/flows/flow-id/permissions

Parameter Values

api-version The version of the API to use, such as 3.13. For more information, see REST API and Resource Versions.
site-id The ID of the site that contains the flow.
datasource-id The ID of the flow.

Request Body

<tsRequest>
  <permissions>
    <flow id="flow-id" />
    <granteeCapabilities>
      <user id="user-id" />
      <capabilities>
        <capability name="capability-name" mode="capability-mode" />
        ... additional capabilities ...
      </capabilities>
    </granteeCapabilities>
    <granteeCapabilities>
      <group id="group-id" />
      <capabilities>
        <capability name="capability-name" mode="capability-mode" />
        ... additional capabilities ...
      </capabilities>
    </granteeCapabilities>
    ... additional grantee capability sets ...
  </permissions>
</tsRequest>
        

Attribute Values

flow-id The flow-id value for the flow you want to add permissions to.
user-id The ID (not name) of the user to add permissions for.
group-id The ID (not name) of the group to add permissions for.
capability-name The capability to assign. If any capability has already been granted or denied for a specified user or group, that capability is ignored. Valid capabilities for a flow are ChangeHierarchy, ChangePermissions, Delete, Execute, ExportXml (Download), Read (view), and Write.

For more information, see Permissions.

Permissions

Tableau Server users who are not server administrators or site administrators can call this method only if they have permission to set permissions on the flow (either explicitly or implicitly).

Response Code

200

Response Body

<tsResponse>
    <permissions>
        <flow id="8359f0c5-4b98-4ca4-a7e5-38e4261e88a2" name="Flow1">
            <owner id="8f735728-7484-40d1-89d1-41f09824536b"/>
        </flow>
        <granteeCapabilities>
            <group id="9de5cc1a-5bb8-4c8e-b2cd-b54e736a7b9f"/>
            <capabilities>
                <capability name="Read" mode="Allow"/>
                <capability name="Write" mode="Allow"/>
                <capability name="Delete" mode="Deny"/>
            </capabilities>
        </granteeCapabilities>
        <granteeCapabilities>
            <user id="1f2345678-1234-12d1-12d1-11f234567b"/>
            <capabilities>
                <capability name="Delete" mode="Allow"/>
            </capabilities>
        </granteeCapabilities>
    </permissions>
</tsResponse>
        

Version

Version 3.3 and later. For more information, see REST API and Resource Versions.

Errors

HTTP status error Code Condition Details
400 400000 Bad request The content of the request body is missing or incomplete, or contains malformed XML.
400 400009 Invalid capability The capability in the URI is invalid for a flow. Valid capabilities for a flow are ChangeHierarchy, ChangePermissions, Delete, Execute, ExportXml (Download), Read (view), and Write.
403 403004 Permissions setting forbidden A non-administrator user called this method but doesn't have permission to set permissions on the flow.
404 404000 Site not found The site ID in the URI doesn't correspond to an existing site.
404 404002 User not found A user ID in the request body doesn't correspond to an existing user.
404 404027 Flow not found The flow ID in the URI doesn't correspond to an existing flow.
404 404012 Group not found A group ID in the request body doesn't correspond to an existing group.
404 404013 Capability not found The specified capability doesn't correspond to a defined capability. This can apply to either an invalid capability name or a capability other than Allow or Deny for any mode value.
405 405000 Invalid request method Request type was not PUT.

For more information, see Handling Errors.

Add Flow Task to Schedule

Adds a task to run a flow to an existing schedule.

Note: This method is unavailable if you do not have the Data Management Add-on or Tableau Prep Conductor is disabled for your site.

URI

PUT /api/api-version/sites/site-id/schedules/schedule-id/flows

Parameter Values

api-version The version of the API to use, such as 3.13. For more information, see REST API and Resource Versions.
site-id The ID of the site that contains the flow.
schedule-id The ID of the schedule that you are associating with the flow. The schedule that you are adding to must have Flow as the schedule type.

Request Body

<tsRequest>
  <task>
    <flowRun>
       <flow id="flow-id"/>
    </flowRun>
  </task>
</tsRequest>
        

Attribute Values

flow-id The ID of the flow to add to the schedule. This will include all the output steps in the flow and any output steps created in the future.

Permissions

Tableau Server users who are not server administrators or site administrators can only add a flow to a schedule if they own the flow, or are the project leader for the project that contains the workbook.

Response Code

200

Version

Version 3.3 and later. For more information, see REST API and Resource Versions.

Errors

HTTP status error Code Condition Details
400 400000 Bad request The content of the request body is missing or incomplete, or contains malformed XML.
401 401002 Unauthorized Access The authentication token provided in the request header was invalid or has expired.
403 403098 Update Forbidden A non-administrator user called this method, but the caller doesn't have sufficient permissions.
404 404000 Site not found The site ID in the URI is unknown.
404 404002 User not found A user ID in the request body doesn't correspond to an existing user.
404 404027 Flow not found The flow ID in the URI doesn't correspond to an existing flow.
405 405000 Invalid request method Request type was not PUT.

For more information, see Handling Errors.

Example

curl "http://MY-SERVER/api/3.13/sites/1edc53ac-e247-4870-9fd3-6fad0ce5f84d/schedules/9a4ebbab-9ec8-487a-9b48-47fa81d6077a/flows" -X PUT -H "X-Tableau-Auth:12ab34cd56ef78ab90cd12ef34ab56cd" –d @add-to-schedule.xml"

Content of add-to-schedule.xml:

<tsRequest>
  <task>
    <flowRun>
       <flow id="5ab9cd53-e17f-45gh-804i-4914jk39r29z"/>
    </flowRun>
  </task>
</tsRequest>

Example response:

<tsResponse version-and-namespace-settings>
    <task>
        <flowRun id="8a78c68e-37ad-4b21-80fc-e67e2ab55279" priority="50" consecutiveFailedCount="0" type="RunFlowTask">
            <schedule id="99e8841e-8527-4d09-89b8-71d9872634df" name="demo" state="Active" priority="50" createdAt="2018-11-15T17:14:45Z" updatedAt="2018-11-19T23:06:56Z" type="Flow" frequency="Hourly" nextRunAt="2018-11-20T00:00:00Z"/>
            <flow id="09942c88-99d5-4669-aa62-07560fc4b201" name="CoffeeChain"/>
        </flowRun>
    </task>
</tsResponse>

Add Flow to Favorites

Adds the specified flow to the user's favorites.

If the user already has the flow listed as a favorite with the same label, the operation has no effect. If the label differs, the original favorite is overwritten.

URI

PUT /api/api-version/sites/site-id/favorites/user-id

Parameter Values

api-version The version of the API to use, such as 3.13. For more information, see REST API and Resource Versions.
site-id The ID of the site that contains the data source.
user-id The ID of the user to add the favorite for.

Request Body

<tsRequest>
  <favorite label="favorite-label">
    <flow id="flow-id" />
  </favorite>
</tsRequest>
        

Attribute Values

favorite-label A label to assign to the favorite. This value is displayed when you search for favorites on the server.
flow-id The ID of the flow to add as a favorite.

Permissions

Tableau Server users who are not server administrators or site administrators can call this method only if they have Read (view) permissions on the data source (either explicitly or implicitly).

Response Code

200

Response Body

<tsResponse>
  <favorites>
    <favorite label="favorite-label">
     <flow id="flow-id" />
    </favorite>
    <favorite label="favorite-label">
     <flow id="flow-id" />
    </favorite>
    ... additional favorites ...
  </favorites>
</tsResponse>
        

Version

Version 3.3 and later. For more information, see REST API and Resource Versions.

Errors

HTTP status error Code Condition Details
400 400000 Bad request The content of the request body is missing or incomplete, or contains malformed XML.
400 400005 Invalid label The favorite label is empty or consists of only white space characters.
403 403004 Forbidden favorites access A non-administrator user called this method but doesn't have permission to add a data source to the specified user's favorites. This will always be the case when the user ID in the URI represents a different user than a non-administrator user who is calling the method.
404 404000 Site not found The site ID in the URI doesn't correspond to an existing site.
404 404002 User not found The user ID in the URI doesn't correspond to an existing user.
404 404027 Flow not found The flow ID in the URI doesn't correspond to an existing flow.
405 405000 Invalid request method Request type was not PUT.
409 409007 Label conflict There is already a favorite with the same label for a different data source in the specified user's favorites.

For more information, see Handling Errors.

Add Project Permissions

Adds permissions to the specified project for a Tableau Server user or group. You can specify multiple sets of permissions using one call.

If the request body includes a child datasource or <project> element, the request is invalid.

URI

PUT /api/api-version/sites/site-id/projects/project-id/permissions

Parameter Values

api-version The version of the API to use, such as 3.13. For more information, see REST API and Resource Versions.
site-id The ID of the site that contains the project.
project-id The ID of the project to set permissions for.

Request Body

<tsRequest>
  <permissions>
    <granteeCapabilities>
      <user id="user-id" />
      <capabilities>
        <capability name="capability-name" mode="capability-mode" />
        ... additional capabilities ...
      </capabilities>
    </granteeCapabilities>
    <granteeCapabilities>
      <group id="group-id" />
      <capabilities>
        <capability name="capability-name" mode="capability-mode" />
        ... additional capabilities ...
      </capabilities>
    </granteeCapabilities>
    ... additional grantee capability sets ...
  </permissions>
</tsRequest>
        

Attribute Values

user-id The ID (not name) of the user to add permissions for.
group-id The ID (not name) of the group to add permissions for.
capability-name The capability to assign permissions to. In Tableau Server 10.0, the valid capabilities for a project are ProjectLeader, Read (view), and Write.

For more information, see Permissions.

capability-mode Allow to allow the capability, or Deny to deny it. This value is case sensitive.

Permissions

Tableau Server users who are not server administrators or site administrators can add permissions for a project only if they have ChangePermissions (version 2.0) or ProjectLeader (version 2.1) permission for that project (either explicitly or implicitly).

Response Code

200

Response Body

<tsResponse>
  <permissions>
    <project id="project-id" name="project-name" />
      <owner id="project-owner-id" />
    </project>
    <granteeCapabilities>
      <user id="user-id" />
      <capabilities>
        <capability name="capability" mode="Allow-or-Deny" />
        <capability name="capability" mode="Allow-or-Deny" />
        ... additional capabilities ...
      </capabilities>
    </granteeCapabilities>
    <granteeCapabilities>
      <group id="group-id" />
      <capabilities>
        <capability name="capability" mode="Allow-or-Deny" />
        <capability name="capability" mode="Allow-or-Deny" />
        ... additional capabilities ...
      </capabilities>
    </granteeCapabilities>
    ... additional grantee capability sets ...
  </permissions>
</tsResponse>
        

Version

Version 2.0 and later. For more information, see REST API and Resource Versions.

Errors

HTTP status error Code Condition Details
400 400000 Bad request The content of the request body is missing or incomplete, or contains malformed XML.
400 400009 Invalid capability

The capability specified in the request is not in the list of valid capability names for this method.

The mode of the capability for ProjectLeader cannot be set to Deny.

403 403004 Permissions setting forbidden A non-administrator user called this method but doesn't have permission to add permissions on the project.
404 404000 Site not found The site ID in the URI doesn't correspond to an existing site.
404 404002 User not found A user ID in the request body as the grantee doesn't correspond to an existing user.
404 404005 Project not found The project ID in the URI doesn't correspond to an existing project.
404 404009 Project ID mismatch A project ID specified in the URI does not match the project ID specified in the request body. (You do not have to specify a project ID in the request body.)
404 404012 Group not found A group ID in the request body doesn't correspond to an existing group.
404 404013 Capability not found The capability in the request body doesn't correspond to a defined capability. This can apply to either an invalid capability name or to a capability other than Allow or Deny for any mode value.
405 405000 Invalid request method Request type was not PUT.

For more information, see Handling Errors.

Add Project to Favorites

Adds the specified project to a user's favorites.

If the user already has the project listed as a favorite with the same label, the operation has no effect. If the label differs, the original favorite is overwritten.

URI

PUT /api/api-version/sites/site-id/favorites/user-id

Parameter Values

api-version The version of the API to use, such as 3.13. For more information, see REST API and Resource Versions.
site-id The ID of the site that contains the project.
user-id The ID of the user to add the favorite for.

Request Body

<tsRequest>
  <favorite label="favorite-label">
    <project id="project-id"/>
  </favorite>
</tsRequest>
        

Attribute Values

favorite-label A label to assign to the favorite. This value is displayed when you search for favorites on the server.
project-id The ID (not name) of the project to add as a favorite.

Permissions

Tableau Server users who are not server administrators or site administrators can call this method only if they have permission to add a project to a favorite list (either explicitly or implicitly).

Response Code

200

Response Body

<tsResponse>
  <favorites>
    <favorite label="favorite1-label">
     <project id="project-id" />
    </favorite>
    <favorite label="favorite2-label">
     <project id="project-id" />
    </favorite>
  </favorites>
</tsResponse>

        

Version

Version 3.1 and later. For more information, see REST API and Resource Versions.

Errors

HTTP status error Code Condition Details
400 400000 Bad request The content of the request body is missing or incomplete, or contains malformed XML.
400 400005 Invalid label The favorite label is empty or consists of only white space characters.
403 403004 Access to favorites denied A non-administrator user called this method but doesn't have permission to add a project to the specified user's favorites. This will always be the case when the user ID in the URI represents a different user than a non-administrator user who is calling the method.
404 404000 Site not found The site ID in the URI doesn't correspond to an existing site.
404 404002 User not found The user ID in the URI doesn't correspond to an existing user.
404 404005 Project not found The project ID in the request body doesn't correspond to an existing project.
405 405000 Invalid request method Request type was not PUT.

For more information, see Handling Errors.

Example

curl "http://MY-SERVER/api/3.13/sites/1edc53ac-e247-4870-9fd3-6fad0ce5f84d/favorites/2474164d-8d37-4a4c-abc7-c2070fd25fd5" -X PUT -d @add-project-to-favorites.xml -H "X-Tableau-Auth:12ab34cd56ef78ab90cd12ef34ab56cd"

Content of add-project-to-favorites.xml:

<tsRequest>
  <favorite label="Economic Indicators">
    <project id="1f1e1d1c-2b2a-2f2e-3d3c-3b3a4f4e4d4c" />
  </favorite>
</tsRequest>

Example response:

<tsResponse version-and-namespace-settings>
  <favorites>
    <favorite label="Economic Indicators">
      <project id="1f1e1d1c2-b2a2-f2e3-d3c3-b3a4f4e4d4c"/>
    </favorite>
  </favorites>
</tsResponse>

Add (or Update) Quality Warning Trigger

Create or update one or more quality warning triggers to monitor and display alerts for the following events: refresh failures on extract data sources and flow run failures on flows.

An asset can only have one trigger. Adding a trigger to an asset that already has one will update the trigger with the latest specified values.

Note: An asset can have one trigger and one DQW applied to it at the same time.

This method is available if your Tableau Online site or Tableau Server is licensed with the Data Management Add-on.

URI

Add or update a quality warning trigger

POST api/api-version/sites/site-id/dataQualityTriggers/content-type/contentIds?filter=contentId:in:[content-luid]

Add or update a quality warning trigger for multiple assets

POST api/api-version/sites/site-id/dataQualityTriggers/content-type/contentIds?filter=contentId:in:[content-luid1,content-luid2,content-luid3,...]

Parameter Values

api-version The version of the API to use, such as 3.13. For more information, see REST API and Resource Versions.
site-id The unique ID of the site asset.
content-type

The type of content the quality warning trigger is being applied to. Use one of the following values:

  • datasource
  • flow

These values are not case sensitive.

content-luid The unique ID of the asset. This is the same as the content ID.

Request Body

<tsRequest>
  <dataQualityTrigger type="content" active="status" message="message" severe="severity"/>
</tsRequest>
      

Attribute Values

Any combination of attributes inside the <dataQualityTrigger> element is valid, however type is required.

content

Type of content item to apply the trigger. To specify the type, use one of the following values:

  • EXTRACT_REFRESH
  • FLOW_RUN

These values are not case sensitive.

status

(Optional) Status of the trigger. Values can be "true" or "false". If set to "true", either the extract data source is monitored for refresh failures or the flow is monitored for flow run failures. If a failure occurs, an alert is applied (or replaces an existing one) to either the extract data source or flow. The alert remains there until the next successful refresh or flow run. For more information about quality warning triggers, see "Set a Data Quality Warning" in the Server Help or Online Help.

message (Optional) A custom message to accompany the trigger.
severity (Optional) Enables high visibility for the trigger. Values can be "true" or "false". For more information, see "Set high visibility for data quality warning" in the Server Help or Online Help.

Permissions

If Tableau Server or Tableau Online is licensed through the Data Management Add-on, the following users have permissions to add quality warning triggers:

  • Tableau Server admins or Tableau Online site admins
  • Authorized users who have been granted explicit permission to edit or "Write" to the asset metadata

Response Code

200

Response Body

Example response

<tsResponse>
  <dataQualityTriggerList>
	<dataQualityTrigger id="{trigger-luid}" siteId="{site-luid}"
		userId="{user-luid}" userDisplayName="Joe Nguyen" contentId="{content-luid}"
		contentType="DATASOURCE" message=" This message is specified by the user."
		type="EXTRACT_REFRESH" active="true" createdAt="Wed Sep 22 05:49:52 UTC 2020"
		updatedAt="Wed Sep 22 05:49:52 UTC 2020" severe="false"/>
  </dataQualityTriggerList>
</tsResponse>
      

Version

Version 3.11 and later. For more information, see REST API and Resource Versions.

Errors

HTTP status error Code Condition Details
400 400136 Generic quality warning trigger error The quality warning trigger could not be added or updated for some other reason than those specified below.
403 403004 Unauthorized operation Insufficient permissions to perform the operation.
409 409004 Invalid parameter One or more values in the request body are invalid.

Add Table Permissions

Add permissions to a table asset.

This method is available if your Tableau Online site or Tableau Server is licensed with the Data Management Add-on.

URI

PUT api/api-version/sites/site-id/tables/table-id/permissions

Parameter Values

api-version The version of the API to use, such as 3.13. For more information, see REST API and Resource Versions.
site-id The unique ID of the site asset.
table-id The unique ID of the table asset.

Request Body

<tsRequest>
  <permissions>
    <table id="table-id" />
    <granteeCapabilities>
     <user id="user-id" />
     <capabilities>
      <capability name="capability-name" mode="capability-mode" />
      ... additional capabilities ...
      </capabilities>
    </granteeCapabilities>
    <granteeCapabilities>
     <group id="group-id" />
      <capabilities>
       <capability name="capability-name" mode="capability-mode" />
       ... additional capabilities ...
       </capabilities>
     </granteeCapabilities>
       ... additional grantee capability sets ...
     <contentPermissions="new-content-permissions" />
  </permissions>
</tsRequest>
    

Attribute Values

table-id The ID (not name) for the table asset you want to add permissions to.
user-id The ID (not name) of the user to add permissions for.
capability-name

The capability to assign. If any capability has been granted or denied for a specified user or group, that capability is ignored. Valid capabilities for a database are:

  • Read (view)
  • Write (edit)
  • ProjectLeader (set permissions)

These values are case sensitive.

capability-mode

Use one of the following capabilities:

  • Allow
  • Deny

These values are case sensitive.

group-id The ID (not name) of the group to add permissions for.

Permissions

If Tableau Server or Tableau Online is licensed through the Data Management Add-on, the following users have permissions to add table asset permissions:

  • Tableau Server admins or Tableau Online site admins
  • Authorized users who have been granted explicit permission to set or "ChangePermissions" to the asset metadata

Response Code

200

Response Body

Example response:

<tsResponse xmlns="http://tableau.com/api" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://tableau.com/api http://tableau.com/api/ts-api-3.5.xsd">
  <permissions>
	<table id="d0fe66ae-1407-4338-8520-9489d7ce959c" name="_WarehouseConfig"/>
	<granteeCapabilities>
	  <user id="6265b714-7533-465d-b6db-6d0be92bfd07"/>
	  <capabilities>
		<capability name="Read" mode="Allow"/>
	  </capabilities>
	</granteeCapabilities>
  </permissions>
</tsResponse>
      

Version

Version 3.5 and later. For more information, see REST API and Resource Versions.

Errors

HTTP status error Code Condition Details
400 400000 Bad request The content of the request body is missing or incomplete, or contains malformed XML.
400 400120 Bad request Permissions could not be added because support for explicit permissions is available for table assets associated with published data sources only.
401 401000 Unauthorized access No authorization credentials were provided.
401 401002 Unauthorized access Invalid authorization credentials were provided.
403 403117 Database locked Permissions for the table asset cannot be deleted because the database asset is locked.
404 404000 Resource not found The site ID in the URI doesn't correspond to an existing site.
404 404032 Table not found The requested table asset could not be found.
409 409052 Table error An unknown table asset error occurred.
409 409057 Table update error An unknown error occurred and the table asset could not be updated.
409 409058 Table update forbidden A user without "write" permissions to the table asset attempted an update.

Add Tags to Column

Add one or more tags to a column.

For more information about tags, see Tag Items(Link opens in a new window) in the Tableau User Help.

URI

PUT api/api-version/sites/site-id/columns/column-id/tags

Parameter Values

api-version The version of the API to use, such as 3.13. For more information, see REST API and Resource Versions.
site-id The unique ID of the site asset.
column-id The unique ID of the column asset.

Request Body

<tsRequest>
  <tags>
	<tag label="tag-value1" />
	<tag label="tag-value2" />
  </tags>
</tsRequest>
      

Attribute Values

tag-value1

Keyword text you want to add to the asset.

tag-value2

Keyword text you want to add to the asset.

Permissions

If Tableau Server or Tableau Online is licensed through the Data Management Add-on, the following users have permissions to add tags:

  • Tableau Server admins or Tableau Online site admins
  • Authorized users who have been granted explicit permission to edit or "Write" to the asset metadata

Response Code

200

Response Body

Example response

<tsResponse>
  <tags>
	<tag label="Noteworthy" />
	<tag label="PII" />
  </tags>
</tsResponse>
      

Version

Version 3.9 and later. For more information, see REST API and Resource Versions.

Errors

HTTP status error Code Condition Details
400 400000 Bad request The content of the request body is missing or incomplete, or contains malformed XML.
403 403004 Unauthorized operation Insufficient permissions to perform the operation.
409 409062 Generic column tag error The tag or tags could not be added (or deleted) for some other reason than those specified above.
409 409066 Column not found The column asset does not exist.

Add Tags to Data Source

Adds one or more tags to the specified data source.

URI

PUT /api/api-version/sites/site-id/datasources/datasource-id/tags

Parameter Values

api-version The version of the API to use, such as 3.13. For more information, see REST API and Resource Versions.
site-id The ID of the site that contains the data source.
datasource-id The ID of the data source to add tags to.

Request Body

<tsRequest>
  <tags>
    <tag label="tag" />
    ... additional tags ...
  </tags>
</tsRequest>
        

Attribute Values

datasource-id The data source to add the tag to. If the data source is already tagged with a tag that's included in the request body, those tags are ignored and the data source retains them. If the <tags> element is empty, no new tags are added to the data source.
tag The text of the tag.

Permissions

Tableau Server users who are not server administrators or site administrators can call this method only if they have Read permissions for the data source (either explicitly or implicitly).

Response Code

200

Response Body

<tsResponse>
  <tags>
    <tag label="tag"/>
        ... additional new tags ...
        ... existing tags ...
  </tags>
</tsResponse>

Version

Version 1.0 and later. For more information, see REST API and Resource Versions.

Errors

HTTP status error Code Condition Details
400 400000 Bad request The content of the request body is missing or incomplete, or contains malformed XML.
400 400075 Error adding tags There was a problem adding tags to the specified data source.
403 403004 Adding tags forbidden

A non-administrator user called this method but doesn't have permission to add tags. This error is raised even if the <tags> element is empty.

404 404000 Site not found

The site ID in the URI is not for an existing site.

404 404004 Data source not found The data source ID in URI doesn't correspond to an existing data source.
404 404009 Data source ID mismatch The request body contains a data source ID (which is optional) and it doesn't match the ID in the URI.
404 405000 Invalid request method Request type was not PUT.

For more information, see Handling Errors.

Example

curl "http://MY-SERVER/api/3.13/sites/9a8b7c6d-5e4f-3a2b-1c0d-9e8f7a6b5c4d/datasources/1a2a3b4b-5c6c-7d8d-9e0e-1f2f3a4a5b6b/tags" -X PUT -H "X-Tableau-Auth:12ab34cd56ef78ab90cd12ef34ab56cd" -d @add-tags-to-datasource.xml

Content of add-tags-to-datasource.xml:

<tsRequest>
    <tags>
      <tag label="GDP" />
      <tag label="Health" />
    </tags>
</tsRequest>

Example response:

<tsResponse version-and-namespace-settings>
  <tags>
    <tag label="GDP"/>
    <tag label="Health"/>
    <tag label="Spending"/>
  </tags>
</tsResponse>

Add Tags to Database

Add one or more tags to a database.

For more information about tags, see Tag Items(Link opens in a new window) in the Tableau User Help.

URI

PUT api/api-version/sites/site-id/databases/database-id/tags

Parameter Values

api-version The version of the API to use, such as 3.13. For more information, see REST API and Resource Versions.
site-id The unique ID of the site asset.
database-id The unique ID of the database asset.

Request Body

<tsRequest>
  <tags>
	<tag label="tag-value1" />
	<tag label="tag-value2" />
  </tags>
</tsRequest>
      

Attribute Values

tag-value1

Keyword text you want to add to the asset.

tag-value2 Keyword text you want to add to the asset.

Permissions

If Tableau Server or Tableau Online is licensed through the Data Management Add-on, the following users have permissions to add tags:

  • Tableau Server admins or Tableau Online site admins
  • Authorized users who have been granted explicit permission to edit or "Write" to the asset metadata

Response Code

200

Response Body

Example response

<tsResponse>
  <tags>
	<tag label="Noteworthy" />
	<tag label="PII" />
  </tags>
</tsResponse>
      

Version

Version 3.9 and later. For more information, see REST API and Resource Versions.

Errors

HTTP status error Code Condition Details
400 400000 Bad request The content of the request body is missing or incomplete, or contains malformed XML.
403 403004 Unauthorized operation Insufficient permissions to perform the operation.
404 404031 Database not found The database asset does not exist.
409 409048 Generic database tag error The tag or tags could not be added (or deleted) for some other reason than those specified above.

Add Tags to Table

Add one or more tags to a table.

For more information about tags, see Tag Items(Link opens in a new window) in the Tableau User Help.

URI

PUT api/api-version/sites/site-id/tables/table-id/tags

Parameter Values

api-version The version of the API to use, such as 3.13. For more information, see REST API and Resource Versions.
site-id The unique ID of the site asset.
table-id The unique ID of the column asset.

Request Body

<tsRequest>
  <tags>
	<tag label="tag-value1" />
	<tag label="tag-value2" />
  </tags>
</tsRequest>
      

Attribute Values

tag-value1

Keyword text you want to add to the asset.

tag-value2

Keyword text you want to add to the asset.

Permissions

If Tableau Server or Tableau Online is licensed through the Data Management Add-on, the following users have permissions to add tags:

  • Tableau Server admins or Tableau Online site admins
  • Authorized users who have been granted explicit permission to edit or "Write" to the asset metadata

Response Code

200

Response Body

Example response

<tsResponse>
  <tags>
	<tag label="Noteworthy" />
	<tag label="PII" />
  </tags>
</tsResponse>
      

Version

Version 3.9 and later. For more information, see REST API and Resource Versions.

Errors

HTTP status error Code Condition Details
400 400000 Bad request The content of the request body is missing or incomplete, or contains malformed XML.
403 403004 Unauthorized operation Insufficient permissions to perform the operation.
404 404032 Table not found The table asset does not exist.
409 409055 Generic table tag error The tag or tags could not be added (or deleted) for some other reason than those specified above.

Add Tags to View

Adds one or more tags to the specified view.

URI

PUT /api/api-version/sites/site-id/views/view-id/tags

Parameter Values

api-version The version of the API to use, such as 3.13. For more information, see REST API and Resource Versions.
site-id The ID of the site that contains the workbook.
view-id The ID of the views to add tags to.

Request Body

<tsRequest>
  <tags>
    <tag label="tag" />
    ... additional tags ...
  </tags>
</tsRequest>
        

Attribute Values

view-id The view to add the tag to. If the view is already tagged with a tag that's included in the request body, those tags are ignored and the view retains them. If the <tags> element is empty, no new tags are added to the view.
tag The text of the tag.

Permissions

Tableau Server users who are not server administrators or site administrators can call this method only if they have Read permissions for the view (either explicitly or implicitly).

Response Code

200

Response Body

<tsResponse>
  <tags>
    <tag label="tag"/>
        ... additional new tags ...
        ... existing tags ...
  </tags>
</tsResponse>

Version

Version 1.0 and later. For more information, see REST API and Resource Versions.

Errors

HTTP status error Code Condition Details
400 400000 Bad request The content of the request body is missing or incomplete, or contains malformed XML.
400 400076 Error adding tags There was a problem adding tags to the specified view.
403 403004 Adding tags forbidden

A non-administrator user called this method but doesn't have permission to add tags. This error is raised even if the <tags> element is empty.

404 404000 Site not found

The site ID in the URI is not for an existing site.

404 404011 View not found The view ID in URI doesn't correspond to an existing view.
404 404009 Workbook ID mismatch The request body contains a view ID (which is optional) and it doesn't match the ID in the URI.
404 405000 Invalid request method Request type was not PUT.

For more information, see Handling Errors.

Example

curl "http://MY-SERVER/api/3.13/sites/9a8b7c6d-5e4f-3a2b-1c0d-9e8f7a6b5c4d/views/1f1e1d1c-2b2a-2f2e-3d3c-3b3a4f4e4d4c/tags" -X PUT -H "X-Tableau-Auth:12ab34cd56ef78ab90cd12ef34ab56cd" -d @add-tags-to-view.xml

Content of add-tags-to-workbook.xml:

<tsRequest>
    <tags>
      <tag label="GDP" />
      <tag label="Health" />
    </tags>
</tsRequest>

Example response:

<tsResponse version-and-namespace-settings>
  <tags>
    <tag label="GDP"/>
    <tag label="Health"/>
    <tag label="Spending"/>
  </tags>
</tsResponse>

Add Tags to Workbook

Adds one or more tags to the specified workbook.

URI

PUT /api/api-version/sites/site-id/workbooks/workbook-id/tags

Parameter Values

api-version The version of the API to use, such as 3.13. For more information, see REST API and Resource Versions.
site-id The ID of the site that contains the workbook.
workbook-id The ID of the workbook to add tags to.

Request Body

<tsRequest>
  <tags>
    <tag label="tag" />
    ... additional tags ...
  </tags>
</tsRequest>
        

Attribute Values

workbook-id The workbook to add the tag to. If the workbook is already tagged with a tag that's included in the request body, those tags are ignored and the workbook retains them. If the <tags> element is empty, no new tags are added to the workbook.
tag The text of the tag.

Permissions

Tableau Server users who are not server administrators or site administrators can call this method only if they have Read permissions for the workbook (either explicitly or implicitly).

Response Code

200

Response Body

<tsResponse>
  <tags>
    <tag label="tag"/>
        ... additional new tags ...
        ... existing tags ...
  </tags>
</tsResponse>

Version

Version 1.0 and later. For more information, see REST API and Resource Versions.

Errors

HTTP status error Code Condition Details
400 400000 Bad request The content of the request body is missing or incomplete, or contains malformed XML.
400 400049 Error adding tags There was a problem adding tags to the specified workbook.
403 403004 Adding tags forbidden

A non-administrator user called this method but doesn't have permission to add tags. This error is raised even if the <tags> element is empty.

404 404000 Site not found

The site ID in the URI is not for an existing site.

404 404006 Workbook not found The workbook ID in URI doesn't correspond to an existing workbook.
404 404009 Workbook ID mismatch The request body contains a workbook ID (which is optional) and it doesn't match the ID in the URI.
404 405000 Invalid request method Request type was not PUT.

For more information, see Handling Errors.

Example

curl "http://MY-SERVER/api/3.13/sites/9a8b7c6d-5e4f-3a2b-1c0d-9e8f7a6b5c4d/workbooks/1a1b1c1d-2e2f-2a2b-3c3d-3e3f4a4b4c4d/tags" -X PUT -H "X-Tableau-Auth:12ab34cd56ef78ab90cd12ef34ab56cd" -d @add-tags-to-workbook.xml

Content of add-tags-to-workbook.xml:

<tsRequest>
    <tags>
      <tag label="GDP" />
      <tag label="Health" />
    </tags>
</tsRequest>

Example response:

<tsResponse version-and-namespace-settings>
  <tags>
    <tag label="GDP"/>
    <tag label="Health"/>
    <tag label="Spending"/>
  </tags>
</tsResponse>

Add User to Data-Driven Alert

Adds a specified user to the recipients list for a data-driven alert.

URI

POST /api/api-version/sites/site-id/dataAlerts/data-alert-id/users

Parameter Values

api-version The version of the API to use, such as 3.13. For more information, see REST API and Resource Versions.
site-id The ID of the site that contains the specified data-driven alert.
data-alert-id The ID of the data-driven alert. You can obtain this ID by calling Query Data-Driven Alerts.

Request Body

<tsRequest>
  <user id="user-id"/>
</tsRequest>
        

Permissions

This method can only be called by server administrators and site administrators, and by users who are owners of the specified alert.

Response Code

200

Response Body

<tsResponse>
  <user id="user-id"
    name="user-name"
    siteRole="site-role"
    externalAuthUserId="external-user-id"/>
</tsResponse>
        

Version

Version 3.2 and later. For more information, see REST API and Resource Versions.

Errors

HTTP status error Code Condition Details
403 403004 Write forbidden A user called this method who does not have the required permissions.
403 409028 Adding recipient to data-driven alert forbidden The user is not authorized to add the recipient to the data-driven alert.
404 404000 Site not found The site ID or URL namespace in the URI doesn't correspond to an existing site.
404 404002 Resource Not Found The user ID specified in the request body is invalid.
404 409023 Resource Not Found The data-driven alert ID specified in the URI is invalid.
405 405000 Invalid request method Request type was not POST.

For more information, see Handling Errors.

Example

curl "http://MY-SERVER/api/3.13/sites/13020592-762f-4de4-a25e-f4beb005836e/dataAlerts/e5a4b73e-5cbb-412d-907e-f31cc31684f7/users" -X POST -H "X-Tableau-Auth:12ab34cd56ef78ab90cd12ef34ab56cd" -d @add-user-to-alert.xml

Content of add-user-to-alert.xml:

<tsRequest>
  <user id="8eda27d9-5ad2-42cd-a39a-61bc01a423af"/>
</tsRequest>

Example response:


<tsResponse>
  <user id="8eda27d9-5ad2-42cd-a39a-61bc01a423af"
        name="admin"
        siteRole="ServerAdministrator"
        externalAuthUserId=""/>
</tsresponse>

Add User to Group

Adds a user to the specified group.

Note: After you create a resource, the server updates its search index. If you make a query immediately to see a new resource, the query results might not be up to date.

URI

POST /api/api-version/sites/site-id/groups/group-id/users

Parameter Values

api-version The version of the API to use, such as 3.13. For more information, see REST API and Resource Versions.
site-id The ID of the site that contains the group.
group-id The ID of the group to add the user to.

Request Body

<tsRequest>
  <user id="user-id" />
</tsRequest>
        

Attribute Values

user-id The ID (not name) of the user to add. You can get the user ID by calling Get Users on Site .

Permissions

This method can only be called by server administrators and site administrators.

Response Code

200

Response Body

<tsResponse>
  <user id="user-id"
    name="user-name"
    siteRole="site-role" />
</tsResponse>
        

The siteRole value is returned as one of the following values: Creator, Explorer, ExplorerCanPublish, ServerAdministrator, SiteAdministratorExplorer, SiteAdministratorCreator, Unlicensed, ReadOnly, or Viewer.

Version

Version 2.0 and later. For more information, see REST API and Resource Versions.

Errors

HTTP status error Code Condition Details
400 400000 Bad request The content of the request body is missing or incomplete, or contains malformed XML.
404 404000 Site not found The site ID in the URI doesn't correspond to an existing site.
404 404012 Group not found The group name in the request body doesn't correspond to an existing group.
405 405000 Invalid request method Request type was not POST.
409 409011 User conflict The specified user is already a member of the group.

For more information, see Handling Errors.

Example

curl "http://MY-SERVER/api/3.13/sites/9a8b7c6d-5e4f-3a2b-1c0d-9e8f7a6b5c4d/groups/1a2b3c4d-5e6f-7a8b-9c0d-1e2f3a4b5c6d/users" -X POST -H "X-Tableau-Auth:12ab34cd56ef78ab90cd12ef34ab56cd" -d @add-user-to-group.xml

Content of add-user-to-group.xml:

<tsRequest>
  <user id="9f9e9d9c-8b8a-8f8e-7d7c-7b7a6f6d6e6d" />
</tsRequest>

Example response:

<?xml version="1.0" encoding="UTF-8" ?>
<tsResponse version-and-namespace-settings>
  <user id="59a8a7b6-be3a-4d2d-1e9e-08a7b6b5b4ba" name="Adam"
        siteRole="Explorer" />
</tsResponse>

Add User to Site

Adds a user to Tableau Server and assigns the user to the specified site.

If Tableau Server is configured to use local authentication, the information you specify is used to create a new user in Tableau Server.

Note: After creating the user, you must set a full name, password, and email address for the user with the call to Update User. If you are using SAML with local authentication, the user information that you add is not synchronized with the SAML IdP, as it would be if you were using Active Directory. Even if it is not used by SAML, the user information must be present.

If Tableau Server is configured to use Active Directory for authentication, the user you specify is imported from Active Directory into Tableau Server.

When you add user to Tableau Online, the name of the user must be the email address that is used to sign in to Tableau Online. After you add a user, Tableau Online sends the user an email invitation. The user can click the link in the invitation to sign in and update their full name and password.

If you try to add a user using a specific site role but you have already reached the limit on the number of licenses for your users, the user is added as an unlicensed user. In that case, the response code is 201 (which indicates success), but the siteRole value in the response body is set to Unlicensed.

Note: After you create a resource, the server updates its search index. If you make a query immediately to see a new resource, the query results might not be up to date.

URI

POST /api/api-version/sites/site-id/users

Parameter Values

api-version The version of the API to use, such as 3.13. For more information, see REST API and Resource Versions.
site-id The ID of the site to add users to.

Request Body

<tsRequest>
  <user name="user-name"
        siteRole="site-role"
        authSetting="auth-setting" />
</tsRequest>
        

Attribute Values

user-name

The name of the user. If the server uses local authentication, this can be any name. If you are using Active Directory authentication, or if you are using Tableau Online, there are specific requirements for the name.

For Tableau Server:
If Tableau Server uses Active Directory authentication, this must be the name of an existing user in Active Directory. If the user name is not unique across domains, you must include the domain as part of the user name (for example, example\Adam or adam@example.com).

Note: Active Directory specifies a user name using two attributes: sAMAccountName and userPrincipalName (UPN) prefix. For most Active Directory users, these attributes are the same. By default, if you are adding a user from Active Directory, the name that you provide in the user-name is matched against the Active Directory sAMAccountName attribute, which becomes the name that the user signs in to Tableau Server with.

Two exceptions are when the name that you provide: is longer than 20 characters; and includes an @ character. In these cases, Tableau imports the user using the Active Directory UPN. For more information, see User Naming Attributes(Link opens in a new window) on the MSDN site.

For Tableau Online:
The user-name is the email address that the user will use to sign in to Tableau Online. When you add a user to the site, Tableau Online sends an email invitation. The user can click the link in the invitation to sign in and update their full name and password.

site-role

The site role to assign to the user. You can assign the following roles: Creator, Explorer, ExplorerCanPublish, SiteAdministratorExplorer, SiteAdministratorCreator, Unlicensed, or Viewer.

Note: You cannot use the REST API to set a user to be a server administrator (ServerAdministrator site role).

new-auth-setting

(Optional) The authentication type for the user.

(For Tableau Server: This attribute only applies when adding users to sites with site-specific SAML enabled in settings.)

You can assign the following values for this attribute:

Permissions

This method can only be called by server administrators and site administrators.

Response Code

201

Response Body

<tsResponse>
  <user id="user-id"
   name="user-name"
   siteRole="site-role"
   authSetting="auth-setting" />
</tsResponse>
        

Response Headers

Location: /api/3.13/sites/site-id/users/new-user-id

Version

Version 1.0 and later. For more information, see REST API and Resource Versions.

Errors

HTTP status error Code Condition Details
400 400000 Bad request The content of the request body is missing or incomplete, or contains malformed XML.
400 400013 Invalid site role

The value of the siteRole attribute must be Explorer, ExplorerCanPublish, SiteAdministratorCreator, SiteAdministratorExplorer, Unlicensed, or Viewer.

404 404000 Site not found The site ID in the URI doesn't correspond to an existing site.
404 404002 User not found The server is configured to use Active Directory for authentication, and the username specified in the request body doesn't match an existing user in Active Directory.
405 405000 Invalid request method Request type was not POST.
409 409000 User conflict The specified user already exists on the site.
409 409005 Guest user conflict The Tableau Server API doesn't allow adding a user with the guest role to a site.

For more information, see Handling Errors.

Example

curl "http://MY-SERVER/api/3.13/sites/9a8b7c6d-5e4f-3a2b-1c0d-9e8f7a6b5c4d/users/" -X POST -H "X-Tableau-Auth:12ab34cd56ef78ab90cd12ef34ab56cd" -d @add-user-to-site.xml

  • MY-SERVER is the name or IP address of your server.
  • 9a8b7c6d5-e4f3-a2b1-c0d9-e8f7a6b5c4d is the ID of the site to add the user to, as returned by a previous call to Sign In.
  • 12ab34cd56ef78ab90cd12ef34ab56cd is the authentication returned by a previous call to Sign In.

Content of add-user-to-site.xml:

<tsRequest>
  <user name="Adam"
    siteRole="Explorer" />
</tsRequest>

Example response:

<tsResponse version-and-namespace-settings>
  <user id="9f9e9d9c-8b8a-8f8e-7d7c-7b7a6f6d6e6d"
    name="Adam"
    siteRole="Explorer"
    authSetting="ServerDefault"  />
</tsResponse>

Add View Permissions

Adds permissions to the specified view (also known as a sheet) for a Tableau Server user or group. You can specify multiple sets of permissions using one call.

URI

PUT /api/api-version/sites/site-id/views/view-id/permissions

Parameter Values

api-version The version of the API to use, such as 3.13. For more information, see REST API and Resource Versions.
site-id The ID of the site that contains the workbook view.
view-id The ID of the view to set permissions for. You can obtain this ID by calling Query Views for Site.

Request Body

<tsRequest>
  <permissions>
    <view id="view-id" />
	<granteeCapabilities>
	  <user id="user-id" />
      <capabilities>
        <capability name="capability-name" mode="capability-mode" />
        ... additional capabilities ...
      </capabilities>
    </granteeCapabilities>
    <granteeCapabilities>
      <group id="group-id" />
      <capabilities>
        <capability name="capability-name" mode="capability-mode" />
        ... additional capabilities ...
      </capabilities>
    </granteeCapabilities>
    ... additional grantee capability sets ...
  </permissions>
</tsRequest>
        

Attribute Values

view-id The view-id value must match the view ID in the URI.
user-id The ID (not name) of the user to add permissions for.
group-id The ID (not name) of the group to add permissions for.
capability-name The capability to assign. If any capability has already been granted or denied for a specified user or group, that capability is ignored. For valid capabilities for a view are AddComment, ChangePermissions, Delete, ExportData, ExportImage, ExportXml, Filter, Read (view), ShareView, ViewComments, ViewUnderlyingData, WebAuthoring, and Write.

For more information, see Permissions.

capability-mode Allow to allow the capability, or Deny to deny it. This value is case sensitive.

Permissions

This method can only be called by server and site administrators, and user who have permission to set permissions on the workbook (either explicitly or implicitly). To use this method, the parent workbook that contains the specified view must have its showTabs attribute set to Hide. You can configure this setting by using the Update Workbook method.

Response Code

200

Response Body

<tsResponse>
  <permissions>
    <view id="view-id" />
      <owner id="owner-id"/>
    </view>
    <granteeCapabilities>
      <user id="user-id" />
      <capabilities>
        <capability name="capability-name" mode="capability-mode" />
        <capability name="capability-name" mode="capability-mode" />
      </capabilities>
    </granteeCapabilities>
    <granteeCapabilities>
      <user id="user-id" />
      <capabilities>
        <capability name="capability-name" mode="capability-mode" />
        <capability name="capability-name" mode="capability-mode" />
      </capabilities>
    </granteeCapabilities>
    <granteeCapabilities>
      <group id="group-id" />
      <capabilities>
        <capability name="capability-name" mode="capability-mode" />
          </capabilities>
          </granteeCapabilities>
  </permissions>
</tsResponse>
        

The createdAt and updatedAt values are dates and times in UTC format (YYYY-MM-DDTHH:MM:SSZ).

Version

Version 3.2 and later. For more information, see REST API and Resource Versions.

Errors

HTTP status error Code Condition Details
400 400000 Bad request The content of the request body is missing or incomplete, or contains malformed XML.
400 400009 Invalid capability The capability in the URI is invalid for a view.
403 403004 Permissions setting forbidden A non-administrator user called this method but doesn't have permission to set permissions on the view.
404 404000 Site not found The site ID in the URI doesn't correspond to an existing site.
404 404011 View not found The view ID in the URI doesn't correspond to an existing view.
404 404012 Group not found A group ID in the request body doesn't correspond to an existing group.
404 404013 Capability not found The specified capability doesn't correspond to a defined capability. This can apply to either an invalid capability name or an invalid capability value (other than Allow or Deny).
405 405000 Invalid request method Request type was not PUT.

For more information, see Handling Errors.

Example

curl "http://MY-SERVER/api/3.13/sites/13020592-762f-4de4-a25e-f4beb005836e/views/e5a4b73e-5cbb-412d-907e-f31cc31684f7" -X GET -H "X-Tableau-Auth:12ab34cd56ef78ab90cd12ef34ab56cd" -d @add-view-permissions.xml

Example of add-view-permissions.xml:

<tsRequest>
  <permissions>
    <view id="34acb0d7-fa37-43d7-bdde-d6635eb724b5" />
    <granteeCapabilities>
      <user id="8eda27d9-5ad2-42cd-a39a-61bc01a423af" />
      <capabilities>
        <capability name="ExportImage" mode="Allow" />
        <capability name="ChangePermissions" mode="Deny" />
      </capabilities>
    </granteeCapabilities>
  </permissions>
</tsRequest>

Example response:

<tsResponse>
  <permissions>
    <view id="34acb0d7-fa37-43d7-bdde-d6635eb724b5" name="What If Forecast">
      <owner id="8eda27d9-5ad2-42cd-a39a-61bc01a423af"/>
    </view>
    <granteeCapabilities>
      <group id="2aa47cfa-9f2b-11e8-a260-af4a26124661"/>
      <capabilities>
        <capability name="ShareView" mode="Allow"/>
        <capability name="ViewComments" mode="Allow"/>
        <capability name="Filter" mode="Allow"/>
        <capability name="ExportData" mode="Allow"/>
        <capability name="Read" mode="Allow"/>
        <capability name="AddComment" mode="Allow"/>
        <capability name="ViewUnderlyingData" mode="Allow"/>
        <capability name="ExportImage" mode="Allow"/>
      </capabilities>
    </granteeCapabilities>
    <granteeCapabilities>
      <user id="8eda27d9-5ad2-42cd-a39a-61bc01a423af"/>
      <capabilities>
        <capability name="ExportImage" mode="Allow"/>
        <capability name="ChangePermissions" mode="Deny"/>
      </capabilities>
    </granteeCapabilities>
  </permissions>
</tsResponse>

Add View to Favorites

Adds the specified view to a user's favorites.

If the user already has the view listed as a favorite with the same label, the operation has no effect. If the label differs, the original favorite is overwritten.

URI

PUT /api/api-version/sites/site-id/favorites/user-id

Parameter Values

api-version The version of the API to use, such as 3.13. For more information, see REST API and Resource Versions.
site-id The ID of the site that contains the view.
user-id The ID of the user to add the favorite for.

Request Body

<tsRequest>
  <favorite label="favorite-label">
    <view id="view-id" />
  </favorite>
</tsRequest>
        

Attribute Values

favorite-label A label to assign to the favorite. This value is displayed when you search for favorites on the server.
view-id The ID (not name) of the view to add as a favorite.

Permissions

Tableau Server users who are not server administrators or site administrators can call this method only if they have permission to add a view to a favorite list (either explicitly or implicitly).

Response Code

200

Response Body

<tsResponse>
  <favorites>
    <favorite label="favorite-labe1">
	  <view id="view-id"
	    name="view-name"
    	contentUrl="content-url"
	    createdAt="created-at"
		updatedAt="updated-at"
  		viewUrlName="view-url-name">
		  <workbook id="workbook-luid"/>
		  <project id"project-luid"/>
		  <tags />
	  </view>
	</favorite>
    ... additional favorites ...
  </favorites>
</tsResponse>
        

The value of view-url-name is the name of the view in its URL. For example, if a view named View 1 shows the URL https://MY_SERVER/#/site/MY_SITE/views/VIEW_1 in your browser address bar, then the view-url-name would be VIEW_1. Modifying the name (display name) of a view will not impact the view-url-name (path element of the view's URL).

Version

Version 1.0 and later. For more information, see REST API and Resource Versions.

Errors

HTTP status error Code Condition Details
400 400000 Bad request The content of the request body is missing or incomplete, or contains malformed XML.
400 400005 Invalid label The favorite label is empty or consists of only white space characters.
403 403004 Forbidden Favorites access A non-administrator user called this method but doesn't have permission to add a view to the specified user's favorites. This will always be the case when the user ID in the URI represents a different user than a non-administrator user who is calling the method.
404 404000 Site not found The site ID in the URI doesn't correspond to an existing site.
404 404002 User not found The user ID in the URI doesn't correspond to an existing user.
404 404011 View not found The view ID in the request body doesn't correspond to an existing view.
405 405000 Invalid request method Request type was not PUT.
409 409007 Label conflict There is already a favorite with the same label for a different view of the same workbook in the specified user's favorites.

For more information, see Handling Errors.

Example

curl "http://MY-SERVER/api/3.13/sites/9a8b7c6d-5e4f-3a2b-1c0d-9e8f7a6b5c4d/favorites/9f9e9d9c-8b8a-8f8e-7d7c-7b7a6f6d6e6d" -X PUT -d @add-view-to-favorites.xml -H "X-Tableau-Auth:12ab34cd56ef78ab90cd12ef34ab56cd"

Content of add-view-to-favorite.xml:

<tsRequest>
  <favorite label="Economic Indicators">
    <view id="1f1e1d1c-2b2a-2f2e-3d3c-3b3a4f4e4d4c" />
  </favorite>
</tsRequest>

Example response:

<tsResponse version-and-namespace-settings>
  <favorites>
    <favorite label="DC Crimespotting">
	  <view id="08a7b6b5-b4ba-be3a-4d2d-1e9e59a8a7b6" name="Crimes_DC"
		contentUrl="content-url"
		createdAt="created-at"
		updatedAt="updated-at"
		viewUrlName="view-url-name">
		  <workbook id="abb3e4c1-e650-4704-870a-03fb7615136f"/>
		  <project id"3d6e8174-8cdf-43ec-94dd-0a1fd3662e47"/>
		  <tags />
	  </view>
    </favorite>
    <favorite label="Economic Indicators">
      <view id="1f1e1d1c2-b2a2-f2e3-d3c3-b3a4f4e4d4c"/>
    </favorite>
  </favorites>
</tsResponse>

Add Workbook Permissions

Adds permissions to the specified workbook for a Tableau Server user or group. You can specify multiple sets of permissions using one call.

URI

PUT /api/api-version/sites/site-id/workbooks/workbook-id/permissions

Parameter Values

api-version The version of the API to use, such as 3.13. For more information, see REST API and Resource Versions.
site-id The ID of the site that contains the workbook.
workbook-id The ID of the workbook to set permissions for.

Request Body

<tsRequest>
  <permissions>
    <workbook id="workbook-id" />
    <granteeCapabilities>
      <user id="user-id" />
      <capabilities>
        <capability name="capability-name" mode="capability-mode" />
        ... additional capabilities ...
      </capabilities>
    </granteeCapabilities>
    <granteeCapabilities>
      <group id="group-id" />
      <capabilities>
        <capability name="capability-name" mode="capability-mode" />
        ... additional capabilities ...
      </capabilities>
    </granteeCapabilities>
    ... additional grantee capability sets ...
  </permissions>
</tsRequest>
        

Attribute Values

workbook-id The <workbook> element is not required, but can be included for compatibility with earlier versions of the REST API. If the <workbook> element is included, the workbook-id value must match the workbook ID in the URI. Any other attributes in the <workbook> element are ignored.
user-id The ID (not name) of the user to add permissions for.
group-id The ID (not name) of the group to add permissions for.
capability-name

The capability to assign. If any capability has already been granted or denied for a specified user or group, that capability is ignored. Valid capabilities for a workbook are AddComment, ChangeHierarchy, ChangePermissions, Delete, ExportData, ExportImage, ExportXml, Filter, Read (view), ShareView, ViewComments, ViewUnderlyingData, WebAuthoring, and Write.

For more information, see Permissions.

capability-mode Allow to allow the capability, or Deny to deny it. This value is case sensitive.

Permissions

Tableau Server users who are not server administrators or site administrators can call this method only if the have permission to set permissions on the workbook (either explicitly or implicitly).

Response Code

200

Response Body

<tsResponse>
  <permissions>
    <workbook id="workbook-id" />
    <granteeCapabilities>
      <user id="user-id" />
      <capabilities>
        <capability name="capability" mode="Allow-or-Deny" />
        <capability name="capability" mode="Allow-or-Deny" />
        ... additional capabilities ...
      </capabilities>
    </granteeCapabilities>
    <granteeCapabilities>
      <group id="group-id" />
      <capabilities>
        <capability name="capability" mode="Allow-or-Deny" />
        <capability name="capability" mode="Allow-or-Deny" />
        ... additional capabilities ...
      </capabilities>
    </granteeCapabilities>
    ... additional grantee capability sets ...
  </permissions>
</tsResponse>
        

Version

Version 2.0 and later. For more information, see REST API and Resource Versions.

Errors

HTTP status error Code Condition Details
400 400000 Bad request The content of the request body is missing or incomplete, or contains malformed XML.
400 400009 Invalid capability The capability in the URI is invalid for a workbook resource. Valid capabilities for a workbook are AddComment, ChangeHierarchy, ChangePermissions, Delete, ExportData, ExportImage, ExportXml, Filter, Read (view), ShareView, ViewComments, ViewUnderlyingData, WebAuthoring, and Write.
403 403004 Permissions setting forbidden A non-administrator user called this method but doesn't have permission to set permissions on the workbook.
404 404000 Site not found The site ID in the URI doesn't correspond to an existing site.
404 404002 User not found A user ID in the request body doesn't correspond to an existing user.
404 404006 Workbook not found The workbook ID in the URI doesn't correspond to an existing workbook.
404 404012 Group not found A group ID in the request body doesn't correspond to an existing group.
404 404013 Capability not found The specified capability doesn't correspond to a defined capability. This can apply to either an invalid capability name or a capability other than Allow or Deny for any mode value.
405 405000 Invalid request method Request type was not PUT.

For more information, see Handling Errors.

Add Workbook to Favorites

Adds the specified workbook to a user's favorites.

If the user already has the workbook listed as a favorite with the same label, the operation has no effect. If the label differs, the original favorite is overwritten.

URI

PUT /api/api-version/sites/site-id/favorites/user-id

Parameter Values

api-version The version of the API to use, such as 3.13. For more information, see REST API and Resource Versions.
site-id The ID of the site that contains the workbook.
user-id The ID of the user to add the favorite for.

Request Body

<tsRequest>
  <favorite label="favorite-label">
    <workbook id="workbook-id" />
  </favorite>
</tsRequest>
        

Attribute Values

favorite-label A label to assign to the favorite. This value is displayed when you search for favorites on the server. If the label is already in use for another workbook, an error is returned.
workbook-id The ID (not name) of the workbook to add as a favorite.

Permissions

Tableau Server users who are not administrators or site administrators can call this method only if they have permission to add a workbook to a favorites list.

Response Code

200

Response Body

<tsResponse>
  <favorites>
      <favorite label="favorite-label">
        <workbook id="workbook-id" />
      </favorite>
      <favorite label="favorite">
        <view id="view-id" />
      </favorite>
      ... additional favorites ...
  </favorites>
</tsResponse>
        

Version

Version 1.0 and later. For more information, see REST API and Resource Versions.

Errors

HTTP status error Code Condition Details
400 400000 Bad request The content of the request body is missing or incomplete, or contains malformed XML.
400 400005 Invalid label

The favorite label is empty or consists of only white space characters.

403 403004 Access to Favorites forbidden

A non-administrator user called this method but doesn't have permission to add a workbook to the specified user's favorites. This will always be the case when the user references in the URI identifies a user other than the user who is calling the method.

404 404000 Site not found The site ID in the URI doesn't correspond to an existing site.
404 404002 User not found The user ID in the URI doesn't correspond to an existing user.
404 404006 Workbook not found The workbook ID in the request body doesn't correspond to an existing workbook.
405 405000 Invalid request method Request type was not PUT.
409 409007 Label conflict There is already a favorite with the same label for a different workbook in the specified user's favorites.

For more information, see Handling Errors.

Add Workbook to Schedule

Adds a task to refresh or accelerate a workbook to an existing schedule. This method is not available for Tableau Online.

The task type must match the schedule type. For a list of schedule types, see Create a Schedule.

URI

PUT /api/api-version/sites/site-id/schedules/schedule-id/workbooks

Parameter Values

api-version The version of the API to use, such as 3.13. For more information, see REST API and Resource Versions.
site-id The ID of the site that contains the view.
schedule-id The ID of the schedule that you are associating with the workbook.

Request Body

<tsRequest>
  <task>
    <extractRefresh>
      <workbook id="workbook-id" />
    </extractRefresh>
  </task>
  <task>
    <dataAcceleration>
      <workbook id="workbook-id" />
    </dataAcceleration>
  </task>
</tsRequest>
        

Attribute Values

workbook-id The ID of the workbook to add to the schedule.

Permissions

Only Tableau Server users who are server administrators or site administrators can add a workbook to a data acceleration schedule. Tableau Server users who are not server administrators or site administrators can only add a workbook to other types of schedules if they own the workbook, or are the project leader for the project that contains the workbook.

Response Code

200

Response Body

<tsResponse>
  <task id="task-id" type="task-type">
    <schedule id="schedule-id"/>
  </task>
</tsResponse>
        

Version

Version 2.8 and later for extract refresh and version 3.8 and later for data acceleration. For more information, see REST API and Resource Versions.

Errors

HTTP status error Code Condition Details
400 400000 Bad Request The content of the request body is missing or incomplete, or contains malformed XML.
401 401002 Unauthorized Access The authentication token provided in the request header was invalid or has expired.
403 403032 Update Forbidden A non-administrator user called this method, but the caller doesn't have sufficient permissions.
404 404000 Site not found The site ID in the URI is unknown.
404 404006 Resource not found The workbook ID in the request body is unknown.
405 405000 Invalid request method Request type was not PUT.
500 500000 Internal Server Error The schedule ID in the URI is unknown.

For more information, see Handling Errors.

Example

curl "http://MY-SERVER/api/3.13/sites/ 1edc53ac-e247-4870-9fd3-6fad0ce5f84d/schedules/9a4ebbab-9ec8-487a-9b48-47fa81d6077a/workbooks" -X PUT -H "X-Tableau-Auth:12ab34cd56ef78ab90cd12ef34ab56cd" –d @add-to-schedule.xml"

Content of add-to-schedule.xml:

<tsRequest>
  <task>
    <extractRefresh>
      <workbook id="5de9cc53-b17d-45af-804d-49144b39f29f" />
    </extractRefresh>
  </task>
</tsRequest>

Example response:

<tsResponse>
  <task>
    <extractRefresh id="9bf8aea0-e3ca-422e-b7ef-d9c4ba6cca45" priority="50" consecutiveFailedCount="0" type="RefreshExtractTask">
      <schedule id="9a4ebbab-9ec8-487a-9b48-47fa81d6077a" name="Weekday early mornings" state="Active" />
      <workbook id="5de9cc53-b17d-45af-804d-49144b39f29f" />
    </extractRefresh>
  </task>
</tsResponse>

Allow dashboard extension on site

Adds a dashboard extension to the safe list the site you are signed into. Permissions - This method can be called by site and server administrators. Availability - Not available for Tableau Online.

POST {server}/api/-/settings/site/extensions/dashboard/safeListItems

view details

Append to File Upload

Uploads a block of data and appends it to the data that is already uploaded. This method is called after an upload has been initiated using Initiate File Upload.

You call Append to File Upload as many times as needed in order to upload the complete contents of a file. When the final block of data has been uploaded, you call Publish Data Source, Publish Flow, or Publish Workbook to commit the file.

For more information, see Publishing Resources.

URI

PUT /api/api-version/sites/site-id/fileUploads/upload-session-id

Parameter Values

api-version The version of the API to use, such as 3.13. For more information, see REST API and Resource Versions.
site-id The ID of the site to upload the file to.
upload-session-id The ID of the upload session. You get this value when you start an upload session using Initiate File Upload.

Request Body

The content of the file to be uploaded is included in a MIME multipart message. For more information, see Publishing Resources.

Permissions

Tableau Server users who are not server administrators or site administrators can call this method only if they have publishing rights on the site.

Response Code

200

Response Body

<tsResponse>
  <fileUpload uploadSessionId=upload-session-id
              fileSize=size-of-file-in-megabytes-after-append />
</tsResponse>
        

Version

Version 2.0 and later. For more information, see REST API and Resource Versions.

Errors

HTTP status error Code Condition Details
400 400000 Bad request The content of the request body is missing or incomplete, or contains malformed XML.
400 400016 File size too large The attached file exceeds the configured maximum attachment size for a single append call. The maximum allowable size will be reported in the error response.
400 400019 Malformed request body The XML content in the MIME multipart request is not empty.
400 400020 Missing file data There is no attachment in the request with the file data to be appended to the upload.
403 403007 Not a publisher A non-administrator user attempted to initiate a file upload, but the caller doesn't have publishing rights on the site.
403 403016 Upload failure The file could not be uploaded for some other reason than those specified earlier.
404 404000 Site not found The site ID in the URI doesn't correspond to an existing site.
404 404015 File upload not found The file upload ID in the URI doesn't correspond to an existing file upload.
405 405000 Invalid request method Request type was not PUT.

For more information, see Handling Errors.

Batch Add (or Update) Data Quality Warnings

Add or update multiple data quality warnings (DQWs) for different content and asset items.

This method is available if your Tableau Online site or Tableau Server is licensed with the Data Management Add-on.

URI

POST api/api-version/sites/site-id/dataQualityWarnings/createOrUpdate

Parameter Values

api-version The version of the API to use, such as 3.13. For more information, see REST API and Resource Versions.
site-id The unique ID of the site asset.

Request Body

<tsRequest>
  <contentList>
	<content contentType="content" id="database-id" />
	<content contentType="content" id="table-id" />
	<content contentType="content" id="datasource-id" />
	<content contentType="content" id="flow-id" />
  </contentList>
  <dataQualityWarning type="type" message="message" isActive="state" isSevere="severity" />
</tsRequest>
      

Attribute Values

content

The type of content or asset the data quality warning is attached to. To specify type, use one of the following values:

  • database
  • table
  • datasource
  • flow
database-id The unique ID of the database asset.
table-id The unique ID of the table asset.
datasource-id The unique ID of the data source content.
flow-id The unique ID of the flow content.
type

The type of data quality warning to apply to the content or asset. To specify type, use one of the following values:

  • DEPRECATED
  • WARNING
  • STALE
  • SENSITIVE_DATA
  • MAINTENANCE
message (Optional) A custom message to accompany the data quality warning.
state (Optional) Controls whether the data quality warning displays. Value can be "true" or "false". If the state is not specified, the data quality warning is set to "true" and is visible by default. For more information about data quality warnings, see "Set a Data Quality Warning" in the Server Help or Online Help.
severity (Optional) Enables high visibility for when the data quality warning is set to "true". Value can be "true" or "false". For more information, see "Set high visibility for data quality warning" in the Server Help or Online Help.

Permissions

If Tableau Server or Tableau Online is licensed through the Data Management Add-on, the following users have permissions to batch add or update data quality warnings:

  • Tableau Server admins or Tableau Online site admins
  • Authorized users who have been granted explicit permission to edit or "Write" to the asset metadata

Response Code

200

Response Body

Example response

<tsRequest>
  <dataQualityWarningList>
	<dataQualityWarning id="8f58aa47-7313-4504-8537-52d869552e18" userDisplayName="Mark Nguyen" contentId="7cfd2ac8-a934-4aa8-bf24-96bff08a019c" contentType="DATABASE" message="Contact admin with questions" type="WARNING" isActive="true" createdAt="2021-06-26T21:34:46Z" updatedAt="2021-06-26T21:34:46Z" isSevere="true">
	  <site id="1e4b3aa0-b48a-4b8e-9bdf-74b7596b9f0a" />
	  <owner id="adcc51d7-8558-4099-9f87-dc1a1615d297" />
	</dataQualityWarning>
	<dataQualityWarning id="c8f0b332-a1c1-48f1-b650-86f342ab937f" userDisplayName="Mark Nguyen" contentId="f6dcfd24-7c65-40f4-a3f3-c29f91b7731e" contentType="DATASOURCE" message="Contact admin with questions" type="WARNING" isActive="true" createdAt="2021-06-26T21:34:46Z" updatedAt="2021-06-26T21:34:46Z" isSevere="true">
	  <site id="1e4b3aa0-b48a-4b8e-9bdf-74b7596b9f0a" />
	  <owner id="adcc51d7-8558-4099-9f87-dc1a1615d297" />
	<dataQualityWarning>
  </dataQualityWarningList>
</tsRequest>     

Version

Version 3.12 and later. For more information, see REST API and Resource Versions.

Errors

HTTP status error Code Condition Details
400 400109 Bad request The content of the request body (content type, content id, or dataQualityWarning attributes) is missing, incomplete, or contains malformed XML.
400 400108 Generic add data quality warning error The data quality warning could not be added for some other reason than those specified in this table.
403 403004 Unauthorized operation Insufficient permissions to perform the operation.
404 404029 Content not found The content does not exist.
409 409004 Invalid parameter One or more values in the request body are invalid.

Batch Add Tags

Add multiple tags to items that are different content and asset types.

This method is available if your Tableau Online site or Tableau Server is licensed with the Data Management Add-on.

For more information about tags, see Tag Items(Link opens in a new window) in the Tableau User Help.

URI

PUT api/api-version/sites/site-id/tags:batchCreate

Parameter Values

api-version The version of the API to use, such as 3.13. For more information, see REST API and Resource Versions.
site-id The unique ID of the site asset.

Request Body

<tsRequest>
  <tagBatch>
	<tags>
	   <tag label="tag-value1"></tag>
	   <tag label="tag-value2"></tag>
	</tags>
	<contents>
	   <content id="database-id"></content>
	   <content id="table-id"></content>
	   <content id="column-id"></content>
	   <content id="datasource-id"></content>
	   <content id="workbook-id"></content>
	   <content id="flow-id"></content>
	</contents>
  </tagBatch>
</tsRequest>
      

Attribute Values

tag-value1

Keyword text you want to add to item.

tag-value2

Keyword text you want to add to item.

database-id The unique ID of the database asset.
table-id The unique ID of the table asset.
column-id The unique ID of the column asset.
datasource-id The unique ID of the data source content.
workbook-id The unique ID of the workbook content.
flow-id The unique ID of the flow content.

Permissions

If Tableau Server or Tableau Online is licensed through the Data Management Add-on, the following users have permissions to add tags:

  • Tableau Server admins or Tableau Online site admins
  • Authorized users who have been granted explicit permission to edit or "Write" to the asset metadata

Response Code

200

Response Body

Example response

<tsRequest>
  <tagBatch>
	<tags>
	   <tag label="PII"></tag>
	   <tag label="Noteworthy"></tag>
	</tags>
	<contents>
	   <content id="21cade8c-d4eb-4fef-bd4a-bdb9d8b09b7d" contentType="Database"></content>
	   <content id="a0314be1-afd4-4a4f-ab85-d75dac661c41" contentType="Table"></content>
	   <content id="8fec4046-e054-476d-a6d0-e808b0d5448b" contentType="Column"></content>
	   <content id="c8c3a0be-3ac8-4de7-8bd6-f912900a1ccd" contentType="Datasource"></content>
	   <content id="ec2b7845-d627-430e-b99c-8543ed50b25c" contentType="Workbook"></content>
	   <content id="c4a560eb-c8a6-48c6-86f4-c9d5e518d027" contentType="Flow"></content>
	</contents>
  </tagBatch>
</tsRequest>
      

Version

Version 3.9 and later. For more information, see REST API and Resource Versions.

Errors

HTTP status error Code Condition Details
400 400000 Bad request The content of the request body is missing or incomplete, or contains malformed XML.
403 403004 Unauthorized operation Insufficient permissions to perform the operation.
404 404029 Content not found The content does not exist.
404 404031 Database not found The database asset does not exist.
404 404032 Table not found The table asset does not exist.
409 409004 Invalid parameter One or more values in the request body are invalid.
409 409066 Column not found The column asset does not exist.

Batch Delete Data Quality Warnings

Permanently remove multiple data quality warning (DQW) items from different content and asset types.

This method is available if your Tableau Online site or Tableau Server is licensed with the Data Management Add-on.

URI

DELETE api/api-version/sites/site-id/dataQualityWarnings/batchDelete

Parameter Values

api-version The version of the API to use, such as 3.13. For more information, see REST API and Resource Versions.
site-id The unique ID of the site asset.

Request Body

<tsRequest>
  <contentList>
	<content contentType="content" id="database-id" />
	<content contentType="content" id="table-id" />
	<content contentType="content" id="datasource-id" />
	<content contentType="content" id="flow-id" />
  </contentList>
</tsRequest>
      

Attribute Values

content

The type of content or asset the data quality warning is attached to. To specify type, use one of the following values:

  • database
  • table
  • datasource
  • flow
database-id The unique ID of the database asset.
table-id The unique ID of the table asset.
datasource-id The unique ID of the data source content.
flow-id The unique ID of the flow content.

Permissions

If Tableau Server or Tableau Online is licensed through the Data Management Add-on, the following users have permissions to delete data quality warnings:

  • Tableau Server admins or Tableau Online site admins
  • Authorized users who have been granted explicit permission to edit or "Write" to the asset metadata

Response Code

204

Response Body

None

Version

Version 3.12 and later. For more information, see REST API and Resource Versions.

Errors

HTTP status error Code Condition Details
400 400000 Bad request The content of the request body is missing or incomplete, or contains malformed XML.
403 403004 Unauthorized operation Insufficient permissions to perform the operation.
404 404029 Content not found The content does not exist.
404 404031 Database not found The database asset does not exist.
404 404032 Table not found The table asset does not exist.
409 409004 Invalid parameter One or more values in the request body are invalid.

Delete Data Quality Certification by ID

Permanently remove a data quality certification from a content or asset item using the data quality certification ID.

This method is available if your Tableau Online site or Tableau Server is licensed with the Data Management Add-on.

URI

DELETE api/api-version/sites/site-id/dataQualityCertification/indicator-id

Parameter Values

api-version The version of the API to use, such as 3.13. For more information, see REST API and Resource Versions.
site-id The unique ID of the site asset.
indicator-id The unique ID of the data quality certification.

Request body

None

Permissions

If Tableau Server or Tableau Online is licensed through the Data Management Add-on, the following users have permissions to delete a data quality certification:

  • Tableau Server admins or Tableau Online site admins
  • Authorized users who have been granted explicit permission to edit or "Write" to the asset metadata

Response Code

204

Version

Version 3.13 and later. For more information, see REST API and Resource Versions.

Errors

HTTP status error Code Condition Details
400 400105 Generic data quality certification error The data quality certification could not be deleted for some reason other than those specified in this table.
403 403004 Unauthorized operation Insufficient permissions to perform the operation.
409 409004 Invalid parameter One or more values in the request body are invalid.

Delete Data Quality Certifications by Content

Permanently remove all data quality certifications from multiple content or asset items.

This method is available if your Tableau Online site or Tableau Server is licensed with the Data Management Add-on.

URI

DELETE api/api-version/sites/site-id/dataQualityCertification

Parameter Values

api-version The version of the API to use, such as 3.13. For more information, see REST API and Resource Versions.
site-id The unique ID of the site asset.
indicator-id The unique ID of the data quality certification.

Request body

<tsRequest>
  <contentList>
	<content contentType="content" id="database-id" />
	<content contentType="content" id="table-id" />
	<content contentType="content" id="datasource-id" />
  </contentList>
</tsRequest>

Attribute Values

content

The type of content or asset the data quality warning is attached to. To specify type, use one of the following values:

  • database
  • table
  • datasource
database-id The unique ID of the database asset.
table-id The unique ID of the table asset.
datasource-id The unique ID of the data source content.

Permissions

If Tableau Server or Tableau Online is licensed through the Data Management Add-on, the following users have permissions to delete data quality certifications:

  • Tableau Server admins or Tableau Online site admins
  • Authorized users who have been granted explicit permission to edit or "Write" to the asset metadata

Response Code

204

Version

Version 3.13 and later. For more information, see REST API and Resource Versions.

Errors

HTTP status error Code Condition Details
400 400106 Generic data quality certification error The data quality certifications could not be deleted for some reason other than those specified in this table.
404 404029 Content not found The content does not exist.
403 403004 Unauthorized operation Insufficient permissions to perform the operation.
409 409004 Invalid parameter One or more values in the request body are invalid.

Batch Delete Tags

Delete multiple tags from items that are different content and asset types.

This method is available if your Tableau Online site or Tableau Server is licensed with the Data Management Add-on.

For more information about tags, see Tag Items(Link opens in a new window) in the Tableau User Help.

URI

DELETE api/api-version/sites/site-id/tags:BatchDelete

Parameter Values

api-version The version of the API to use, such as 3.13. For more information, see REST API and Resource Versions.
site-id The unique ID of the site asset.

Request Body

<tsRequest>
  <tagBatch>
	<tags>
	   <tag label="tag-value1"></tag>
	   <tag label="tag-value2"></tag>
	</tags>
	<contents>
	   <content id="database-id"></content>
	   <content id="table-id"></content>
	   <content id="column-id"></content>
	   <content id="datasource-id"></content>
	   <content id="workbook-id"></content>
	   <content id="flow-id"></content>
	</contents>
  </tagBatch>
</tsRequest>
      

Attribute Values

tag-value1

Keyword text you want to add to item.

tag-value2

Keyword text you want to add to item.

database-id The unique ID of the database asset.
table-id The unique ID of the table asset.
column-id The unique ID of the column asset.
datasource-id The unique ID of the data source content.
workbook-id The unique ID of the workbook content.
flow-id The unique ID of the flow content.

Permissions

If Tableau Server or Tableau Online is licensed through the Data Management Add-on, the following users have permissions to delete tags:

  • Tableau Server admins or Tableau Online site admins
  • Authorized users who have been granted explicit permission to edit or "Write" to the asset metadata

Response Code

204

Response Body

Example response

<tsRequest>
  <tagBatch>
	<tags>
	   <tag label="PII"></tag>
	   <tag label="Noteworthy"></tag>
	</tags>
	<contents>
	   <content id="database-id"></content>
	   <content id="table-id"></content>
	   <content id="column-id"></content>
	   <content id="datasource-id"></content>
	   <content id="workbook-id"></content>
	   <content id="flow-id"></content>
	</contents>
  </tagBatch>
</tsRequest>
      

Version

Version 3.9 and later. For more information, see REST API and Resource Versions.

Errors

HTTP status error Code Condition Details
400 400000 Bad request The content of the request body is missing or incomplete, or contains malformed XML.
403 403004 Unauthorized operation Insufficient permissions to perform the operation.
404 404029 Content not found The content does not exist.
404 404031 Database not found The database asset does not exist.
404 404032 Table not found The table asset does not exist.
409 409004 Invalid parameter One or more values in the request body are invalid.
409 409066 Column not found The column asset does not exist.

Block dashboard extension on server

Adds a dashboard extension to the block list of a server. Permissions - This method can only be called by server administrators. Availability - Not available for Tableau Online.

POST {server}/api/-/settings/server/extensions/dashboard/blockListItems

view details

Cancel Flow Run

Cancels a flow run that is in progress.

URI

PUT /api/api-version/sites/site-id/flows/runs/flow-run-id

Parameter Values

api-version The version of the API to use, such as 3.13. For more information, see REST API and Resource Versions.
site-id The ID of the site that contains the flow.
flow-run-id The ID of the flow run.

Request Body

None

Response Code

200

Response Body

None

Version

Version 3.10 and later. For more information, see REST API and Resource Versions.

Errors

HTTP status error Code Condition Details
403 403135 Flow run already complete The flow run is already complete so it could not be canceled.
403 403137 User does not have permissions to cancel flow run In addition to server administrators and site administrators, users can cancel a flow run if they initiated the flow run or created the flow run scheduled task and have "Run Flow Now" permissions for the flow.
404 404000 Site not found The site ID or URL namespace in the URI doesn't correspond to an existing site.
404 404036 Flow run not found The flow run ID in the URI doesn't correspond to an existing flow run.
405 405000 Invalid request method Request type was not PUT.

For more information, see Handling Errors.

Cancel Job

Cancels a job specified by job ID. To get a list of job IDs for jobs that are currently queued or in-progress, use the Query Jobs method.

The following jobs can be canceled using the Cancel Job method:

  • Full extract refresh
  • Incremental extract refresh
  • Subscription
  • Flow Run
  • Data Acceleration
  • Bridge full extract refresh
  • Bridge incremental extract refresh
  • Queue upgrade Thumbnail (Job that puts the upgrade thumbnail job on the queue)
  • Upgrade Thumbnail

URI

PUT /api/api-version/sites/site-id/jobs/job-id

Parameter Values

api-version The version of the API to use, such as 3.13. For more information, see REST API and Resource Versions.
site-id The ID of the site where the job is running.
job-id The ID of the job to cancel.

Request Body

None

Permissions

This method can only be called by server administrators and site administrators.

Response Code

200

Response Body

None

Version

Version 3.1 and later. For more information, see REST API and Resource Versions.

Errors

HTTP status error Code Condition Details
403 403032 Update forbidden A non-administrator user tried to cancel a job.
403 403091 Can not cancel job, because it's already complete. The job ID provided is for a job that has already succeeded or failed.
404 404000 Site not found The site ID in the URI doesn't correspond to an existing site.
404 405000 Invalid request method Request type was not PUT.

For more information, see Handling Errors.

Example

curl "http://MY-SERVER/api/3.13/sites/1edc53ac-e247-4870-9fd3-6fad0ce5f84d/jobs/2474164d-8d37-4a4c-abc7-c2070fd25fd5" -X PUT -H "X-Tableau-Auth:12ab34cd56ef78ab90cd12ef34ab56cd"

Create a Webhook

Creates a new webhook for a site.

URI

POST /api/3.6/sites/<site-id>/webhooks

Parameter Values

site-id The ID of the site in which you want to create the webhook.  

Request Body

<tsRequest>
  <webhook
    name="webhook-name"
    isEnabled="webhook-enabled-flag"
    event="api-event-name">
      <webhook-source>
        <webhook-source-api-event-name />
      </webhook-source>
      <webhook-destination>
        <webhook-destination-http method="POST" url="url"/>
     </webhook-destination>
  </webhook>
</tsRequest>

Attribute Values

webhook-name This is required. A name for the webhook.
api-event-name | webhook-source-api-event-name

You must specify one of these attribute values. The name of the Tableau event that triggers your webhook. The event name must be one of the supported events listed in the Trigger Events table. The event and webhook-source use different name values for the same event. 

Recommended: Use the event attribute of the webhook to specify the triggering API event for the webhook. The webhook-source element serves the same purpose but is being deprecated in future versions of Tableau webhooks. If both events and webhook-source are specified, their events specified must match. If either are specified, with the other being NULL, then the specified event becomes the webhook trigger, whether the element containing the event name is event or webhook-source.

url Required. The destination URL for the webhook. The webhook destination URL must be https and have a valid certificate.
webhook-enabled-flag (Optional) Boolean. If true (default), the newly created webhook is enabled. If false then the webhook will be disabled.  

Permissions

This method can only be called by server and site administrators.

Response Code

200

Response Body

<tsResponse>
  <webhook
    id="webhook-id"
    name="webhook-name"
    isEnabled="true-or-false"
    statusChangeReason="status-change-reason"
    event="api-event-name">
      <webhook-source>
        <webhook-source-api-event-name />
      </webhook-source>
      <webhook-destination>
        <webhook-destination-http method="POST" url="url"/>
      </webhook-destination>
        <owner id="webhook_owner_luid" name="webhook_owner_name"/>
  </webhook>
</tsResponse>

Response Headers

Location: /api/3.13/sites/site-id/webhooks/<new-webhook-id>

Create an Extract for a Data Source

Create an extract for a data source in a site. Optionally, encrypt the extract if the site and workbooks using it are configured to allow it.

URI

POST /api/api-version/sites/site-id/datasources/datasource-id/createExtract

POST /api/api-version/sites/site-id/datasources/datasource-id/createExtract?encrypt=encryption-flag

Parameter Values

api-version The version of the API to use, such as 3.13. For more information, see REST API and Resource Versions.
site-id The LUID of the site.
datasource-id The LUID of the datasource.
encryption-flag If true, then Tableau will attempt to encrypt the created extracts. If false, or no encrypt parameter is appended to the URI, then the extract won't be encrypted, unless encryption is enforced by site or workbook configuration. An error will be returned when encrypt equals true and encryption is disabled in the site or workbook.

Request Body

None

Permissions

Extracts for data sources can be created by Tableau server or site administrators, and by users who own the data source or are an owner or leader of the project where the data source resides.

Response Code

200

Response Body

<tsResponse>
  <job id="job-id" mode="Asynchronous" type="CreateExtract" createdAt="date-time">
    <extractCreationJob>
	  <datasource id="datasource-id" name="datasource-name" />
  </extractCreationJob>
</tsResponse>
        

Version

Version 3.5 and later. For more information, see REST API and Resource Versions.

Errors

HTTP status error Code Condition Details
400 400000 Bad request The content of the request body is missing or incomplete, or contains malformed XML.
404 404000 Site not found The specified site doesn't correspond to an existing site.
405 405000 Invalid request method Request type was not POST.
409 409070 Invalid request method The data source cannot be extracted because it is file based or in another unsupported form.

For more information, see Handling Errors.

Example

curl "http://MY-SERVER/api/3.13/sites/9a8b7c6d-5e4f-3a2b-1c0d-9e8f7a6b5c4d/datasources/abcd7c6d-5e4f-3a2b-1c0d-9e8f7a6b1234/createExtract" -X POST -H "X-Tableau-Auth: oIcGYxkXSBCLLVm91mfITg|jCQSkWoIbUQVwTcH8WUTWD5nCoOf53LE"

Response body:

<tsResponse>
  <job id="df410925-feae-481d-bf84-2f37bdf7ce69" mode="Asynchronous" type="CreateExtract" createdAt="2019-11-05T00:06:57Z">
    <extractCreationJob>
        <datasource id="e35ec79d-9526-44f1-9a67-7a8b63d265df" name="MY_DATASOURCE_NAME"/>
      <jobLuid>df410925-feae-481d-bf84-2f37bdf7ce69</jobLuid>
    </extractCreationJob>
  </job>
</tsResponse> 

Create Extracts for Embedded Data Sources in a Workbook

Create extracts for all embedded data sources of a workbook. Optionally, encrypt the extracts if the site and workbook using them are configured to allow it.

When you create an extract for a data source in a workbook, the extract is available only to the workbook and may have configuration specific to the workbook, such as hiding of unused fields.

You can create workbook extracts for both embedded and published data sources used by the workbook. When you create a workbook data source for a published data source, then refreshing the workbook extract will retrieve any changes to data from the published datasource, or from the published data source's extract if it is using one.

Note: This method will fail and result in an error if your Server Administrator has disabled the RunNow setting for the site. For more information, see Tableau Server Settings(Link opens in a new window).

URI

POST /api/api-version/sites/site-id/workbooks/workbook-id/createExtract

POST /api/api-version/sites/site-id/workbooks/workbook-id/createExtract?encrypt=encryption-flag

Path Parameter Values

api-version The version of the API to use, such as 3.13. For more information, see REST API and Resource Versions.
site-id The LUID of the site.
workbook-id The LUID of the workbook.
encryption-flag If true, then Tableau will attempt to encrypt the created extracts. If false, or no encrypt parameter is appended to the URI, then the extract won't be encrypted, unless encryption is enforced by site or workbook configuration. An error will be returned when encrypt equals true and encryption is disabled in the site or workbook.

Request Body

<tsRequest>
  <datasources includeAll="extract-all-datasources-flag">
	<datasource id="datasource-id" />
  </datasources>
</tsRequest>
        

Request Parameter Values

api-version Boolean. If true, then create extracts for all datasources embedded in a workbook. If false (default), then a datasource must be specified in the request.
datasource-id LUID of the embedded data source to be extracted.
extract-all-datasources-flag Boolean. If true, then all data sources in the workbook will have an extract created for them. If false, then a data source must be supplied in the request.

Permissions

Extracts for data sources embedded in a workbook can be created by Tableau server or site administrators, and users who own the workbook, or are an owner or leader of the project where the workbook resides.

Response Code

200

Response Body

<tsResponse>
  <job id="job-id" mode="Asynchronous" type="CreateExtract" createdAt="date-time">
    <extractCreationJob>
      <workbook id="workbook-id" name="workbook-name" />
	</extractCreationJob>
  </job>
</tsResponse>
        

Version

Version 3.5 and later. For more information, see REST API and Resource Versions.

Errors

HTTP status error Code Condition Details
400 400000 Bad request The content of the request body is missing or incomplete, or contains malformed XML.
404 404000 Site not found The specified site doesn't correspond to an existing site.
405 405000 Invalid request method Request type was not POST.
409 409070 Invalid request method The data source cannot be extracted because it is file based or in another unsupported form.

For more information, see Handling Errors.

Example

curl "http://MY-SERVER/api/3.13/sites/9a8b7c6d-5e4f-3a2b-1c0d-9e8f7a6b5c4d/workbooks/abcd7c6d-5e4f-3a2b-1c0d-9e8f7a6b1234/createExtract" -X POST -H "X-Tableau-Auth: oIcGYxkXSBCLLVm91mfITg|jCQSkWoIbUQVwTcH8WUTWD5nCoOf53LE" -d "@create-extracts-for-workbook.xml"

Content of create-extracts-for-workbook.xml

<tsResponse>
  <datasources includeAll="false" />
    <datasource id="6b4cf715-c90b-49d6-be85-920a47bae433" />
  </datasources>
</tsRequest>

Response body:

<tsResponse>
  <job id="df410925-feae-481d-bf84-2f37bdf7ce69" mode="Asynchronous" type="CreateExtract" createdAt="2019-11-05T00:06:57Z">
	<extractCreationJob>
	  <workbook id="e35ec79d-9526-44f1-9a67-7a8b63d265df" name="MY_WORKBOOK_NAME"/>
	  <jobLuid>df410925-feae-481d-bf84-2f37bdf7ce69</jobLuid>
    </extractCreationJob>
  </job>
</tsResponse>

Create Group

Creates a group.

If Tableau Server or Tableau Online site is configured to use Active Directory for authentication, this method can create a group and then import users from an Active Directory group.

Note: After you create a resource, the server updates its search index. If you make a query immediately to see a new resource, the query results might not be up to date.

To add users to a group, call Add User To Group. To make changes to an existing group, call Update Group.

If you use the method to import users from an Active Directory, the import process can be performed immediately (synchronously) or as a background job (asynchronously).

Note: If Active Directory contains a large number of users, you should import them asynchronously; otherwise, the process can time out.

The Create Group response returns information in two ways: in the response header and in the response body. The ID of the new group is always returned as the value of the Location header. If you create a local group or import an Active Directory group immediately, the response body contains the name and ID of the new group. If you import an Active Directory group using a background process, the response body contains a <job> element that includes a job ID. You can use the job ID to check the status of the operation by calling Query Job.

URI

POST /api/api-version/sites/site-id/groups

POST /api/api-version/sites/site-id/groups?asJob=asJob-value

Parameter Values

api-version The version of the API to use, such as 3.13. For more information, see REST API and Resource Versions.
site-id The ID of the site to create the group in.
asJob-value A Boolean value that is used if you are importing from Active Directory. If you set this to false (the default), the import process runs as a synchronous process. If the Active Directory group contains many users, the process might time out before it finishes.

If you set this to true, the process runs asynchronously. In that case, Tableau Server starts a job to perform the import and returns the job ID in the Location header. You can check the status of the import job by calling Query Job.

Note: This parameter has no effect if the server is configured to use local authentication.

Request Body

Creating a local group

<tsRequest>
  <group name="new-tableau-server-group-name"
   minimumSiteRole="minimum-site-role"/>
</tsRequest>

        

When the request is to create a local group and minimumSiteRole is specified, users are granted a license using the grant license on-login mode by default.

Importing a group from Active Directory

<tsRequest>
  <group name="active-directory-group-name" >
    <import source="ActiveDirectory"
      domainName="active-directory-domain-name"
      grantLicenseMode="license-mode"
      siteRole="minimum-site-role"/>
  </group>
</tsRequest>
        

When the request is to create a group with grantLicenseMode, a siteRole value should also be supplied.

When the request body contains an <import> element, a Tableau Server or Tableau Online site configured to authenticate via Active Directory will create the group and modify the set of users in the group to be the same as those in Active Directory. The source attribute of the <import> element must be set to ActiveDirectory. If Tableau Server or Tableau Online site is configured to use local authentication, including an <import> element has no effect.

Note: When a group is created by importing from Active Directory, Tableau Server uses the value of the Active Directory sAMAccountName attribute as the user name.

Attribute Values

new-tableau-server-group-name The name for the new group.
active-directory-group-name

The name of the Active Directory group to import.

active-directory-domain-name

The domain of the Active Directory group to import.

minimum-site-role

Required if an import element or grantLicenseMode attribute are present in the request. The site role assigned to users who are imported from Active Directory or granted a license automatically using the grant license on-sync or on-login mode.

If the requested user name matches an existing user in the group, the user either retains their existing role or are granted the one specified in the request, based on the role that enables the most capabilities. This is true whether the group the user belongs to is imported from Active Directory or local.

Site roles that can be assigned, listed from the one enabling the least capabilities to the most, are as follows.

  1. Unlicensed
  2. Viewer
  3. Explorer
  4. ExplorerCanPublish
  5. Creator
  6. SiteAdministratorExplorer
  7. SiteAdministratorCreator

Note: You cannot use the REST API to set a user to be a server administrator (ServerAdministrator site role).

license-mode

Optional. The mode for automatically applying licenses for group members. When the mode is onLogin, a license is granted for each group member when they log in to a site.

For local groups, the mode can be either onLogin or unset. If the attribute is omitted, the default mode is unset, which results in no licenses being granted automatically to group members.

For groups that import an Active Directory domain, the mode can be either onSync or onLogin. If the attribute is omitted, the default mode is onSync where licenses are granted for group members each time the domain is synced.

The minimum role granted to users through grantLicenseMode is specified in the siteRole attribute. If that role has less permissions than an existing role assigned to the user, then the user's permissions remain unchanged.

Permissions

This method can only be called by server administrators and site administrators.

Response Code

201, for creating a local group and for importing immediately

202, for importing using a background process

Response Headers

Location: /api/3.13/sites/site-id/groups/new-group-id

Response Body

Creating a local group:

<tsResponse>
  <group id="new-group-id"
	name="group-name"
	minimumSiteRole="minimum-site-role">
	<import domainName="local" siteRole="default-site-role" grantLicenseMode="license-mode" />
  </group>
</tsResponse>
        

Creating a group and importing from Active Directory immediately:

<tsResponse>
  <group id="new-group-id"
    name="group-name">
	  <import domainName="active-directory-domain-name”
        siteRole="default-site-role"
	 grantLicenseMode="onLogin" />
  </group>
</tsResponse>
        

Importing as a background process:

<tsResponse>
  <job id="job-id" mode="Asynchronous" type="GroupImport"
    progress="0" createdAt="time-job-created" />
</tsResponse>
        

Version

Version 3.9 and later. For more information, see REST API and Resource Versions.

Errors

HTTP status error Code Condition Details
400 400000 Bad request The content of the request body is missing or incomplete, or contains malformed XML.
400 400013 Invalid site role

The value of the minimumSiteRole or siteRole attribute must be Creator, Explorer, ExplorerCanPublish, SiteAdministratorCreator, SiteAdministratorExplorer, Unlicensed, or Viewer.

400 400019 Malformed import element When the <import> element is present in the request body, the following attributes must be specified: source with the value ActiveDirectory; domainName; and siteRole If any of these is missing, the element is malformed.
403 403011 ActiveDirectory is not configured The <import> element is present, but Tableau Server is configured for local authentication.
404 404000 Site not found The site ID in the URI doesn't correspond to an existing site.
404 404016 Domain not found The request body includes an <import> element, but the specified domain name doesn't exist in Active Directory.
404 404017 Active Directory group not found The request body includes an <import> element, but no group exists in Active Directory that matches the specified group name.
405 405000 Invalid request method Request type was not POST.
409 409009 Group name conflict The group name in the request already belongs to the specified site. For the purpose of uniqueness checks, group names are case-insensitive.

For more information, see Handling Errors.

Example: Local Group

curl "http://MY-SERVER/api/3.13/sites/9a8b7c6d-5e4f-3a2b-1c0d-9e8f7a6b5c4d/groups/" -X POST -H "X-Tableau-Auth:12ab34cd56ef78ab90cd12ef34ab56cd" -d @create-local-group.xml

Content of create-local-group.xml:

<tsRequest>
  <group name="marketing-group" />
</tsRequest>

Response header:

Location: /api/3.13/sites/9a8b7c6d-5e4f-3a2b-1c0d-9e8f7a6b5c4d/groups/1a2b3c4d5-e6f7-a8b9-c0d1-e2f3a4b5c6d

Response body:

<tsResponse version-and-namespace-settings>
  <group id="1a2b3c4d-5e6f-7a8b-9c0d-1e2f3a4b5c6d" name="marketing-group" />
</tsResponse>

Example: Active Directory Group

curl "http://MY-SERVER/api/3.13/sites/9a8b7c6d-5e4f-3a2b-1c0d-9e8f7a6b5c4d/groups/" -X POST -H "X-Tableau-Auth:12ab34cd56ef78ab90cd12ef34ab56cd" -d @create-ad-group.xml

Content of create-ad-group.xml:

<tsRequest>
  <group id="1a2b3c4d-5e6f-7a8b-9c0d-1e2f3a4b5c6d" name="marketing-group">
    <import domainName="MY-DOMAIN" siteRole="Viewer" grantLicenseMode="onLogin" />
  </group>
</tsRequest>

Response header:

Location: /api/3.13/sites/9a8b7c6d-5e4f-3a2b-1c0d-9e8f7a6b5c4d/groups/1a2b3c4d5-e6f7-a8b9-c0d1-e2f3a4b5c6d

Response body:

<tsResponse version-and-namespace-settings>
  <group id="1a2b3c4d-5e6f-7a8b-9c0d-1e2f3a4b5c6d" name="marketing-group">
	  <import domainName="MY-DOMAIN" siteRole="Viewer" grantLicenseMode="onLogin" />
  </group>
</tsResponse>

Create Project

Creates a project on the specified site. You can also create project hierarchies by creating a project under the specified parent project on the site. To make changes to an existing project, call Update Project.

Note: After you create a resource, the server updates its search index. If you make a query immediately to see a new resource, the query results might not be up to date.

URI

POST /api/api-version/sites/site-id/projects

POST /api/api-version/sites/site-id/projects?publishSamples=publish-value

Parameter Values

api-version The version of the API to use, such as 3.13. For more information, see REST API and Resource Versions.
site-id The ID of the site to create the project in.
publish-value (Optional) A Boolean value that specifies whether to publish the sample workbooks provided by Tableau to the project. When the publish-value is not specified in the request, or the publishSamples parameter is missing, no samples will be published. To publish the sample workbooks, set publishSamples parameter to true. This option is equivalent to the tabcmd command-line utility option, publishsamples. For more information, see tabcmd(Link opens in a new window).

Request Body

<tsRequest>
  <project parentProjectId="parent-project-id"
    name="project-name"
    description="project-description"
    contentPermissions="content-permissions"/>
</tsRequest>
        

Attribute Values

parent-project-id (Optional) The identifier of the parent project. Use this option to create project hierarchies. For information about how permissions are evaluated in project hierarchies, see Project Permissions States and Defaults Windows(Link opens in a new window) | Linux(Link opens in a new window).
project-name The name to assign to the project.
project-description (Optional) A description for the project.
new-content-permissions

(Optional) This value controls user permissions in a project. However, if the project is nested within a project, it will inherit those permissions and these settings will have no effect. The functional permissions of a project, including those it inherits, are available in value of contentPermission in the response body from a request to create, update, or query a project.

  • LockedToProject to lock permissions so that users cannot overwrite the default permissions set for the project
  • ManagedByOwner to allow users to manage permissions for content that they own
  • LockedToProjectWithoutNested to lock the permissions of a parent project, but not those of its child projects.

The default is ManagedByOwner. For more information, see Lock Content Permissions(Link opens in a new window).

Permissions

This method can only be called by server administrators and site administrators.

Response Code

201

Response Body

<tsResponse>
  <project id="new-project-id"
    parentProjectId="parent-project-id"
    name="project-name"
    description="project-description"
	contentPermissions="content-permissions"
	controllingPermissionsProjectId="controlling-permissions-project-id" />
</tsResponse>
        

Response Headers

Location: /api/3.13/sites/site-id/projects/new-project-id

Version

Version 1.0 and later. For more information, see REST API and Resource Versions.

Errors

HTTP status error Code Condition Details
400 400000 Bad request The content of the request body is missing or incomplete, or contains malformed XML.
400 400008 Bad request The request cannot set content permissions to LockedToProjectWithoutNested for a REST API version lower than 3.8.
403 403008 Insufficient storage on site The samples could not be published because there is not enough storage space remaining on the server to accommodate the samples.
404 404000 Site not found

The site ID in the URI doesn't correspond to an existing site.

405 405000 Invalid request method Request type was not POST.
409 409006 Project name conflict The project name in the request already belongs to the specified site. For the purpose of uniqueness checks, project names are case-insensitive.

For more information, see Handling Errors.

Example 1

curl "http://MY-SERVER/api/3.13/sites/9a8b7c6d-5e4f-3a2b-1c0d-9e8f7a6b5c4d/projects" -X POST -H "X-Tableau-Auth:12ab34cd56ef78ab90cd12ef34ab56cd" -d @create-project.xml

Content of create-project.xml:

<tsRequest>
  <project name="New-Project"
   description="This is a new project"
   contentPermissions="LockedToProject" />
</tsRequest>

Example response:

<tsResponse version-and-namespace-settings>
  <project id="1f2f3e4e-5d6d-7c8c-9b0b-1a2a3f4f5e6e" name="New-Project"
    description="This is a new project"
	contentPermissions="LockedToProject"
	controllingPermissionsProjectId="57646e4e-5d6d-7c8c-9b0b-1a2a3f4f5e6e" />
</tsResponse>

Example 2

curl "http://MY-SERVER/api/3.13/sites/9a8b7c6d-5e4f-3a2b-1c0d-9e8f7a6b5c4d/projects" -X POST -H "X-Tableau-Auth:12ab34cd56ef78ab90cd12ef34ab56cd" -d @create-nested-project.xml

Content of create-nested-project.xml:

<tsRequest>
  <project name="New-Nested-Project"
    parentProjectId="1f2f3e4e-5d6d-7c8c-9b0b-1a2a3f4f5e6e"
    description="This is a new nested project"
    contentPermissions="LockedToProject" />
</tsRequest>
        

Example response:

<tsResponse version-and-namespace-settings>
  <project id="08a7b6b5-b4ba-be3a-4d2d-1e9e59a8a7b6"
    parentProjectId="1f2f3e4e-5d6d-7c8c-9b0b-1a2a3f4f5e6e"
    name="New-Nested-Project"
    description="This is a new nested project"
    contentPermissions="LockedToProject"
    controllingPermissionsProjectId="57464e-5d6d-7c8c-9b0b-1a2a3f4f5e6e" />
</tsResponse>
        

Create Schedule

Creates a new schedule on Tableau Server.

Schedules are not specific to sites. For more information, see Creating a Flow Schedule(Link opens in a new window), Extracts and Refresh Schedules(Link opens in a new window) and Create or Modify a Schedule(Link opens in a new window) in the Tableau Server documentation. Scheduling flows requires Tableau Prep Conductor to be enabled on your Tableau Server. For more information, see Enable Tableau Prep Conductor(Link opens in a new window).

Note: After you create a resource, the server updates its search index. If you make a query immediately to see a new resource, the query results might not be up to date.

URI

POST /api/api-version/schedules

Parameter Values

api-version The version of the API to use, such as 3.13. For more information, see REST API and Resource Versions.

Request Body

<tsRequest>
  <schedule name="schedule-name"
	priority="schedule-priority"
	type="schedule-type"
	frequency="schedule-frequency"
	executionOrder="schedule-execution-order">
	  <frequencyDetails start="start-time" end="end-time">
	    <intervals>
	      <interval interval-expression />
	    </intervals>
 	  </frequencyDetails>
  </schedule>
</tsRequest>
        

Attribute Values

schedule-name The name to give to the schedule. This name identifies the schedule in the server environment when users select a schedule and manage schedule information.
schedule-priority An integer value between 1 and 100 that determines the default priority of the schedule if multiple tasks are pending in the queue. Lower numbers have higher priority.
schedule-type Flow to create a flow schedule,Extract to create an extract refresh schedule, Subscription to create a subscription schedule, or DataAcceleration to create a data acceleration schedule.
schedule-execution-order Parallel to allow jobs associated with this schedule to run at the same time, or Serial to require the jobs to run one after the other.
schedule-frequency

This represents the granularity of the schedule.

  • Hourly. Jobs can be scheduled to at intervals specified in run one or more times per day at intervals specified in minutes or hours. The allowed intervals 15 and 30 minutes and 2, 4, 6, 8, and 12 hours.

  • Daily. Jobs can be scheduled to run once day.
  • Weekly. Jobs can be scheduled to run one or more times per week.
  • Monthly. Jobs can be scheduled to run once per month on a specific day.

The value you provide for schedule-frequency determines whether you must include an end-time value, and what is required in the contents of the <intervals> element.

start-time The time of day on which scheduled jobs should run (or if the frequency is hourly, on which they should start being run), in the format HH:MM:SS (for example, 18:30:00). This value is required for all schedule frequencies. The entered time will be applied based on the time zone of your server.
end-time If the schedule frequency is Hourly, the time of day on which scheduled jobs should stop being run, in the format HH:MM:SS (for example, 23:30:00). Hourly jobs will occur at the specified intervals between the start time and the end time. For other schedule frequencies, this value is not required; if the attribute is included, it is ignored. The entered time will be applied based on the time zone of your server.
interval-expression A value that specifies the interval between jobs associated with the schedule. The value you specify here depends on the value specified in schedule-frequency.

Hourly

The interval expression is only one of the following:

  • hours="interval" where interval is 1, 2, 4, 6, 8, or 12, representing how many hours between jobs.
  • minutes="interval" where interval is 15 or 30, representing how many minutes between jobs.

You can specify an interval in hours or minutes, but not both.

Daily

If the schedule frequency is Daily, no interval is specified. Any information specified in the <intervals> element is ignored.

Weekly

The interval expression is weekDay="weekday", where weekday is Sunday, Monday, Tuesday, Wednesday, Thursday, Friday, or Saturday.

You can specify multiple <interval> elements to indicate that scheduled jobs should run on multiple days during the week.

Monthly

The interval expression is monthDay="day", where day is either the day of the month (1, 2, etc.) or LastDay.

Note: If you want to specify multiple days in the month, you can do this using the web interface. You cannot create such a monthly schedule using REST API.

Permissions

This method can only be called by server administrators.

Response Code

200

Response Body

<tsResponse>
  <schedule id="schedule-id"
    name="schedule-name"
	state="Active-or-Suspended"
    priority="schedule-priority"
	createdAt="datetime-created"
	updatedAt="datetime-updated"
	type="Extract-or-Subscription-or-Flow"
	frequency="schedule-frequency"
	nextRunAt="datetime-next-run"
	executionOrder="Parallel-or-Serial">
	  <frequencyDetails frequency-expression >
	    <intervals>
	      <interval interval-expression />
	    </intervals>
	  </frequencyDetails>
  </schedule>
</tsResponse>
        

Version

Version 2.3 and later. For more information, see REST API and Resource Versions.

Errors

HTTP status error Code Condition Details
400 400000 Bad request The content of the request body is missing or incomplete, or contains malformed XML.
400 400064 Error creating schedule An unspecified error occurred while trying to create the schedule.
400 409004 Bad request The content of the request body is missing or incomplete. For hourly, daily, or monthly schedules, this often means that the content of the <intervals> element does not match the expected format. The <detail> element of the error provides detail about the expected format.
405 405000 Invalid request method Request type was not POST.
409 409021 Schedule name conflict The schedule name in the request already belongs to an existing schedule.

For more information, see Handling Errors.

Example

curl "http://MY-SERVER/api/3.13/schedules/" -X POST -H "X-Tableau-Auth:12ab34cd56ef78ab90cd12ef34ab56cd" -d @create-schedule.xml


Content of create-schedule.xml for an hourly schedule

<tsRequest>
  <schedule name="hourly-schedule-1"
    priority="50"
	type="Extract"
	frequency="Hourly"
	executionOrder="Parallel">
	  <frequencyDetails start="18:30:00" end="23:00:00">
		<intervals>
		  <interval hours="2" />
		</intervals>
	  </frequencyDetails>
  </schedule>
</tsRequest>

Response body

<tsResponse >
  <schedule
    id="4d652179-36bf-47e4-a9dc-e069227c72d0"
    name="hourly-schedule-1"
    state="Active"
    priority="50"
    createdAt="2016-05-07T01:51:19Z"
    updatedAt="2016-05-07T01:51:19Z"
    type="Extract"
    frequency="Hourly"
    nextRunAt="2016-05-07T03:30:00Z"
    executionOrder="Parallel">
      <frequencyDetails start="18:30:00" end="23:00:00">
        <intervals>
           <interval hours="2" />
        </intervals>
      </frequencyDetails>
  </schedule>
</tsResponse>
        


Content of create-schedule.xml for a daily schedule

For a daily schedule, frequencyDetails is set to Daily. The start attribute is required. No intervals element is required. Daily schedules on any recurrence must have the same start and end minute. The hour can be different. However, if the daily schedule is set to only happen once a day, that it needs only a start time and not an end time.

<tsRequest>
  <schedule
    name="daily-schedule-1"
    priority="50"
    type="Subscription"
    frequency="Daily"
    executionOrder="Parallel">
      <frequencyDetails start="02:15:00" />
  </schedule>
</tsRequest>

Response body

<tsResponse>
  <schedule
	id="4d652179-36bf-47e4-a9dc-e069227c72d0"
	name="daily-schedule-1"
	state="Active"
	priority="50"
	createdAt="2016-05-07T01:43:33Z"
	updatedAt="2016-05-07T01:43:33Z"
	type="Subscription"
	frequency="Daily"
	nextRunAt="2016-05-07T09:15:00Z"
	executionOrder="Parallel">
	  <frequencyDetails start="02:15:00" />
  </schedule>
</tsResponse>
        


Content of create-schedule.xml for a weekly schedule

For a weekly schedule, frequencyDetails is set to Weekly. A start attribute is required. The intervals element is required, and must include between 1 and 7 interval subelements that contain a weekDay attribute. Valid values for the weekDay attribute are Sunday, Monday, Tuesday, Wednesday, Thursday, Friday, or Saturday.

<tsRequest>
  <schedule name="weekly-schedule-1"
	priority="50"
	type="Subscription"
	frequency="Weekly"
	executionOrder="Serial">
  	  <frequencyDetails start="18:30:00">
	    <intervals>
	      <interval weekDay="Sunday" />
	      <interval weekDay="Wednesday" />
 	    </intervals>
	  </frequencyDetails>
  </schedule>
</tsRequest>

Response body

<tsResponse>
  <schedule id="4d652179-36bf-47e4-a9dc-e069227c72d0"
    name="weekly-schedule-1"
    state="Active"
    priority="50"
    createdAt="2016-05-07T02:01:30Z"
    updatedAt="2016-05-07T02:01:30Z"
    type="Subscription"
    frequency="Weekly"
    nextRunAt="2016-05-09T01:30:00Z"
    executionOrder="Serial">
      <frequencyDetails start="18:30:00">
        <intervals>
          <interval weekDay="Sunday" />
          <interval weekDay="Wednesday" />
        </intervals>
      </frequencyDetails>
  </schedule>
</tsResponse>
        


Content of create-schedule.xml for a monthly schedule

For a monthly schedule, frequencyDetails is set to Monthly. A start attribute is required. The intervals element is required, and must include 1 interval subelement that contains a monthDay attribute. Valid values for the monthDay attribute are integers between 1 and 31 and the string LastDay.

<tsRequest>
  <schedule name="monthly-schedule-1"
	priority="50"
	type="Subscription"
	frequency="Monthly"
	executionOrder="Parallel">
	  <frequencyDetails start="06:00:00">
	    <intervals>
	      <interval monthDay="15" />
	    </intervals>
	  </frequencyDetails>
  </schedule>
</tsRequest>

Response body

<tsResponse>
  <schedule
	id="4d652179-36bf-47e4-a9dc-e069227c72d0"
	name="monthly-schedule-1"
	state="Active"
	priority="50"
	createdAt="2016-05-07T02:08:25Z"
	updatedAt="2016-05-07T02:08:25Z"
	type="Subscription"
	frequency="Monthly"
	nextRunAt="2016-06-03T13:00:00Z"
	executionOrder="Parallel">
	  <frequencyDetails start="06:00:00">
	    <intervals>
	      <interval monthDay="15" />
	    </intervals>
  	  </frequencyDetails>
  </schedule>
</tsResponse>
        

Create Site

Creates a site on Tableau Server. To make changes to an existing site, call Update Site. This method is not available for Tableau Online.

For more information, see Work with Sites(Link opens in a new window) and Add or Edit Sites(Link opens in a new window) in the Tableau Server documentation.

Note: After you create a resource, the server updates its search index. If you make a query immediately to see a new resource, the query results might not be up to date.

URI

POST /api/api-version/sites

Request Body

<tsRequest>
  <site
	name="site-name"
	contentUrl="content-url"
	adminMode="admin-mode"
	storageQuota="limit-in-megabytes"
	disableSubscriptions="disable-subscriptions"
    editingFlowsEnabled="editing-flows-enabled-flag"
    schedulingFlowsEnabled="scheduling-flows-enabled-flag"
	allowSubscriptionAttachments="allow-subcription-attachments-flag"
	guestAccessEnabled="guest-access-enabled-flag"
	cacheWarmupEnabled="cache-warmup-enabled-flag"
	commentingEnabled="commenting-enabled-flag"
	revisionHistoryEnabled="enable-revision-history-flag"
	revisionLimit="num-revision-limit"
	subscribeOthersEnabled="subscribe-others-enabled-flag"
	extractEncryptionMode="extractEncryptionMode"
	requestAccessEnabled="request-access-enabled-flag"
	runNowEnabled="run-now-enabled-flag"
	userQuota="all-license-limit-total"
	tierCreatorCapacity="creator-license-limit"
	tierExplorerCapacity="explorer-license-limit"
	tierViewerCapacity="viewer-license-limit"
	dataAlertsEnabled="data-alerts-enabled-flag"
	commentingMentionsEnabled="commenting-mentions-enabled-flag"
	catalogObfuscationEnabled="catalog-obfuscation-enabled-flag"
	flowAutoSaveEnabled="flow-auto-save-enabled-flag"
	webExtractionEnabled="web-extraction-enabled-flag"
	runNowEnabled="run-now-enabled-flag"
	metricsContentTypeEnabled="metrics-content-type-enabled-flag"
	notifySiteAdminsOnThrottle="notify-site-admins-on-throttle-flag"
	authoringEnabled="authoring-enabled-flag"
	customSubscriptionEmailEnabled="custom-subscription-email-enabled-flag"
	customSubscriptionEmail="custom-subscription-email"
	customSubscriptionFooterEnabled="custom-subscription-footer-enabled-flag"
	customSubscriptionFooter="custom-subscription-footer"
	askDataMode="ask-data-mode"
	namedSharingEnabled="named-sharing-enabled-flag"
	catalogingEnabled="cataloging-enabled-flag"
	derivedPermissionsEnabled="derived-permissions-enabled-flag"
	userVisibilityMode="user-visibility-mode"
	useDefaultTimeZone="default-time-zone-flag"
 	timeZone="time-zone"
    autoSuspendRefreshEnabled="auto-suspend-refresh-enabled-flag"
    autoSuspendRefreshInactivityWindow="auto-suspend-refresh-inactivity-window"
	explainDataEnabled="explainDataEnabled" />
</tsRequest>
        

Attribute Values

site-name The name of the site.
content-url The site URL. This value can contain only characters that are valid in a URL.
admin-mode (Optional) Specify ContentAndUsers to allow site administrators to use the server interface and tabcmd commands to add and remove users. (Specifying this option does not give site administrators permissions to manage users using the REST API.) Specify ContentOnly to prevent site administrators from adding or removing users. (Server administrators can always add or remove users.)

Note: You cannot set adminMode to ContentOnly and also set userQuota. The default value is ContentAndUsers.

storage-quota (Optional) The maximum amount of space for the new site, in megabytes. If you set a quota and the site exceeds it, publishers will be prevented from uploading new content until the site is under the limit again.
disable-subscriptions

(Optional) Specify true to prevent users from being able to subscribe to workbooks on the specified site. The default is false.

editing-flows-enabled-flag

(Optional) Specify true to enable and false to disable editing flows for a site. For more information on flows, see Enable and Configure Tableau Prep Conductor(Link opens in a new window).

The default is set to true which means editing flows is enabled by default. For more information, see Implication of disabling Tableau Prep Conductor.

scheduling-flows-enabled-flag

(Optional) Specify true to enable and false to disable scheduling flows for a site. For more information on flows, see Enable and Configure Tableau Prep Conductor(Link opens in a new window).

The default is set to true which means scheduling flows is enabled by default. For more information, see Implication of disabling Tableau Prep Conductor.

flows-enabled-flag

The flowsEnabled attribute is deprecated as of API version 3.10.

allow-subscription-attachments-flag

(Optional) If true, and subscription to attachments is enabled on the server, then users can create subscriptions that send an email with images of a workbook or view in a PDF attachment. The default value is true. If subscription to attachments is disabled in the server settings, then making this value true will have no effect. Default is true.

guest-access-enabled-flag

(Optional) Specify true to enable and false to disable the ability for guests, users without specific site access permission, to access the site. Default is false.

cache-warmup-enabled-flag

(Optional) Set this value to true to enable cache warm up to improve workbook load time. Set the value to false to disable cache warmup. Default is true.

commenting-enabled-flag

(Optional) Specify true to enable and false to disable the ability for user comments on views in the site. Default is true.

revision-history-enabled (Optional) true if the site maintains revisions for changes to workbooks and data sources; otherwise, false. The default is false.
num-revision-limit (Optional) An integer between 2 and 10000 to indicate a limited number of revisions for content.

Setting this value to -1 removes any value that was set previously, and effectively removes any limit to the number of revisions that are maintained.

subscribe-others-enabled-flag

(Optional) Specify true to enable and false to disable the ability for view owners to subscribe other users to a view. Default is true.

extractEncryptionMode

(Optional) Specify enforced, enabled, or disabled. Default is disabled. For more information, see Extract and Encryption Methods.

requestAccessEnabled (Optional) Specify true to allow users send access request emails to content or project owners. Specify false if you do not want users to be able to request access. The default is false.
runNowEnabled

(Optional) Specify true to allow users to run flows, extract refreshes, and schedules manually. Specify false if you do not want users to be able to run flows, extract refreshes, and subscriptions manually. The default is true. If this attribute is set to false, the following methods will fail and will return an error message.

Run Flow Now

Run Flow Task(Link opens in a new window)

Update Data Source Now(Link opens in a new window)

Run Extract Refresh Task(Link opens in a new window)

Licensing attributes

For user-based license types, the maximum possible number of users is set by the licenses activated on that server. For core-based licensing, there is no limit to the number of users; if you specify a maximum value, only licensed users are counted, and server administrators are excluded.

The REST API enables administrators to set licensing limits below the purchased maximum with two types of license-related attributes:
- User Quota - The total maximum number of licenses currently configured for a site.
- Tiered Capacities - If set, the configured maximum license count for each license type (role).

Online administrators can get these attributes. An on premise server administrator can both get and set them but if license maximums are set using one attribute kind then the value(s) of the other kind must be null. Setting values for both kinds of attributes will result in an error.

For more information, see Licensing Overview(Link opens in a new window).

User quota

all-license-limit-total

(Optional) The maximum total number of users with Creator, Explorer, or Viewer licenses currently allowed on a site.

On premise server administrators can set userQuota with the following rules: The number can't exceed the number of licenses activated for the site; and if tiered capacity attributes are set, then userQuota will equal the sum of the tiered capacity values, and attempting to set userQuota will cause an error.

An administrator can revert the license limit to number of activated licenses on the site, or shift control of license limits to tiered capacities values, by omitting userQuota from a Create Site or Update Site request, or making its value -1.

Tiered capacity attributes

creator-license-limit
explorer-license-limit
viewer-license-limit

(Optional) The maximum number of licenses for users with the Creator, Explorer, or Viewer role, respectively, allowed on a site.

On premise server administrators can set tiered capacity attributes with the following rules: the number can't exceed the number of licenses of a given type that are activated for the site; a value must be supplied for every tiered capacity license type every time any one or more of them is set.

A value of -1 removes the administrator applied limit for a license type, and reverts the limit to the number of activated licenses configured for the role. Setting the value of a tiered capacity to -1 will not automatically increase the limit if more licenses are purchased and activated for the role in the future.

To use role-specific license limits, the userQuota must be set to null by omitting the attribute from Create Site or Update Site request, or setting its value to -1. Attempting to set values for both tiered capacities and userQuota will result in an error.

data-alerts-enabled-flag

(Optional, boolean) If true, data alerts are enabled on the site. Default value is true.

commenting-mentions-enabled-flag

(Optional, boolean) If true, mentions for commenting are enabled. Default value is true.

catalog-obfuscation-enabled-flag

(Optional, boolean) If true, catalog obfuscation is enabled on the site. Default value is true.

flow-auto-save-enabled-flag

(Optional, boolean) If true, flow auto save is enabled on the site. Default value is true.

web-extraction-enabled-flag

(Optional, boolean) If true, web extraction is enabled on the site. Default value is true.

run-now-enabled-flag

(Optional, boolean) If true, run now for schedules is enabled which allows non-administrators to run schedules manually. Default value is true.

metrics-content-type-enabled-flag

(Optional, boolean) If true, the metrics content type is enabled on the server. Default value is true.

notify-site-admins-on-throttle-flag

(Optional, boolean) If true, site admins will be notified if their background jobs are being throttled. Default value is false.

authoring-enabled-flag

(Optional, boolean) If true, web authoring is enabled. Default value is true.

custom-subscription-email-enabled-flag

(Optional, boolean) If true, sending custom subscription email is enabled. If set to false after being set true, the current custom subscription email is voided. Default value is false.

custom-subscription-email

A valid custom email that will be sent if customSubscriptionEmailEnabled is set to true. Default value is false.

custom-subscription-footer-enabled-flag

(Optional, boolean) If true, a custom footer will be included on subscription and data alert emails. If set to false after being set true, the current custom subscription footer is voided. Default value is false.

custom-subscription-footer

A custom subscription footer that will be added to subscription and data alerts if customSubscriptionFooterEnabled is set to true. Default value is false.

ask-data-mode

The mode of the ask data feature on the site. Can be set to one of two values:
  • DisabledByDefault - Enables creation of Ask Data lenses for all published data sources. Data sources do not have lenses created automatically.
  • DisabledAlways - Disables Ask Data lenses and related content throughout the site. Preserves information about lenses and data source indexes, which are restored if Ask Data is re-enabled.
Default value is DisabledByDefault. For more information, see Disable or Enable Ask Data for a Site(Link opens in a new window).

named-sharing-enabled-flag

(Optional, boolean) If true, named sharing is enabled. Default value is true.

cataloging-enabled-flag

(Optional, boolean) If true, data catalog is enabled for the site. Default value is true.

derived-permissions-enabled-flag

(Optional, boolean) If true, derived permissions are enabled for the site. Default value is false.

user-visibility-mode

(Optional, string) When the value is FULL users can see the user of other site users. If the value is LIMITED User information on the site is not visibel to other users. Default value is FULL. For more information, see User Visibility(Link opens in a new window).
use-default-time-zone Optional, boolean) Set this to true, if you want the time-zone attribute use the Server time Zone at run time. This attribute is set to official IANA name.  If this is set to false, the time-zone value must be specified.
time-zone (Optional, string) Use this attribute to specify a time zone other than the Server time zone at run time. Only canonical names in the official IANA database are supported. You can find the list of the canonical time zone names on wikipedia.
autoSuspendRefreshEnabled (Optional) Tableau can automatically suspend extract refresh tasks for inactive workbooks to save resources. Specify true to enable or false to disable. Default is true.
autoSuspendRefreshInactivityWindow (Optional) An integer between 7 and 100 to indicate the number of days to wait before automatically suspending extract refresh tasks for inactive workbooks. The default is 30.
explainDataEnabled

(Optional, boolean) Set this attribute to false to disable Explain Data capabilities for a site. By default, this attribute is set to true. For more information about this site setting, see one of the following topics:

dqwSubscriptionsEnabled

(Optional, boolean) Set this attribute to false to exclude data quality warnings (DQWs) from subscription emails. By default, this attribute is set to true. For more information about this site setting, see one of the following topics:

Permissions

This method can only be called by server administrators.

Response Code

201

Response Body

<tsResponse>
  <site id="site-id"
 	name="site-name"
	contentUrl="content-url"
 	adminMode="admin-mode"
	disableSubscriptions="disable-subscriptions-flag"
	state="active-or-suspended"
	revisionHistoryEnabled="history-enabled-flag"
	revisionLimit="max-num-revisions"
	allowSubscriptionAttachments="allow-subcription-attachments-flag"
	subscribeOthersEnabled="enable-subscription-of-others-flag"
	guestAccessEnabled="guest-access-enabled-flag"
	cacheWarmupEnabled="cache-warmup-enabled-flag"
	commentingEnabled="commenting-enabled-flag"
    editingFlowsEnabled="editing-flows-enabled-flag"
    schedulingFlowsEnabled="scheduling-flows-enabled-flag"
	extractEncryptionMode="encryption-mode"
	catalogingEnabled="cataloging-enabled-flag"
	derivedPermissionsEnabled="derived-permissions-enabled-flag"
	requestAccessEnabled="request-access-enabled-flag"
	webExtractionEnabled="create-extracts-on-the-web-flag"
	runNowEnabled="run-now-enabled-flag"
	userQuota="all-license-limit-total"
	tierCreatorCapacity="creator-license-limit"
	tierExplorerCapacity="explorer-license-limit"
	tierViewerCapacity="viewer-license-limit"
	askDataMode="ask-data-mode"
	useDefaultTimeZone="default-time-zone-flag"
	timeZone="time-zone"
    autoSuspendRefreshEnabled="auto-suspend-refresh-enabled-flag"
    autoSuspendRefreshInactivityWindow="auto-suspend-refresh-inactivity-window"
	explainDataEnabled="explain-data-enabled"
	dqwSubscriptionsEnabled="dqw-subscriptions-enabled" />
  </site>
</tsResponse>
        

Response Body Details:

  • userQuota, storageQuota, and tiered capacity (tierCreatorCapacity, tierExplorerCapacity, tierViewerCapacity) attributes are only present in the response body if those quotas have been set for the site being queried.

Response Headers

Location: /api/3.13/sites/new-site-id

Version

Version 1.0 and later. For more information, see REST API and Resource Versions.

Errors

HTTP status error Code Condition Details
400 400000 Bad request The content of the request body is missing, incomplete, or contains malformed XML.
400 400000 Invalid storage quota The storage quota value was not a positive number.
400 400000 Invalid user quota The user quota value was not a positive number.
400 400013 Invalid administrator mode The user provided an administrator mode that is not ContentOnly or ContentAndUsers.

Note: An empty string or all whitespace is invalid.

405 405000 Invalid request method Request type was not POST.
409 409001 Site name conflict The site name in the request already belongs to an existing site.
409 409002 Site URL conflict The content URI in the request already belongs to an existing site.
409 409004 User quota and tiered capacity conflict The request cannot set both tiered capacity attributes and userQuota. One or the other must be null.
409 409004 License limit exceeded The request cannot set tiered capacity attributes or userQuota values that are larger than the number of active licenses configured for the site.
409 409004 Administrator mode or user quota conflict The request cannot set adminMode to ContentOnly and also specify a userQuota value.

For more information, see Handling Errors.

Example

curl "http://MY-SERVER/api/3.13/sites/" -X POST -H "X-Tableau-Auth:12ab34cd56ef78ab90cd12ef34ab56cd" -d @create-site.xml

Content of create-site.xml:

<tsRequest>
	<site name="Marketing-Site"
		contentUrl="marketingsite"
		adminMode="ContentAndUsers"
		tierCreatorCapacity="2"
		tierExplorerCapacity="1"
		tierViewerCapacity="1"
		useDefaultTimeZone="false"
		timeZone="America/Los_Angeles"/>
</tsRequest>
        

Response body:

<tsResponse>
	<site id="43e01bb6-d7f9-42ef-bc9f-0422c07520e5"
		name="Marketing-Site"
		contentUrl="marketingsite"
		adminMode="ContentAndUsers"
		disableSubscriptions="true"
		state="Active"
		revisionHistoryEnabled="true"
		revisionLimit="25"
		subscribeOthersEnabled="false"
		allowSubscriptionAttachments="true"
		guestAccessEnabled="true"
		cacheWarmupEnabled="true"
		commentingEnabled="true"
        editingFlowsEnabled="false"
        schedulingFlowsEnabled="false"
		extractEncryptionMode="enabled"
		catalogingEnabled="true"
		derivedPermissionsEnabled="false"
		requestAccessEnabled="false"
		runNowEnabled="true"
		userQuota="4"
		tierCreatorCapacity="2"
		tierExplorerCapacity="1"
		tierViewerCapacity="1"
		useDefaultTimeZone="false"
		timeZone="America/Los_Angeles" />
</tsResponse>
        

Create Subscription

Creates a new, unsuspended subscription to a view or workbook for a specific user. When a user is subscribed to the content, Tableau Server sends the content to the user in email on the schedule that's defined in Tableau Server and specified in this call.

For more information, see Subscribe to Views(Link opens in a new window) in the Tableau Server documentation.

Note: After you create a resource, the server updates its search index. If you make a query immediately to see a new resource, the query results might not be up to date.

URI

POST /api/api-version/sites/site-id/subscriptions

Parameter Values

api-version The version of the API to use, such as 3.13. For more information, see REST API and Resource Versions.
site-id The ID of the site to create the subscription in.

Request Body

<tsRequest>
  <subscription
	subject="subscription-subject"
	attachImage="attach-image-flag"
	attachPdf="attach-pdf-flag"
	pageOrientation="page-orientation"
	pageSizeOption="page-size-option">
	message="message">
	  <content id="content-id"
        type="content-type"
		sendIfViewEmpty="send-view-if-empty-flag"/>
	  <schedule id="schedule-id" />
	  <user id="user-id" />
	</subscription>
</tsRequest>
        

Attribute Values

subscription-subject A description for the subscription. This description is displayed when users list subscriptions for a site in the server environment. A description is required.
attach-image-flag

(Optional) Setting this true will cause the subscriber to receive mail with .png images of workbooks or views attached to it. This is the default behavior if neither attachImage or attachPdf are specified.

If subscriptions to attachments are disabled in Tableau server or site settings, then making a request that sets attachImage to false will cause an error.

attach-pdf-flag

(Optional) Setting this true will cause the subscriber to receive mail with a .pdf file containing images of workbooks or views attached to it.

If subscriptions to attachments are disabled in Tableau server or site settings, then making a request that sets attachPdf to true will cause an error.

page-orientation (Optional) The orientation of the pages produced when attach-pdf-flag is true. The value can be Portrait or Landscape. If this parameter is not present the page orientation will default to Portrait.
page-size-option (Optional) The type of page produced, which determines the page dimensions when attach-pdf-flag is true. The value can be: A3, A4, A5, B5, Executive, Folio, Ledger, Legal, Letter, Note, Quarto, or Tabloid. If this parameter is not present the page type will default to Letter.
message The text body of the subscription email message.
content-type Workbook to create a subscription for a workbook, or View to create a subscription for a view.
send-view-if-empty-flag (Optional) Applies to views only. If true, an image is sent even if the view specified in a subscription is empty. If false, nothing is sent if the view is empty. The default value is true.
content-id The ID of the workbook or view to subscribe to.
schedule-id The ID of a schedule to associate the subscription with. To determine what schedules are available, call Query Schedules. The type of the schedule must be Subscription.
user-id The ID of the user to create the subscription for.

Note: The user must have an email address defined in Tableau Server.

Permissions

The following list summarizes the permissions required to subscribe a user to specific content:

  • Tableau Server users who are server administrators can subscribe any user to any content.
  • Site administrators can subscribe any user on the site to any content on that site.
  • Project leaders can subscribe users to any content that they are project leaders for.
  • Content owners can subscribe users to any content they own.
  • Non-owners can subscribe themselves to any content that they have Read (view) permissions for.

Response Code

201

Response Body

<tsResponse>
  <subscription id="subscription-id"
	subject="subscription-subject"
	suspended="suspended-flag"
	pageOrientation="page-orientation"
	pageSizeOption="page-size-option" >
	  <content id="content-id"
		type="content-type" />
	  <schedule id="schedule-id" name="schedule-name" />
	  <user id="user-id" name="user-name" />
  </subscription>
</tsResponse>
        

Response Headers

Location: /api/3.13/sites/site-id/subscriptions/new-subscription-id

Version

Version 2.3 and later. For more information, see REST API and Resource Versions.

Errors

HTTP status error Code Condition Details
400 400000 Bad request The content of the request body is missing or incomplete, or contains malformed XML.
400 400067 Invalid subscription subject The subscription subject is null or empty.
400 400068 Invalid subscription target The content type specified in the request body is not a workbook or view.
400 400069 Invalid subscription type The subscription type is not Workbook or View.
400 400069 Invalid schedule type The schedule type is not Subscription.
403 403060 No permissions to create subscription. The user does not have permission to create a subscription for the specified content.
403 403063 No user permissions for content. The user specified in the request body does not have Read (view) permissions for the specified content.
403 403064 No user email address. The user does not have an email address.
404 404000 Site not found The specified site doesn't correspond to an existing site.
404 404002 User not found The user specified in the request body doesn't correspond to an existing user.
400 404006 Workbook not found The workbook ID in the request body doesn't correspond to an existing workbook.
404 404011 View not found The view ID in the request body doesn't correspond to an existing view.
404 404023 Schedule not found The schedule ID in the request body doesn't correspond to an existing schedule.
405 405000 Invalid request method Request type was not POST.

For more information, see Handling Errors.

Decrypt Extracts in a Site

Extract encryption at rest is a data security feature that allows you to encrypt .hyper extracts while they are stored on Tableau Server. For more information, see Extract Encryption at Rest(Link opens in a new window).

Decrypts all extracts on a site.

Note: Depending on the number and size of extracts, this operation may consume significant server resources. Consider running this command outside of normal business hours.

URI

POST /api/api-version/sites/site-id/decrypt-extracts

Parameter Values

api-version The version of the API to use, such as 3.13. For more information, see REST API and Resource Versions.
site-id The ID of the site.

Request Body

None

Permissions

Tableau Server administrators can call this method.

Response Code

200

Response Body

None

Version

Version 3.5 and later. For more information, see REST API and Resource Versions.

Errors

HTTP status error Code Condition Details
400 400000 Bad request The content of the request body is missing or incomplete, or contains malformed XML.
404 404000 Site not found The specified site doesn't correspond to an existing site.
405 405000 Invalid request method Request type was not POST.

For more information, see Handling Errors.

Delete a Webhook

Deletes the specified webhook.

URI

DELETE /api/3.6/sites/<site-id>/webhooks/<webhook-id>

Parameter Values

site-id The ID of the site that contains the workbook to be deleted.  
webhook-id The ID of the webhook.  

Request Body

None.

Permissions

This method can only be called by server and site administrators.

Response Code

204

Response Body

None.

Delete analytics extension connection

Deletes a specific connection to an external service for analytics extensions on this site. Permissions - This method can be called by site and server administrators.

DELETE {server}/api/-/settings/site/extensions/analytics/connections/{connection_luid}

view details

Delete Data Acceleration Task

Deletes a data acceleration task.

URI

DELETE /api/api-version/sites/site-id/tasks/dataAcceleration/dataAcceleration-id

Parameter Values

api-version The version of the API to use, such as 3.13. For more information, see REST API and Resource Versions.
site-id The ID of the site that contains the task.
dataAcceleration-id The ID of the task to remove.

Request Body

None

Permissions

This method can only be called by server administrators and site administrators.

Response Code

200

Response Body

None

Version

Version 3.8 and later. For more information, see REST API and Resource Versions.

Errors

HTTP status error Code Condition Details
403 409087 Permission denied The user isn't authorized to view data acceleration tasks.
403 409087 Permission denied The user isn't authorized to access the workbook.
404 404000 Site not found The site ID in the URI doesn't correspond to an existing site.
404 404026 Task not found The task id in the URI doesn't correspond to an existing task.
405 405000 Invalid request method Request type was not DELETE.

For more information, see Handling Errors.

Example

curl "http://MY-SERVER/api/3.13/sites/9a8b7c6d-5e4f-3a2b-1c0d-9e8f7a6b5c4d/tasks/dataAcceleration/7a2a7c6d-5e4f-3a2b-1c0d-9e8f7a6b3r4q" -X GET -H "X-Tableau-Auth:12ab34cd56ef78ab90cd12ef34ab56cd"

Delete Data Quality Warning by Content

Permanently remove the data quality warning from the database, table, published data source, or flow.

This method is available if your Tableau Online site or Tableau Server is licensed with the Data Management Add-on.

URI

DELETE api/api-version/sites/site-id/dataQualityWarnings/content-type/content-luid

Parameter Values

api-version The version of the API to use, such as 3.13. For more information, see REST API and Resource Versions.
site-id The unique ID of the site asset.
content-type

The type of asset that the data quality warning is being attached to. To specify the type, use:

  • database
  • table
  • datasource
  • flow

Types are not case sensitive.

content-luid The unique ID of the content type(database, table, published data source, or flow). This is the same as the content ID.

Request Body

None

Permissions

If Tableau Server or Tableau Online is licensed through the Data Management Add-on, the following users have permissions to delete the data quality warning:

  • Tableau Server admins or Tableau Online site admins
  • Authorized users who have been granted explicit permission to edit or "Write" to the asset metadata

Response Code

204

Response Body

None

Version

Version 3.5 and later. For more information, see REST API and Resource Versions.

Errors

HTTP status error Code Condition Details
400 400000 Bad request The content of the request body is missing or incomplete, or contains malformed XML.
409 400106 Data quality warning delete error An unknown error occurred and the data quality warning could not be deleted.
401 401000 Unauthorized access No authorization credentials were provided.
401 401002 Unauthorized access Invalid authorization credentials were provided.
404 404000 Resource not found The site ID in the URI doesn't correspond to an existing site.
404 404029 Content not found The requested asset could not be found.
404 404030 Data quality warning not found The data quality warning for the requested asset could not be found.

Delete Data Quality Warning by ID

Permanently remove a data quality warning.

This method is available if your Tableau Online site or Tableau Server is licensed with the Data Management Add-on.

URI

DELETE api/api-version/sites/site-id/dataQualityWarnings/dataqualitywarning-id

Parameter Values

api-version The version of the API to use, such as 3.13. For more information, see REST API and Resource Versions.
site-id The unique ID of the site asset.
dataqualitywarning-id

The unique ID of the data quality warning attached to the asset (database, table, published data source, or flow).

Permissions

If Tableau Server or Tableau Online is licensed through the Data Management Add-on, the following users have permissions delete the data quality warning:

  • Tableau Server admins or Tableau Online site admins
  • Authorized users who have been granted explicit permission to edit or "Write" to the asset metadata

Response Code

204

Response Body

None

Version

Version 3.5 and later. For more information, see REST API and Resource Versions.

Errors

HTTP status error Code Condition Details
400 400000 Bad request The content of the request body is missing or incomplete, or contains malformed XML.
400 400105 Data quality warning delete error An unknown error occurred and the data quality warning could not be deleted.
401 401000 Unauthorized access No authorization credentials were provided.
401 401002 Unauthorized access Invalid authorization credentials were provided.
404 404000 Resource not found The site ID in the URI doesn't correspond to an existing site.
404 404029 Content not found The requested asset could not be found.
404 404030 Data quality warning not found The data quality warning for the requested asset could not be found.

Delete Data Source

Deletes the specified data source from a site. When a data source is deleted, its associated data connection is also deleted. Workbooks that use the data source are not deleted, but they will no longer work properly.

URI

DELETE /api/api-version/sites/site-id/datasources/datasource-id

Parameter Values

api-version The version of the API to use, such as 3.13. For more information, see REST API and Resource Versions.
site-id The ID of the site that contains the data source.
datasource-id The ID of the data source to delete.

Request Body

None

Permissions

Tableau Server users who are not server administrators or site administrators can delete a data source for which they have Read (view) and Delete permissions (either explicitly or implicitly).

Response Code

204

Response Body

None

Version

Version 2.0 and later. For more information, see REST API and Resource Versions.

Errors

HTTP status error Code Condition Details
403 403004 Deletion forbidden A non-administrator user called this method but doesn't have Read (view) and Delete permission for the data source.
404 404000 Site not found The site ID or URL namespace in the URI doesn't correspond to an existing site.
404 404004 Data source not found The data source ID in the URI doesn't correspond to an existing data source in the site.
405 405000 Invalid request method Request type was not DELETE.

For more information, see Handling Errors.

Delete Data Source from Favorites

Deletes the specified data source from the user's favorites. If the specified data source is not a favorite, the operation has no effect.

URI

DELETE /api/api-version/sites/site-id/favorites/user-id/datasources/datasource-id

Parameter Values

api-version The version of the API to use, such as 3.13. For more information, see REST API and Resource Versions.
site-id The ID of the site that contains the data source.
user-id The ID of the user to remove the favorite from.
datasource-id The ID of the data source to remove from the user's favorites.

Request Body

None

Permissions

Tableau Server users who are not server administrators or site administrators can call this method only if they have Read (view) permissions on the data source (either explicitly or implicitly).

Response Code

204

Response Body

None

Version

Version 2.3 and later. For more information, see REST API and Resource Versions.

Errors

HTTP status error Code Condition Details
403 403004 Forbidden favorites access A non-administrator user attempted to delete a data source from a different user's favorites.
404 404000 Site not found The site ID or URL namespace in the URI doesn't correspond to an existing site.
404 404002 User not found The user ID in the URI doesn't correspond to an existing user
404 404010 Data source not a favorite The data source ID in the URI exists but is not a favorite of the specified user.
404 404011 Data source not found The data source ID in the URI doesn't correspond to an existing data source
405 405000 Invalid request method Request type was not DELETE.

For more information, see Handling Errors.

Delete Data Source Permission

Removes the specified data source permission for the specified group or user.

URI

DELETE /api/api-version/sites/site-id/datasources/datasource-id/permissions/groups/group-id/capability-name/capability-mode

DELETE /api/api-version/sites/site-id/datasources/datasource-id/permissions/users/user-id/capability-name/capability-mode

Parameter Values

api-version The version of the API to use, such as 3.13. For more information, see REST API and Resource Versions.
site-id The ID of the site that contains the data source.
datasource-id The ID of the data source to remove the permission for.
group-id The ID of the group to remove the permission for.
user-id The ID of the user to remove the permission for.
capability-name

The capability to remove the permission for. Valid capabilities for a data source are ChangePermissions, Connect, Delete, ExportXml, Read (view), and Write.

For more information, see Permissions.

capability-mode Allow to remove the allow permission, or Deny to remove the deny permission. This value is case sensitive.

Request Body

None

Permissions

Tableau Server users who are not server administrators or site administrators can call this method only if they have permission to delete permissions from the data source (either explicitly or implicitly).

Response Code

204

Response Body

None

Version

Version 2.0 and later. For more information, see REST API and Resource Versions.

Errors

HTTP status error Code Condition Details
400 400009 Invalid capability The capability in the URI is invalid for a data source. Valid capabilities for a data source are ChangePermissions, Connect, Delete, ExportXml, Read, and Write.
403 403004 Permissions setting forbidden A non-administrator user called this method but doesn't have permission to set permissions on the data source.
404 404000 Site not found The site ID in the URI doesn't correspond to an existing site.
404 404002 User not found The user ID in the URI doesn't correspond to an existing user.
404 404004 Data source not found The data source ID in the URI doesn't correspond to an existing data source.
404 404012 Group not found The group ID in the URI doesn't correspond to an existing group.
404 404013 Capability not assigned The capability in the URI is not assigned to the specified user or group with the specified mode (Allow or Deny).
405 405000 Invalid request method Request type was not DELETE.

For more information, see Handling Errors.

Delete Data-Driven Alert

Deletes the specified data-driven alert from the specified site.

URI

DELETE /api/api-version/sites/site-id/dataAlerts/data-alert-id

Parameter Values

api-version The version of the API to use, such as 3.13. For more information, see REST API and Resource Versions.
site-id The ID of the site that contains the specified data-driven alert.
data-alert-id The ID of the data-driven alert. You can obtain this ID by calling Query Data-Driven Alerts.

Request Body

None

Permissions

This method can only be called by server and site administrators, and by users who are owners or recipients of the specified data-driven alert.

Response Code

204

Response Body

None

Version

Version 3.2 and later. For more information, see REST API and Resource Versions.

Errors

HTTP status error Code Condition Details
403 403004 Delete forbidden A user called this method who does not have the required permissions
404 409023 Resource Not Found The data-driven alert ID specified in the URI is invalid.
404 404000 Site not found The site ID or URL namespace in the URI doesn't correspond to an existing site.
405 405000 Invalid request method Request type was not DELETE.

For more information, see Handling Errors.

Example

curl "http://MY-SERVER/api/3.13/sites/13020592-762f-4de4-a25e-f4beb005836e/dataAlerts/e5a4b73e-5cbb-412d-907e-f31cc31684f7" -X DELETE -H "X-Tableau-Auth:12ab34cd56ef78ab90cd12ef34ab56cd"

Delete Database Permissions

Permanently remove the permissions applied to a database asset.

This method is available if your Tableau Online site or Tableau Server is licensed with the Data Management Add-on.

URI

DELETE api/api-version/sites/site-id/databases/database-id/permissions/users/user-id/capability-name/capability-mode

DELETE api/api-version/sites/site-id/databases/database-id/permissions/groups/group-id/capability-name/capability-mode

Parameter Values

api-version The version of the API to use, such as 3.13. For more information, see REST API and Resource Versions.
site-id The unique ID of the site.
database-id The unique ID of the database asset.
user-id The unique ID of the user to remove the permissions for.
group-id The unique ID of the group to remove the permissions for.
capability-name The explicit permissions capability to remove. Capabilities that can be removed are Read, Write, or ChangePermissions.
capability-mode The permissions mode to remove. Modes that can be removed are Allow or Deny.

Request Body

None

Permissions

If Tableau Server or Tableau Online is licensed through the Data Management Add-on, the following authorized users have permissions to delete the permissions on the database asset:

  • Tableau Server admins or Tableau Online site admins
  • Authorized users who have been granted explicit permission to set or "ChangePermissions" to the asset metadata

Response Code

200

Response Body

None

Version

Version 3.5 and later. For more information, see REST API and Resource Versions.

Errors

HTTP status error Code Condition Details
400 400120 Bad request Permissions could not be deleted because support for explicit permissions is available for database assets associated with published data sources only.
401 401000 Unauthorized access No authorization credentials were provided.
401 401002 Unauthorized access Invalid authorization credentials were provided.
403 403117 Database locked Permissions for the database asset cannot be deleted because the database asset is locked.
404 404000 Resource not found The site ID in the URI doesn't correspond to an existing site.
404 404031 Database not found The requested database could not be found.
409 409045 Database error An unknown database asset error occurred.
409 409051 Database update forbidden A user without "write" permissions to the database asset attempted an update.

Delete Default Database Permissions

Permanently remove the default permissions on a database asset.

Removing the default permissions from the database asset means that any new child table assets that are indexed by Catalog won't have any default permissions set.

This method is available if your Tableau Online site or Tableau Server is licensed with the Data Management Add-on.

URI

DELETE api/api-version/sites/site-id/databases/database-id/default-permissions/tables/users/user-id/capability-mode

DELETE api/api-version/sites/site-id/databases/database-id/default-permissions/tables/groups/group-id/capability-mode

Parameter Values

api-version The version of the API to use, such as 3.13. For more information, see REST API and Resource Versions.
site-id The unique ID of the site asset.
database-id The unique ID of the database asset.

Request Body

None

Permissions

If Tableau Server or Tableau Online is licensed through the Data Management Add-on, the following authorized users have permissions to delete the permissions on the database asset:

  • Tableau Server admins or Tableau Online site admins
  • Authorized users who have been granted explicit permission to edit or "Write" to the asset metadata

Response Code

200

Response Body

None

Version

Version 3.5 and later. For more information, see REST API and Resource Versions.

Errors

HTTP status error Code Condition Details
400 400120 Bad request Permissions could not be deleted because support for explicit permissions is available for database assets associated with published data sources only.
401 401000 Unauthorized access No authorization credentials were provided.
401 401002 Unauthorized access Invalid authorization credentials were provided.
403 403117 Database locked Default permissions cannot be deleted because the database asset is locked.
404 404000 Resource not found The site ID in the URI doesn't correspond to an existing site.
404 404031 Database not found The requested database could not be found.
409 409045 Database error An unknown database asset error occurred.
409 409051 Database update forbidden A user without "write" permissions to the database asset attempted an update.

Delete Default Permission

Removes default permission capabilities granted to a user or group, for metric, flow, workbook, data source, data role, or lense resources in a project. After deleting default permissions, resources of the type you specify that are added to a project will not have the those capabilities granted for a group or user. If permissions are locked to the project(Link opens in a new window), then the same is true for all existing child content of the project.

URI

Workbooks:

DELETE /api/api-version/sites/site-id/projects/project-id/default-permissions/workbooks/groups/group-id/capability-name/capability-mode

DELETE /api/api-version/sites/site-id/projects/project-id/default-permissions/workbooks/users/user-id/capability-name/capability-mode

Data sources:

DELETE /api/api-version/sites/site-id/projects/project-id/default-permissions/datasources/groups/group-id/capability-name/capability-mode

DELETE /api/api-version/sites/site-id/projects/project-id/default-permissions/datasources/users/group-id/capability-name/capability-mode

Flows:

DELETE /api/api-version/sites/site-id/projects/project-id/default-permissions/flows/groups/group-id/capability-name/capability-mode

DELETE /api/api-version/sites/site-id/projects/project-id/default-permissions/flows/users/user-id/capability-name/capability-mode

Metrics:

DELETE /api/api-version/sites/site-id/projects/project-id/default-permissions/metrics/groups/group-id/capability-name/capability-mode

DELETE /api/api-version/sites/site-id/projects/project-id/default-permissions/metrics/users/user-id/capability-name/capability-mode

Data roles:

DELETE /api/api-version/sites/site-id/projects/project-id/default-permissions/dataroles/groups/group-id/capability-name/capability-mode

DELETE /api/api-version/sites/site-id/projects/project-id/default-permissions/dataroles/users/user-id/capability-name/capability-mode

Lenses:

DELETE /api/api-version/sites/site-id/projects/project-id/default-permissions/lenses/groups/user-id/capability-name/capability-mode

DELETE /api/api-version/sites/site-id/projects/project-id/default-permissions/lenses/users/user-id/capability-name/capability-mode

Parameter Values

api-version The version of the API to use, such as 3.13. For more information, see REST API and Resource Versions.
site-id The ID of the site that contains the project.
project-id The ID of the project to remove the default permission for.
group-id The ID of the group to remove the default permission for.
user-id The ID of the user to remove default permission for.
capability-name

The capability to remove the permissions for.

Valid capabilities for a workbook are AddComment, ChangeHierarchy, ChangePermissions, Delete, ExportData, ExportImage, ExportXml, Filter, Read (view), ShareView, ViewComments, ViewUnderlyingData, WebAuthoring, and Write.

Valid capabilities for a data source are ChangePermissions, Connect, Delete, ExportXml, Read (view), and Write.

For more information, see Permissions.

capability-mode Allow to remove the allow permission, or Deny to remove the deny permission. This value is case sensitive.

Request Body

None

Permissions

Tableau Server users who are not server administrators can remove permissions for a project only if they have ProjectLeader permissions for that project (either explicitly or implicitly).

Response Code

204

Response Body

None

Version

Version 2.1 and later. For more information, see REST API and Resource Versions.

Errors

HTTP status error Code Condition Details
400 400009 Invalid capability The capability in the URI is invalid.

Valid capabilities for a workbook are AddComment, ChangeHierarchy, ChangePermissions, Delete, ExportData, ExportImage, ExportXml, Filter, Read, ShareView, ViewComments, ViewUnderlyingData, WebAuthoring, and Write.

Valid capabilities for a data source are ChangePermissions, Connect, Delete, ExportXml, Read, and Write.

403 403004 Permissions setting forbidden A non-administrator user called this method but doesn't have permissions to remove permissions for the project.
403 403095 Delete permissions for flows forbidden A non-administrator user called this method but doesn't have permissions to remove permissions for the project where the flow is located.
404 404000 Site not found The site ID in the URI doesn't correspond to an existing site.
404 404002 User not found A user ID in the URI doesn't correspond to an existing user.
404 404005 Project not found The project ID in the URI doesn't correspond to an existing project.
404 404012 Group not found A group ID in the URI doesn't correspond to an existing group.
404 404013 Capability not assigned The capability in the URI isn't assigned to the specified user or group.
404 404013 Capability not found The capability in the URI doesn't correspond to a defined capability. This can apply to either an invalid capability name or a capability other than Allow or Deny for any mode value.
404 404027 Flow not found The flow ID in the URI doesn't correspond to an existing flow.
405 405000 Invalid request method Request type was not DELETE.

For more information, see Handling Errors.

Delete Extract Refresh Task

Deletes an extract refresh task.

URI

DELETE /api/api-version/sites/site-id/tasks/extractRefreshes/task-id

Parameter Values

api-version The version of the API to use, such as 3.13. For more information, see REST API and Resource Versions.
site-id The ID of the site that contains the extract refresh task.
task-id The ID of the extract refresh task to remove.

Request Body

None

Permissions

Tableau Server users who are not server administrators or site administrators can delete an extract refresh task for which they have Read (view) and Delete permissions (either explicitly or implicitly).

Response Code

204

Response Body

None

Version

Version 3.6 and later. For more information, see REST API and Resource Versions.

Errors

HTTP status error Code Condition Details
404 404000 Site not found The site ID in the URI doesn't correspond to an existing site.
404 404026 Task not found The task id in the URI doesn't correspond to an existing extract refresh task.
405 405000 Invalid request method Request type was not DELETE.

For more information, see Handling Errors.

Delete Extracts of Embedded Data Sources from a Workbook

Delete all extracts of embedded data sources in a workbook.

Note: Depending on the number and size of extracts, this operation may consume significant server resources. Consider running this command outside of normal business hours.

URI

POST /api/api-version/sites/site-id/workbookss/workbook-id/deleteExtract

Path Parameter Values

api-version The version of the API to use, such as 3.13. For more information, see REST API and Resource Versions.
site-id The LUID of the site.
datasource-id The LUID of the workbook containing the extract to be deleted.

Permissions

Extracts for data sources can be deleted by Tableau server or site administrators, and by users who own the data source or are an owner or leader of the project where the data source resides.

Request Body

<tsRequest>
  <datasources includeAll="true"/>
</tsRequest>
        

Request Parameter Values

None.

Response Code

200

Response Body

None.

Version

Version 3.5 and later. For more information, see REST API and Resource Versions.

Errors

HTTP status error Code Condition Details
400 400000 Bad request The content of the request body is missing or incomplete, or contains malformed XML.
404 404000 Site not found The specified site doesn't correspond to an existing site.
405 405000 Invalid request method Request type was not POST.
409 409070 Invalid request method The data source cannot be extracted because it is file based or in another unsupported form.

For more information, see Handling Errors.

Example

curl "http://MY-SERVER/api/3.13/sites/9a8b7c6d-5e4f-3a2b-1c0d-9e8f7a6b5c4d/datasources/abcd7c6d-5e4f-3a2b-1c0d-9e8f7a6b1234/deleteExtract" -X POST -H "X-Tableau-Auth: oIcGYxkXSBCLLVm91mfITg|jCQSkWoIbUQVwTcH8WUTWD5nCoOf53LE" -d "@delete-extracts-for-workbook.xml"

Content of create-extracts-for-workbook.xml

<tsResponse>
  <datasources includeAll="true" />
</tsRequest>

Response body:

None. Response code is 200.

Delete Flow

Deletes a flow. When a flow is deleted, its associated connections, the output and input steps, any associated scheduled tasks, and run history are also deleted.

URI

DELETE /api/api-version/sites/site-id/flows/flow-id

Parameter Values

api-version The version of the API to use, such as 3.13. For more information, see REST API and Resource Versions.
site-id The ID of the site that contains the flow.
flow-id The ID of the flow to delete.

Request Body

None

Permissions

Tableau Server users who are not server administrators or site administrators can delete a flow for which they have Read (view) and Delete permissions (either explicitly or implicitly).

Response Code

204

Response Body

None

Version

Version 3.3 and later. For more information, see REST API and Resource Versions.

Errors

HTTP status error Code Condition Details
403 403004 Deletion forbidden A non-administrator user called this method but doesn't have Read (view) and Delete permission for the flow.
404 404000 Site not found The site ID or URL namespace in the URI doesn't correspond to an existing site.
404 404027 Flow not found The flow ID in the URI doesn't correspond to an existing flow.
405 405000 Invalid request method Request type was not DELETE.

For more information, see Handling Errors.

Delete Flow from Favorites

Deletes the specified flow from the user's favorites. If the specified flow is not a favorite, the operation has no effect.

URI

DELETE /api/api-version/sites/site-id/favorites/user-id/datasources/datasource-id

Parameter Values

api-version The version of the API to use, such as 3.13. For more information, see REST API and Resource Versions.
site-id The ID of the site that contains the data source.
user-id The ID of the user to remove the favorite from.
datasource-id The ID of the data source to remove from the user's favorites.

Request Body

None

Permissions

Tableau Server users who are not server administrators or site administrators can call this method only if they have Read (view) permissions on the data source (either explicitly or implicitly).

Response Code

204

Response Body

None

Version

Version 3.3 and later. For more information, see REST API and Resource Versions.

Errors

HTTP status error Code Condition Details
403 403004 Forbidden favorites access A non-administrator user attempted to delete a data source from a different user's favorites.
404 404000 Site not found The site ID or URL namespace in the URI doesn't correspond to an existing site.
404 404002 User not found The user ID in the URI doesn't correspond to an existing user
404 404010 Flow not a favorite The flow ID in the URI exists but is not a favorite of the specified user.
404 404027 Data source not found The flow ID in the URI doesn't correspond to an existing flow.
405 405000 Invalid request method Request type was not DELETE.

For more information, see Handling Errors.

Delete Flow Permission

Deletes the specified permission from the specified flow for a group or user.

URI

DELETE /api/api-version/sites/site-id/flows/flow-id/permissions/groups/group-id/capability-name/capability-mode

DELETE /api/api-version/sites/site-id/flows/flow-id/permissions/users/user-id/capability-name/capability-mode

Parameter Values

api-version The version of the API to use, such as 3.13. For more information, see REST API and Resource Versions.
site-id The ID of the site that contains the flow.
flow-id The ID of the flow to remove the permission for.
group-id The ID of the group to remove the permission for.
user-id The ID of the user to remove the permission for.
capability-name The capability to remove the permission for. Valid capabilities for a flow are ChangeHierarchy, ChangePermissions, Delete, Execute, ExportXml (Download), Read (view), and Write.

For more information, see Permissions.

capability-mode Allow to remove the allow permission, or Deny to remove the deny permission. This value is case sensitive.

Request Body

None

Permissions

Tableau Server users who are not server administrators or site administrators can delete permissions from a flow only if they have ChangePermissions permission for flow (either explicitly or implicitly).

Response Code

204

Response Body

None

Version

Version 3.3 and later. For more information, see REST API and Resource Versions.

Errors

HTTP status error Code Condition Details
400 400009 Invalid capability The capability in the URI is invalid for a flow. Valid capabilities for a flow are ChangeHierarchy, ChangePermissions, Delete, Execute, ExportXml (Download), Read (view), and Write.
403 403004 Permissions setting forbidden A non-administrator user called this method but doesn't have permission to set permissions on the flow.
404 404000 Site not found The site ID in the URI doesn't correspond to an existing site.
404 404002 User not found The user ID in the URI doesn't correspond to an existing user.
404 404027 Flow not found The flow ID in the URI doesn't correspond to an existing flow.
404 404012 Group not found The group ID in the URI doesn't correspond to an existing group.
404 404013 Capability not found The capability in the URI doesn't correspond to a defined capability. This can apply to either an invalid capability name or a capability other than Allowor Denyat the end of the URI.
404 404013 Capability not assigned The capability in the URI is not assigned to the specified user or group with the specified mode (Allowor Deny).
405 405000 Invalid request method Request type was not DELETE.

For more information, see Handling Errors.

Delete Group

Deletes the group on a specific site. Deleting a group does not delete the users in group, but users are no longer members of the group. Any permissions that were previously assigned to the group no longer apply.

Note: You cannot delete the All Users group.

URI

DELETE /api/api-version/sites/site-id/groups/group-id

Parameter Values

api-version The version of the API to use, such as 3.13. For more information, see REST API and Resource Versions.
site-id The ID of the site that contains the project.
group-id The ID of the group to delete.

Request Body

None

Permissions

This method can be called by site administrators.

Response Code

204

Response Body

None

Version

Version 2.1 and later. For more information, see REST API and Resource Versions.

Errors

HTTP status error Code Condition Details
404 404000 Site not found The site ID or URL namespace in the URI doesn't correspond to an existing site.
404 404012 Group not found The group ID in the URI doesn't correspond to an existing group or the group is not part of the specified site.
405 405000 Invalid request method Request type was not DELETE.

For more information, see Handling Errors.

Example

curl "http://MY-SERVER/api/3.13/sites/9a8b7c6d-5e4f-3a2b-1c0d-9e8f7a6b5c4d/groups/1a2b3c4d-5e6f-7a8b-9c0d-1e2f3a4b5c6d" -X DELETE -H "X-Tableau-Auth:12ab34cd56ef78ab90cd12ef34ab56cd"

The response contains no body (data) for a successful delete operation. The HTTP response code is 204 if the delete operation succeeded.

Delete Metric

Deletes a specified metric from a site.

URI

DELETE /api/api-version/sites/site-id/metrics/metric-luid

Parameter Values

api-version The version of the API to use, such as 3.13. For more information, see REST API and Resource Versions.
site-id The ID of the site that contains the metric.
metric-luid The unique ID of the metric to remove.

Request Body

None

Permissions

Tableau Server users who are not administrators can delete a metric for which they have explicit or implicit Read (view) and Delete permission.

Response Code

204

Response Body

None

Version

Version 3.9 and later. For more information, see REST API and Resource Versions.

Errors

HTTP status error Code Condition Details
404 404000 Site not found The site ID in the URI doesn't correspond to an existing site.
404 404006 Metric not found The metric ID in the URI doesn't correspond to an existing metric.
405 405000 Invalid request method Request type was not DELETE.

For more information, see Handling Errors.

Example

curl "http://MY-SERVER/api/3.9/sites/9a8b7c6d-5e4f-3a2b-1c0d-9e8f7a6b5c4d/metrics/6561daa3-20e8-407f-ba09-709b178c0b4a" -X DELETE -H "X-Tableau-Auth:12ab34cd56ef78ab90cd12ef34ab56cd"

The response contains no body (data) for a successful delete operation. The HTTP response code is 204 if the delete operation succeeded.

Delete Project

Deletes the specified project on a specific site. When a project is deleted, all of its assets are also deleted: associated workbooks, data sources, project view options, and rights. Use this method with caution.

URI

DELETE /api/api-version/sites/site-id/projects/project-id

Parameter Values

api-version The version of the API to use, such as 3.13. For more information, see REST API and Resource Versions.
site-id The ID of the site that contains the project.
project-id The ID of the project to delete.

Request Body

None

Permissions

This method can only be called by server administrators and site administrators.

Response Code

204

Response Body

None

Version

Version 1.0 and later. For more information, see REST API and Resource Versions.

Errors

HTTP status error Code Condition Details
403 403003 Deletion forbidden Attempt to delete the default project, which cannot be deleted.
404 404000 Site not found The site ID or URL namespace in the URI doesn't correspond to an existing site.
404 404005 Project not found The project ID in the URI doesn't correspond to an existing project or the project is not found on this site.
405 405000 Invalid request method Request type was not DELETE.

For more information, see Handling Errors.

Example

curl "http://MY-SERVER/api/3.13/sites/9a8b7c6d-5e4f-3a2b-1c0d-9e8f7a6b5c4d/projects/1f2f3e4e-5d6d-7c8c-9b0b-1a2a3f4f5e6e" -X DELETE -H "X-Tableau-Auth:12ab34cd56ef78ab90cd12ef34ab56cd"

The response contains no body (data) for a successful delete operation. The HTTP response code is 204 if the delete operation succeeded.

Delete Project from Favorites

Deletes the specified project from the user's favorites. If the specified project is not a favorite, the operation has no effect.

URI

DELETE /api/api-version/sites/site-id/favorites/user-id/projects/project-id

Parameter Values

api-version The version of the API to use, such as 3.13. For more information, see REST API and Resource Versions.
site-id The ID of the site that contains the project.
user-id The ID of the user to remove the favorite from.
project-id The ID of the project to remove from the user's favorites.

Request Body

None

Permissions

Tableau Server users who are not server administrators or site administrators can delete a project only from their own favorites.

Response Code

204

Response Body

None

Version

Version 3.1 and later. For more information, see REST API and Resource Versions.

Errors

HTTP status error Code Condition Details
403 403004 Forbidden favorites access A non-administrator user attempted to delete a project from a different user's favorites.
404 404000 Site not found The site ID or URL namespace in the URI doesn't correspond to an existing site.
404 404002 User not found The user ID in the URI doesn't correspond to an existing user.
404 404005 Project not found The project ID in the URI doesn't correspond to an existing project.
405 405000 Invalid request method Request type was not DELETE.

For more information, see Handling Errors.

Example

curl "http://MY-SERVER/api/3.13/sites/1edc53ac-e247-4870-9fd3-6fad0ce5f84d/favorites/9a4ebbab-9ec8-487a-9b48-47fa81d6077a/projects/89a82d78-664f-45a1-8256-d4d2961a070b" -X DELETE -H "X-Tableau-Auth:12ab34cd56ef78ab90cd12ef34ab56cd"

Delete Project Permission

Removes the specified project permission for the specified group or user.

URI

DELETE /api/api-version/sites/site-id/projects/project-id/permissions/groups/group-id/capability-name/capability-mode

DELETE /api/api-version/sites/site-id/projects/project-id/permissions/users/user-id/capability-name/capability-mode

Parameter Values

api-version The version of the API to use, such as 3.13. For more information, see REST API and Resource Versions.
site-id The ID of the site that contains the project.
project-id The ID of the project to remove the permission for.
group-id The ID of the group to remove the permission for.
user-id The ID of the user to remove project the permission for.
capability-name The capability to remove the permission for. In Tableau Server 10.0, valid capabilities for a project are ProjectLeader, Read (view), and Write.

For more information, see Permissions.

capability-mode Allow to remove the allow permission, or Deny to remove the deny permission. This value is case sensitive.

Request Body

None

Permissions

Tableau Server users who are not server administrators or site administrators can remove permissions for a project only if they have ChangePermissions (version 2.0) or ProjectLeader (version 2.1) permissions for that project (either explicitly or implicitly).

Response Code

204

Response Body

None

Version

Version 2.0 and later. For more information, see REST API and Resource Versions.

Errors

HTTP status error Code Condition Details
400 400009 Invalid capability The capability in the URI is invalid for a project. For a list of valid capabilities, see the capability-name attribute earlier.
403 403004 Permissions setting forbidden A non-administrator user called this method but doesn't have permissions to remove default permissions for the project.
403 403004 Delete forbidden A non-administrative user tried to update the project, but does not have permissions to the project.
404 404000 Site not found The site ID in the URI doesn't correspond to an existing site.
404 404002 User not found A user ID in the URI doesn't correspond to an existing user.
404 404005 Project not found The project ID in the URI doesn't correspond to an existing project.
404 404012 Group not found A group ID in the URI doesn't correspond to an existing group.
404 404013 Capability not assigned The capability in the URI isn't assigned to the specified user or group.
404 404013 Capability not found The capability in the URI doesn't correspond to a defined capability. This can apply to either an invalid capability name or a capability other than Allow or Deny for any mode value.
405 405000 Invalid request method Request type was not DELETE.

For more information, see Handling Errors.

Delete Quality Warning Trigger by ID

Permanently remove a quality warning trigger using the quality warning trigger ID.

This method is available if your Tableau Online site or Tableau Server is licensed with the Data Management Add-on.

URI

DELETE api/api-version/sites/site-id/dataQualityTriggers/trigger-id

Parameter Values

api-version The version of the API to use, such as 3.13. For more information, see REST API and Resource Versions.
site-id The unique ID of the site asset.
trigger-id

The unique ID of the quality warning trigger.

Permissions

If Tableau Server or Tableau Online is licensed through the Data Management Add-on, the following users have permissions to delete a quality warning trigger:

  • Tableau Server admins or Tableau Online site admins
  • Authorized users who have been granted explicit permission to edit or "Write" to the asset metadata

Response Code

200

Response Body

None

Version

Version 3.11 and later. For more information, see REST API and Resource Versions.

Errors

HTTP status error Code Condition Details
400 400138 Generic quality warning trigger error The quality warning trigger could not be deleted for some other reason than those specified below.
403 403004 Unauthorized operation Insufficient permissions to perform the operation.
404 404037 Quality warning not found The requested quality warning trigger was not found.
409 409004 Invalid parameter One or more values in the request body are invalid.

Delete Quality Warning Triggers by Content

Permanently remove all quality warning triggers for one or more data sources or flows, or both.

This method is available if your Tableau Online site or Tableau Server is licensed with the Data Management Add-on.

URI

Delete one quality warning trigger

DELETE api/api-version/sites/site-id/dataQualityTriggers/content-type/contentIds?filter=contentId:in:[content-luid]

Delete multiple quality warning triggers

DELETE api/api-version/sites/site-id/dataQualityTriggers/content-type/contentIds?filter=contentId:in:[content-luid1,content-luid2,content-luid3,...]

Parameter Values

api-version The version of the API to use, such as 3.13. For more information, see REST API and Resource Versions.
site-id The unique ID of the site asset.
content-type

The type of content the quality warning trigger has been applied to. In this case, use one of the following values:

  • datasource
  • flow

These values are not case sensitive.

content-luid The unique ID of the asset. This is the same as the content ID.

Permissions

If Tableau Server or Tableau Online is licensed through the Data Management Add-on, the following users have permissions to delete quality warning triggers:

  • Tableau Server admins or Tableau Online site admins
  • Authorized users who have been granted explicit permission to edit or "Write" to the asset metadata

Response Code

200

Response Body

None

Version

Version 3.10 and later. For more information, see REST API and Resource Versions.

Errors

HTTP status error Code Condition Details
400 400138 Generic quality warning trigger error The quality warning trigger could not be deleted for some other reason than those specified below.
403 403004 Unauthorized operation Insufficient permissions to perform the operation.
404 404037 Quality warning not found The requested quality warning trigger was not found.
409 409004 Invalid parameter One or more values in the request body are invalid.

Delete Schedule

Deletes the specified schedule.

URI

DELETE /api/api-version/schedules/schedule-id

Parameter Values

api-version The version of the API to use, such as 3.13. For more information, see REST API and Resource Versions.
schedule-id The ID of the schedule to delete. To determine what schedules are available, call Query Schedules.

Request Body

None

Permissions

This method can only be called by server administrators.

Response Code

204

Response Body

None

Version

Version 2.3 and later. For more information, see REST API and Resource Versions.

Errors

HTTP status error Code Condition Details
400 400059 Error deleting the schedule. An unspecified error occured during the deletion operation.
404 404023 Schedule not found The specified schedule doesn't correspond to an existing schedule on the site.
405 405000 Invalid request method Request type was not DELETE.

For more information, see Handling Errors.

Delete Server Session

Deletes a specified session. This method is not available for Tableau Online and is typically used in programmatic management of the life cycles of embedded Tableau sessions.

URI

DELETE api/api-version/sessions/session-id

Parameter Values

api-version The version of the API to use, such as 3.13. For more information, see REST API and Resource Versions.
session-id

The unique ID of the session to be deleted. A session's ID and other metadata can be queried from the Tableau Server Postgres repository.

Reading the Postgres repository excessively can impact performance and that writing directly to the repository is not supported in any form. For more information, see Collect Data with the Tableau Server Repository and Tableau Server Postgres Data Dictionary.

Request Body

None.

Permissions

This method can only be called by server administrators.

Response Code

204

Response Body

None

Version

Version 3.9 and later. For more information, see REST API and Resource Versions.

Errors

HTTP status error Code Condition Details
400 400000 Bad request The content of the request body is missing or incomplete, or contains malformed XML.
400 400105 Session delete error An unknown error occurred and the session could not be deleted.
401 401000 Unauthorized access No authorization credentials were provided.
401 401002 Unauthorized access Invalid authorization credentials were provided.
404 404000 Resource not found The site ID in the URI doesn't correspond to an existing site.
404 404029 Content not found The requested asset could not be found.

Delete Site

Deletes the specified site.

You can specify the site to delete by using the site ID, the site name, or the content URL. You use the key query string parameter to indicate how you are specifying the site, as shown in the URIs.

Note: You must have previously called Sign In and signed in to a site in order to delete the site. (When you call this method, you must include the authentication token that you got back when you signed into the site.)

URI

DELETE /api/api-version/sites/site-id

DELETE /api/api-version/sites/site-name?key=name

DELETE /api/api-version/sites/content-url?key=contentUrl

Parameter Values

api-version The version of the API to use, such as 3.13. For more information, see REST API and Resource Versions.
site-id The ID of the site to delete.
site-name The name of the site to delete. If you specify a site name, you must also include the parameter key=name.
content-url The URL of the site to delete. If you specify a content URL, you must also include the parameter key=contentUrl.

Request Body

None

Permissions

This method can only be called by server administrators.

Response Code

204

Response Body

None

Version

Version 1.0 and later. For more information, see REST API and Resource Versions.

Errors

HTTP status error Code Condition Details
403 403002 Deletion not allowed. An attempt was made to delete the default Tableau Server site.
404 404000 Site not found The specified site doesn't correspond to an existing site.
405 405000 Invalid request method Request type was not DELETE.

For more information, see Handling Errors.

Example

curl "http://MY-SERVER/api/3.13/sites/9a8b7c6d5-e4f3-a2b1-c0d9-e8f7a6b5c4d" -X DELETE -H "X-Tableau-Auth:12ab34cd56ef78ab90cd12ef34ab56cd"

curl "http://MY-SERVER/api/3.13/sites/marketing-site?key=contentUrl" -X DELETE -H "X-Tableau-Auth:12ab34cd56ef78ab90cd12ef34ab56cd"

The response contains no body (data) for a successful delete operation. The HTTP response code is 204 if the delete operation succeeded.

Delete Subscription

Deletes the specified subscription.

URI

DELETE /api/api-version/sites/site-id/subscriptions/subscription-id

Parameter Values

api-version The version of the API to use, such as 3.13. For more information, see REST API and Resource Versions.
site-id The ID of the site that contains the subscription.
subscription-id The ID of the subscription to delete. To determine what subscriptions are available, call Query Subscriptions.

Request Body

None

Permissions

Tableau Server users can call this method to delete any subscription that they had permission to create. For details, see Create Subscription.

Response Code

204

Response Body

None

Version

Version 2.3 and later. For more information, see REST API and Resource Versions.

Errors

HTTP status error Code Condition Details
400 400062 Error deleting the subscription. An unspecified error occured during the deletion operation.
401 401002 User not authenticated. The user making the request has not been authenticated for this site.
403 403059 Delete forbidden. A non-administrator user called this method but doesn't have permission to delete the subscription.
404 404000 Site not found The specified site doesn't correspond to an existing site.
405 405000 Invalid request method Request type was not DELETE.

For more information, see Handling Errors.

Delete Table Permissions

Permanently remove the permissions applied to a table asset.

This method is available if your Tableau Online site or Tableau Server is licensed with the Data Management Add-on.

URI

DELETE api/api-version/sites/site-id/table/table-id/permissions

Parameter Values

api-version The version of the API to use, such as 3.13. For more information, see REST API and Resource Versions.
site-id The unique ID of the site asset.
table-id The unique ID of the table asset.

Request Body

None

Permissions

If Tableau Server or Tableau Online is licensed through the Data Management Add-on, the following users have permissions to delete the permissions on a table asset:

  • Tableau Server admins or Tableau Online site admins
  • Authorized users who have been granted explicit permission to set or "ChangePermissions" to the asset metadata

Response Code

204

Response Body

None

Version

Version 3.5 and later. For more information, see REST API and Resource Versions.

Errors

HTTP status error Code Condition Details
400 400120 Bad request Permissions could not be deleted because support for explicit permissions is available for table assets associated with published data sources only.
401 401000 Unauthorized access No authorization credentials were provided.
401 401002 Unauthorized access Invalid authorization credentials were provided.
403 403117 Database locked Permissions for the table asset cannot be deleted because the database asset is locked.
404 404000 Resource not found The site ID in the URI doesn't correspond to an existing site.
409 409051 Database update forbidden A user without "write" permissions to the database asset attempted an update.

Delete Tag from Column

Delete a tag from a column.

For more information about tags, see Tag Items(Link opens in a new window) in the Tableau User Help.

URI

DELETE api/api-version/sites/site-id/columns/column-id/tags/tag-name

Parameter Values

api-version The version of the API to use, such as 3.13. For more information, see REST API and Resource Versions.
site-id The unique ID of the site asset.
column-id The unique ID of the column asset.
tag-name The keyword text of the tag.

Request Body

None

Permissions

If Tableau Server or Tableau Online is licensed through the Data Management Add-on, the following users have permissions to delete tags:

  • Tableau Server admins or Tableau Online site admins
  • Authorized users who have been granted explicit permission to edit or "Write" to the asset metadata

Response Code

204

Response Body

None

Version

Version 3.9 and later. For more information, see REST API and Resource Versions.

Errors

HTTP status error Code Condition Details
403 403004 Unauthorized operation Insufficient permissions to perform the operation.
404 404007 Tag not found The tag does not exist.
409 409062 Generic database tag error The tag or tags could not be deleted (or added) for some other reason than those specified in this table.
409 409066 Column not found The column asset does not exist.

Delete Tag from Data Source

Deletes a tag from the specified data source.

URI

DELETE /api/api-version/sites/site-id/datasources/datasource-id/tags/tag-name

Parameter Values

api-version The version of the API to use, such as 3.13. For more information, see REST API and Resource Versions.
site-id The ID of the site that contains the data source.
datasource-id The ID of the data source to remove the tag from.
tag-name The name of the tag to remove from the data source.

Request Body

None

Permissions

Tableau Server users who are not server administrators, site administrators, or data source owners can delete a tag from a data source only if they are project leaders or if they originally added the tag.

Response Code

204

Response Body

None

Version

Version 1.0 and later. For more information, see REST API and Resource Versions.

Errors

HTTP status error Code Condition Details
400 400077 Error deleting tag There was a problem deleting the tag from the specified data source.
403 403004 Deleting tags forbidden A non-administrator user called this method but doesn't have permission to delete a tag from the specified data source.
404 404000 Site not found The site ID or URL namespace in the URI doesn't correspond to an existing site.
404 404004 Data source not found The data source ID in the URI doesn't correspond to an existing data source.
404 404007 Tag not found The tag in the URI doesn't exist for the specified data source.
405 405000 Invalid request method Request type was not DELETE.

For more information, see Handling Errors.

Delete Tag from Database

Delete a tag from a database.

For more information about tags, see Tag Items(Link opens in a new window) in the Tableau User Help.

URI

DELETE api/api-version/sites/site-id/databases/database-id/tags/tag-name

Parameter Values

api-version The version of the API to use, such as 3.13. For more information, see REST API and Resource Versions.
site-id The unique ID of the site asset.
database-id The unique ID of the database asset.
tag-name The keyword text of the tag.

Request Body

None

Permissions

If Tableau Server or Tableau Online is licensed through the Data Management Add-on, the following users have permissions to delete tags:

  • Tableau Server admins or Tableau Online site admins
  • Authorized users who have been granted explicit permission to edit or "Write" to the asset metadata

Response Code

204

Response Body

None

Version

Version 3.9 and later. For more information, see REST API and Resource Versions.

Errors

HTTP status error Code Condition Details
403 403004 Unauthorized operation Insufficient permissions to perform the operation.
404 404007 Tag not found The tag does not exist.
404 404031 Database not found The database asset does not exist.
409 409048 Generic database tag error The tag or tags could not be deleted (or added) for some other reason than those specified above.

Delete Tag from Table

Delete a tag from a table.

For more information about tags, see Tag Items(Link opens in a new window) in the Tableau User Help.

URI

DELETE api/api-version/sites/site-id/tables/table-id/tags/tag-name

Parameter Values

api-version The version of the API to use, such as 3.13. For more information, see REST API and Resource Versions.
site-id The unique ID of the site asset.
table-id The unique ID of the table asset.
tag-name The keyword text of the tag.

Request Body

None

Permissions

If Tableau Server or Tableau Online is licensed through the Data Management Add-on, the following users have permissions to delete tags:

  • Tableau Server admins or Tableau Online site admins
  • Authorized users who have been granted explicit permission to edit or "Write" to the asset metadata

Response Code

204

Response Body

None

Version

Version 3.9 and later. For more information, see REST API and Resource Versions.

Errors

HTTP status error Code Condition Details
403 403004 Unauthorized operation Insufficient permissions to perform the operation.
404 404007 Tag not found The tag does not exist.
404 404032 Table not found The table asset does not exist.
409 409055 Generic database tag error The tag or tags could not be deleted (or added) for some other reason than those specified above.

Delete Tag from View

Deletes a tag from the specified view.

URI

DELETE /api/api-version/sites/site-id/views/view-id/tags/tag-name

Parameter Values

api-version The version of the API to use, such as 3.13. For more information, see REST API and Resource Versions.
site-id The ID of the site that contains the workbook.
view-id The ID of the view to remove the tag from.
tag-name The name of the tag to remove from the view.

Request Body

None

Permissions

Tableau Server users who are not server administrators, site administrators, or workbook owners can delete a tag from a workbook only if they are project leaders or if they originally added the tag.

Response Code

204

Response Body

None

Version

Version 1.0 and later. For more information, see REST API and Resource Versions.

Errors

HTTP status error Code Condition Details
400 400078 Error deleting tag There was a problem deleting the tag from the specified view.
403 403004 Deleting tags forbidden A non-administrator user called this method but doesn't have permission to delete a tag from the specified workbook.
404 404000 Site not found The site ID or URL namespace in the URI doesn't correspond to an existing site.
404 404006 Workbook not found The workbook ID in the URI doesn't correspond to an existing workbook.
404 404007 Tag not found The tag in the URI doesn't exist for the specified workbook.
405 405000 Invalid request method Request type was not DELETE.

For more information, see Handling Errors.

Delete Tag from Workbook

Deletes a tag from the specified workbook.

URI

DELETE /api/api-version/sites/site-id/workbooks/workbook-id/tags/tag-name

Parameter Values

api-version The version of the API to use, such as 3.13. For more information, see REST API and Resource Versions.
site-id The ID of the site that contains the workbook.
workbook-id The ID of the workbook to remove the tag from.
tag-name The name of the tag to remove from the workbook.

Request Body

None

Permissions

Tableau Server users who are not server administrators, site administrators, or workbook owners can delete a tag from a workbook only if they are project leaders or if they originally added the tag.

Response Code

204

Response Body

None

Version

Version 1.0 and later. For more information, see REST API and Resource Versions.

Errors

HTTP status error Code Condition Details
400 400051 Error deleting tag There was a problem deleting the tag from the specified workbook.
403 403004 Deleting tags forbidden A non-administrator user called this method but doesn't have permission to delete a tag from the specified workbook.
404 404000 Site not found The site ID or URL namespace in the URI doesn't correspond to an existing site.
404 404006 Workbook not found The workbook ID in the URI doesn't correspond to an existing workbook.
404 404007 Tag not found The tag in the URI doesn't exist for the specified workbook.
405 405000 Invalid request method Request type was not DELETE.

For more information, see Handling Errors.

Delete the Extract from a Data Source

Delete the extract of a data source in a site.

URI

POST /api/api-version/sites/site-id/datasources/datasource-id/deleteExtract

Parameter Values

api-version The version of the API to use, such as 3.13. For more information, see REST API and Resource Versions.
site-id The LUID of the site.
datasource-id The LUID of the datasource whose extract is to be deleted.

Permissions

Extracts for data sources can be deleted by Tableau server or site administrators, and by users who own the data source or are an owner or leader of the project where the data source resides.

Response Code

204 No Content

Response Body

None.

Version

Version 3.5 and later. For more information, see REST API and Resource Versions.

Errors

HTTP status error Code Condition Details
400 400000 Bad request The content of the request body is missing or incomplete, or contains malformed XML.
404 404000 Site not found The specified site doesn't correspond to an existing site.
405 405000 Invalid request method Request type was not POST.
409 409070 Invalid request method The data source cannot be extracted because it is file based or in another unsupported form.

For more information, see Handling Errors.

Example

curl "http://MY-SERVER/api/3.13/sites/9a8b7c6d-5e4f-3a2b-1c0d-9e8f7a6b5c4d/datasources/abcd7c6d-5e4f-3a2b-1c0d-9e8f7a6b1234/deleteExtract" -X POST -H "X-Tableau-Auth: oIcGYxkXSBCLLVm91mfITg|jCQSkWoIbUQVwTcH8WUTWD5nCoOf53LE"

Response body:

None.

Delete User from Data-Driven Alert

Removes a specified user from the recipients list for a data-driven alert.

URI

DELETE /api/api-version/sites/site-id/dataAlerts/data-alert-id/users/user-id

Parameter Values