The TSC samples are included in the samples directory of the TSC repository on Github.

Run the samples

Each of the samples accepts the following arguments:

To get a token-name and token-value, you will have to create personal access token first. You can follow Tableau’s documentation to do so.

Some of the samples also require additional arguments. For more information about the arguments required by a particular sample, run the sample with the -h flag.

For example, if you run the following command:

python samples/ -h

You will see that you need to enter a file path for the workbook that you want to publish.

Samples list

The following list describes the samples available in the repository:

Note: For all of the samples, ensure that your Tableau Server user account has permission to access the resources. Also keep in mind that some example operations (like create group) are not allowed on Tableau Online.