Tableau has an ever-growing list of Application Programming Interfaces (APIs) that we as developers can leverage to add functionality to Tableau; personally speaking, this is the most exciting part of the Tableau ecosystem. In this article, I want to highlight the various APIs out there which are available for you to use.
Application Programming Interfaces (APIs)
In computer programming, an application programming interface (API) is a set of subroutine definitions, communication protocols, and tools for building software. In general terms, it is a set of clearly defined methods of communication among various components. A good API makes it easier to develop a computer program by providing all the building blocks, which are then put together by the programmer. So in English, this means a set of tools that can be used to build things based on defined functionality.
Tableau Magic Article:
The Tableau Extensions API allows developers can create dashboard extensions that enable customers to integrate and interact with data from other applications directly in Tableau; you can create additional visual components, integrate with applications, or even write back to a database. We see a lot of growth in this area in the future and it will be something that more and more people will want to use.
- Extension API on Github: https://tableau.github.io/extensions-api
- Extension Gallery: https://extensiongallery.tableau.com
- Use Dashboard Extensions: https://onlinehelp.tableau.com/current/pro/desktop/en-gb/dashboard_extensions.htm
Tableau Magic Articles:
- Creating a Tableau Extension Part One: https://tableaumagic.com/creating-a-tableau-extensions-part-one
- Creating a Tableau Extension Part Two: https://tableaumagic.com/creating-a-tableau-extension-part-two
- Creating a Tableau Extension Part Three: https://tableaumagic.com/creating-a-tableau-extension-part-three
- Creating a Tableau Extension Part Four: https://tableaumagic.com/creating-a-tableau-extension-part-four
Representational State Transfer (REST) is a software architectural style that defines a set of constraints to be used for creating Web services. Web services that conform to the REST architectural style, called RESTful Web services (RWS), provide interoperability between computer systems on the Internet. RESTful Web services allow the requesting systems to access and manipulate textual representations of Web resources by using a uniform and predefined set of stateless operations. Other kinds of Web services, such as SOAP Web services, expose their own arbitrary sets of operations.
With the Tableau Server REST API, you can manage and change Tableau Server resources programmatically, using 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.
- Tableau UI: https://tableau.github.io/tableau-ui
Tableau Magic Articles:
- Tableau UI / An Introduction: http://tableaumagic.com/tableau-ui-an-introduction
Webhooks (Developer Preview)
Webhooks let you build custom applications or workflows that react to events that happen in Tableau Online. For example, you could use webhooks to send an SMS or Slack notification any time a data source refresh fails, or fire off a confetti cannon when a new workbook is created. For the initial release of this developer preview, webhooks are supported for data source and workbook events only.
You configure each webhook to subscribe to an event in Tableau. Then, when the event occurs, an HTTP POST request will be sent to the public URL you specified. This POST request includes a JSON payload that includes information about the event. The payload includes the ID of the object in question so that the Tableau REST API can be used to get additional information or take further action.
- Webhooks Documentation: https://github.com/tableau/webhooks-docs
Web Data Connector (WDC) API
- Web Data Connector: https://tableau.github.io/webdataconnector
Tableau Magic Article:
- Creating a Web Data Connector Part 1: http://tableaumagic.com/creating-a-web-data-connector-part-1
The Extract API 2.0 contains a set of functions for creating extracts. Using the Extract API you can 1) create and populate extract (.hyper) files to improve performance and provide offline access to your data sources, 2) write a program that connects to data sources that are not currently supported by Tableau, and then write the data into a .hyper file for use later by Tableau, and 3) write a program to create an extract that contains multiple tables.
- Extract 2.0 API: https://onlinehelp.tableau.com/current/api/extract_api/en-us/Extract/extract_api.htm
The Document API provides a supported way to programmatically make updates to Tableau workbook and data source files. If you’ve been making changes to these file types by directly updating the XML–that is, by XML hacking–this SDK is for you.
- Document API Python: http://tableau.github.io/document-api-python
Note: It looks like the GitHub repository has not been modified in 3 years.
If you want to know more about how Tableau APIs can help you in your day to day work, send me an email at firstname.lastname@example.org to learn more.
As always, I hope you all enjoyed this article as much as I enjoyed writing it and as always do share the love. Do let me know if you experienced any issues recreating this Visualisation, and as always, please leave a comment below or reach out to me on Twitter @Tableau_Magic.