Skip to content

Latest commit

 

History

History
281 lines (192 loc) · 17.1 KB

README.md

File metadata and controls

281 lines (192 loc) · 17.1 KB

Tableau Public API Documentation

Status GitHub Issues GitHub Pull Requests License

This repo for documenting Tableau Public's API and details of its various API calls.

Twitter 💬   |   LinkedIn 👔   |   GitHub :octocat:   |   Website 🔗

🅰️ About

Tableau Public is the free version of Tableau's Desktop product, it allows for the creation and distribution of Tableau dashboards. The Tableau Public platform has an API for handling data relating to user profiles and workbooks (dashboards). This API can be accessed via a web browser or a programming language (R, Python, JavaScript).

Thanks to Jeffrey Shaffer's blog post & Marc Reid's blog post for sharing this information that acting as the starting point for this documentation.

📥 Known API calls

🎁 Project Walkthroughs

🙌 Community Services

💾 Data sets

📥 Tableau Public API Calls

👤 Profile

API call output
Retrieve basic counts of workbooks, followers, following, favourites, details of websites, whether they have the "hire me" button on their profile (freelance), social media links and the last 21 workbooks associated to a Tableau Public username. Returned as a JSON.

API call format
https://public.tableau.com/profile/api/ + Tableau Public Username

Example API call
https://public.tableau.com/profile/api/wjsutton

Note a basic user profile description query is available via:
https://public.tableau.com/public/apis/authors?profileName=wjsutton

📚 Workbooks

API call output
Retrieves details of the last 50 workbooks associated to a Tableau Public username. Returned as a JSON.

Note that the next 50 workbooks can be retrieved by changing the start section to start=50 or start=100, start=150, etc.

In Feb 2023 a visibility parameter has been added,'&visibility=NON_HIDDEN' which will only allow the API to reach visible workbooks on a user's profile.

API call format
First 50 workbooks: https://public.tableau.com/public/apis/workbooks?profileName= + Tableau Public Username + &start=0&count=50&visibility=NON_HIDDEN

Next 50 workbooks: https://public.tableau.com/public/apis/workbooks?profileName= + Tableau Public Username + &start=50&count=50&visibility=NON_HIDDEN

Example API call
https://public.tableau.com/public/apis/workbooks?profileName=wjsutton&start=0&count=50&visibility=NON_HIDDEN

👥 Followers

API call output
Retrieves a list of followers for a Tableau Public User, returns usernames, user metadata, details of their latest workbook. Note that the count of accounts appears to be now limited to 24 per call, i.e. count=24 will return up to 24 accounts, count=24&index=24 will return the next 24 accounts.

API call format
Get 24 followers: https://public.tableau.com/profile/api/followers/ + Tableau Public Username + ?count=24&index=0
Get next 24 followers: https://public.tableau.com/profile/api/followers/ + Tableau Public Username + ?count=24&index=24

Example API call
https://public.tableau.com/profile/api/followers/wjsutton?count=24&index=0

👥 Following

API call output
Retrieves a list of accounts being followed by a Tableau Public User, returns usernames, user metadata, details of their latest workbook. Note that the count of accounts appears to be now limited to 24 per call, i.e. count=24 will return up to 24 accounts, count=24&index=24 will return the next 24 accounts.

API call format
Get 24 following: https://public.tableau.com/profile/api/following/ + Tableau Public Username + ?count=24&index=0
Get next 24 following: https://public.tableau.com/profile/api/following/ + Tableau Public Username + ?count=24&index=24

Example API call
https://public.tableau.com/profile/api/following/wjsutton?count=24&index=0

⭐ Favourites

API call output
Returns a list of workbookRepoUrls favourited by a Tableau Public User, in JSON format.

API call format
https://public.tableau.com/profile/api/favorite/ + Tableau Public Username + /workbook?

Example API call
https://public.tableau.com/profile/api/favorite/wjsutton/workbook?

📚 Workbook Image

API call output
Returns a screenshot image of the entire dashboard.

UPDATE
Thanks to Kelly Gilbert there is a more reliable API call for a fullscreen image.
"https://public.tableau.com/views/WORKBOOKNAME/VIEWNAME.png?%3Adisplay_static_image=y&:showVizHome=n"

API call format
https://public.tableau.com/views/+ Workbook Repo Url + / + Default View Name (Excluding spaces & fullstops) + .png?%3Adisplay_static_image=y&:showVizHome=n
OLD Version: https://public.tableau.com/static/images/ + First 2 Letters of Workbook Repo Url + / + Workbook Repo Url + / + Default View Name (Excluding spaces & fullstops) + /1.png

Example API call
https://public.tableau.com/views/RunningforOlympicGold/RunningforOlympicGold.png?%3Adisplay_static_image=y&:showVizHome=n
OLD Version:https://public.tableau.com/static/images/Ru/RunningforOlympicGold/RunningforOlympicGold/1.png

📚 Workbook Thumbnail

API call output
Returns a thumbnail-sized image, typically found on a Tableau Public author's page. Note there are two different calls to produce a thumbnail image.

API call format
https://public.tableau.com/thumb/views/ + Workbook Repo Url + / + Default View Name (Excluding spaces & fullstops)
Alternative Call:
https://public.tableau.com/static/images/ + First 2 Letters of Workbook Repo Url + / + Workbook Repo Url + / + Default View Name (Excluding spaces & fullstops) + /4_3.png

Example API call
https://public.tableau.com/thumb/views/RunningforOlympicGold/RunningforOlympicGold
Alternative Call: https://public.tableau.com/static/images/Ru/RunningforOlympicGold/RunningforOlympicGold/4_3.png

📚 Workbook Details

API call output
Returns a details of a single workbook based on WorkbookRepoUrl, used in the favourites section of the Tableau Public profile to look up details of a workbook e.g. views, titles, etc.

API call format
https://public.tableau.com/profile/api/single_workbook/ + Workbook Repo Url + ?

Example API call
https://public.tableau.com/profile/api/single_workbook/RunningforOlympicGold?

📚 Workbook Contents

API call output
Returns details of a single workbook based on WorkbookRepoUrl, returns some metadata about the workbook (author, titles) and all visible sheets/dashboards/stories packaged with the workbook as found under the "Metadata" section when viewing a viz on Tableau Public. These are found under the viewInfos section, they list out a sheetRepoUrlwe can be modified to produce a URL to that sheet/dashboard/story, e.g.
sheetRepoUrl: VizConnect-SmallDesignChoicesThatMakeaBigDifference/sheets/IncreasingWhiteSpace-Borders
URL: https://public.tableau.com/profile/simon.beaumont#!/vizhome/VizConnect-SmallDesignChoicesThatMakeaBigDifference/IncreasingWhiteSpace-Borders

API call format
https://public.tableau.com/profile/api/workbook/ + Workbook Repo Url + ?

Example API call
https://public.tableau.com/profile/api/workbook/VizConnect-SmallDesignChoicesThatMakeaBigDifference?

📚 Related Workbooks

Discovered by Chris Meardon

API call output
Returns a list of workbooks (max 20) related to a queried workbook.

API call format
https://public.tableau.com/public/apis/bff/workbooks/v2/ + Workbook Repo Url /recommended-workbooks? + count= n

Example API call
https://public.tableau.com/public/apis/bff/workbooks/v2/RunningforOlympicGold/recommended-workbooks?count=20

📚 Shared Workbooks

Discovered by a "friend of the repo"

API call output
Returns source workbook details for a shared workbook url.

API call format
https://public.tableau.com/profile/api/workbook/shared/ + Share_id

Example API call
https://public.tableau.com/profile/api/workbook/shared/3QJBD7FYC

📓 Featured Authors

API call output
Returns a Tableau Public profile name and bio of their featured authors as JSON.

API call format
https://public.tableau.com/s/authors/list/feed?

Example API call
https://public.tableau.com/s/authors/list/feed?

📈 VOTD Dashboards

API call output
Returns a list of the most recent VOTD winners from the page https://public.tableau.com/app/discover/viz-of-the-day

API call format
https://public.tableau.com/public/apis/bff/discover/v1/vizzes/viz-of-the-day?page= + Page Number + &limit= + Number of VOTDs (max 12)
Note to get all VOTDs you will need to iterate through page numbers, increasing by one until no more results are returned.

Example API call
Get last 12 VOTDs: https://public.tableau.com/public/apis/bff/discover/v1/vizzes/viz-of-the-day?page=0&limit=12
Get next 12 VOTDs: https://public.tableau.com/public/apis/bff/discover/v1/vizzes/viz-of-the-day?page=1&limit=12

📈 Historical VOTD Dashboards | DOES NOT WORK ANYMORE

Historical API call output | DOES NOT WORK ANYMORE

Returns a list of the most recent VOTD winners from the page:
https://public.tableau.com/en-us/gallery/?tab=viz-of-the-day&type=viz-of-the-day

In addition there is a list of featured vizzes on the page
https://public.tableau.com/en-us/gallery/?tab=featured&type=featured

Historical API call format | DOES NOT WORK ANYMORE
https://public.tableau.com/api/gallery?page=0&count= + Number of VOTDs + &galleryType=viz-of-the-day&language=en-us

For featured vizzes:
https://public.tableau.com/api/gallery?page=0&count= + Number of Vizzes + &galleryType=featured&language=en-us

Historical Example API call | DOES NOT WORK ANYMORE
Get last 100 VOTDs: https://public.tableau.com/api/gallery?page=0&count=100&galleryType=viz-of-the-day&language=en-us
Get last 100 featured vizzes: https://public.tableau.com/api/gallery?page=0&count=100&galleryType=featured&language=en-us

💾 Dataset | NO LONGER UPDATED DUE API CHANGE
Tableau Public's Viz of the Day : Google Sheets

🔍 Search Results

API call output
Returns a list of the top search results for a given query as per the search page https://public.tableau.com/en-us/search/vizzes/

API call format
https://public.tableau.com/api/search/query?count= + Number of Results + &language=en-us&query= + Search Term +&start= + Start at Viz Number + &type= + vizzes/authors

Example API call
Get top 100 Maps Search Results: https://public.tableau.com/api/search/query?count=20&language=en-us&query=maps&start=0&type=vizzes