Tableau REST API Integration: 2 Easy Methods

on BI Tool, Data Integration, Tableau • October 7th, 2021 • Write for Hevo

Tableau REST API allows you to manage and modify the Tableau Online site, Tableau Server, and Prep Conductor Resources programmatically with the help of HTTP. The API provides simple access to the functionality behind Tableau projects, site users, workbooks, data sources, flows, sites, and so much more.

This blog provides a detailed insight into REST API Tableau including its key features, benefits, use cases, and importance. It then proceeds to talk about the two methods you can use to set up Tableau REST API Integration, using Autonomous REST Connector and a third-party tool, Hevo Data

Table of Contents

What is Tableau REST API?

Tableau REST API: API Reference
Image Source

You can use Tableau REST API to script interactions with Tableau resources and create your custom applications. Tableau REST API offers multiple methods for your convenience such as:

  • Flow Methods: Flow Methods allow you to add, download, query, run and delete flows, flow permissions, and flow tasks to schedule.
  • Metrics Methods: With Metric Methods you can get, update or delete metrics easily. You can even list metrics by the site through this method.
  • Projects Methods: With these methods, you can easily query, create, delete, or update projects.
  • Publishing Methods: Publishing Methods can help you publish flows, workbooks, or data sources. It can also allow you to append or initiate a file upload.
  • Site Methods: There are a couple of Site Methods that allow you to create, delete, query, and update a site.
  • Revisions Methods: These methods allow you to obtain, download or remove data source revisions or workbook revisions.

The Tableau REST API is based on the principles of REST (Representational State Transfer) protocol for Client-Server communication. The Client-server communication occurs over HTTP, for the Tableau Server using standard web requests.

While working with the Tableau REST API, you can use the following HTTP verbs to request actions from the server:

  • PUT: This HTTP verb can be used to update existing resources, such as updating permissions, updating a user’s password, or changing a workbook owner.
  • POST: You can use this verb to publish or create new resources, such as users, data sources, sites, and workbooks.
  • DELETE: It can be used to remove a resource, for instance, deleting a workbook or user. It can also be used to dissociate a resource from a collection. For instance, if you use DELETE to remove a user from a site, which dissociates the user from the collection of users on the website, but doesn’t remove the user from the server. 
  • GET: You can use GET to read information, such as downloading a workbook or getting a list of users.
Tableau REST API: Description
Image Source

Ways to Set up Tableau REST API Integration

Method 1: Using Autonomous REST Connector for Tableau REST API Integration

This method involves using Autonomous REST Connector to establish Tableau REST API Integration seamlessly. This is a 5-step process.

Method 2: Using Hevo Data for Tableau REST API Integration

Hevo is a No-code Data Pipeline. It will automatically connect Tableau REST API data source without writing any line of code. Hevo comes with a graphical interface that allows you to configure your source and load data in real-time. Hevo is fully managed and completely automates the process of not only loading data from your desired source but also enriching the data and transforming it into an analysis-ready form without having to write a single line of code.

Hevo’s pre-built integration with REST APIs and 100+ Other Data Sources (Including 40+ Free Data Sources) will take full charge of the data transfer process, allowing you to focus on key business activities. Transfer Data from various sources to your target destination for Free!

Get Started with Hevo for Free

Understanding the Methods to Establish Tableau REST API Integration

Here are the different methods you can follow to set up Tableau Server REST API Integration in a seamless fashion:

Method 1: Using Autonomous REST Connector for Tableau REST API Integration

Here are the steps you can follow to establish REST API Tableau connection using Autonomous REST Connector:

Step 1: Download and Install the Autonomous REST Connector

  • Install and download the Autonomous REST Connector for ODBC. Next, you need to install the connector by running the setup executable file.

Step 2: Authenticating Data Source

  • Here, we’ll be using HubSpot as an example data source. HubSpot gives you two means of authentication- API Keys and OAuth. Autonomous REST Connector provides support for both methods. Here, you will be leveraging API Keys for authentication. Here is an instance of the request using the API key:
curl https://api.hubapi.com/contacts/v1/lists/all/contacts/all?hapikey=456****cfa 

Step 3: Create the ODBC Data Source

  • Open ODBC Administrator (64-bit) and create a new data source by clicking on the Add button.
  • Select DataDirect 8.0 Autonomous REST Connector as the driver for this step.
Tableau REST API: Create New Data Source Window
Image Source
  • On the configuration window, give a name to the data source and under REST Sample Path, paste the endpoint you wish to connect to. Suppose, you want to connect to the Get All Companies endpoint, you just have to paste that endpoint in the REST Sample Path as follows:
Tableau REST API: Progress DataDirect Autonomous REST Connector for ODBC Setup
Image Source
  • Navigate to the Authentication tab and set the parameters as follows:
Tableau REST API: Setting the Parameters
Image Source
  • Click on the Test Connect button in the previous step to establish a connection to the API.

Step 4: Connect from Tableau

  • In this step, you need to connect to the data source from Tableau. In Tableau, select Other Databases (ODBC), and select HubSpot as the sample DSN you just created.
Tableau REST API: Other Databases
Image Source
  • Now you can see a list of tables made available through the Autonomous REST Connector. It does this by normalizing the JSON response from the API. Next, you need to access the REST API data as usual.
Tableau REST API: List of Tables in Autonomous REST Connector
Image Source

Step 5: Connecting to Multiple Endpoints

  • To configure multiple endpoints for Autonomous REST Connector, you need to create a new file called <Data Source Name>.rest and configure the endpoints as shown below, and save the file:
Tableau REST API: Connecting to Multiple Endpoints
Image Source
  • Open the ODBC Administrator and clear the REST Sample Path in the DSN Configuration you have created. Next, under the REST Config File, navigate to the configuration file <Data Source Name>.rest as shown below:
Tableau REST API: Clear REST Sample Path
Image Source
  • Click on Test Connect to check if the connection has been established successfully. Next, open Tableau and refresh the connection. You will be able to see more tables that are normalized from the API by Autonomous REST Connector.
Tableau REST API: Test Connect
Image Source
  • You can then choose to Extract Data or use a Live Connection to request data from REST API on the go with the help of an Autonomous REST Connector.

Method 2: Using Hevo for Tableau REST API Integration

Tableau REST API: Hevo Logo
Image Source

Hevo is a No-code Data Pipeline. It supports pre-built data integrations from 100+ data sources such as REST APIs. Hevo offers a fully managed solution for your fully automated pipeline to set up Tableau REST API integration and will let you directly stream data to Tableau from a REST API. It will automate your data flow in minutes without writing any line of code. Its fault-tolerant architecture makes sure that your data is secure and consistent. Hevo provides you with a truly efficient and fully automated solution to manage data in real-time and always have analysis-ready data at Tableau.

Now you can transfer data from REST API to your target BI tool like Tableau for Free using Hevo!

Sign up here for a 14-Day Free Trial!

Hevo focuses on three simple steps to get you started

  • Connect: Connect Hevo with REST API and various other data sources by simply logging in with your credentials/providing the correct end-point.
  • Integrate: Consolidate your customer data from several sources in Hevo’s Fully- Managed Google BigQuery-based Data Warehouse and automatically transform it into an analysis-ready form.
  • Visualize: Connect Hevo with Tableau and easily visualize your unified payments and sales data to gain better insights.

As can be seen, you are simply required to enter the corresponding credentials to implement this fully automated data pipeline without using any code.

The detailed documentation of the functionality offered can be found here.

Let’s look at some salient features of Hevo

  • Fully Managed: It requires no management and maintenance as Hevo is a fully automated platform.
  • Real-Time: Hevo offers real-time data migration. So, your data is always ready for analysis.
  • Schema Management: Hevo can automatically detect the schema of the incoming data and maps it to the destination schema.
  • 100% Complete & Accurate Data Transfer: Hevo’s robust infrastructure ensures reliable data transfer with zero data loss.
  • Scalable Infrastructure: Hevo has in-built integrations for 100+ sources that can help you scale your data infrastructure as required.
  • Live Monitoring: Advanced monitoring gives you a one-stop view to watch all the activities that occur within pipelines.
  • Live Support: Hevo team is available round the clock to extend exceptional support to its customers through chat, email, and support calls.
  • Transformations: Hevo provides preload transformations through Python code. It also allows you to run transformation code for each event in the Data Pipelines you set up. You need to edit the event object’s properties received in the transform method as a parameter to carry out the transformation. Hevo also offers drag and drop transformations like Date and Control Functions, JSON, and Event Manipulation to name a few. These can be configured and tested before putting them to use.
  • Connectors: Hevo supports 100+ integrations to SaaS platforms, files, databases, analytics, and BI tools. It supports various destinations including Amazon Redshift, Snowflake Data Warehouses; Amazon S3 Data Lakes; and MySQL, SQL Server, TokuDB, DynamoDB, PostgreSQL databases to name a few.  

Explore more about Hevo by signing up for a 14-day free trial today.

Conclusion

This blog talks about the different methods you can use to connect REST API to Tableau in a seamless fashion, using Autonomous REST Connector and with the help of a No-code Data Pipeline, Hevo Data. It also gives a brief introduction to Tableau Server REST API. This includes a brief overview of the various methods enlisted under the Tableau Server REST API.

Hevo provides a No-Code Data Pipeline that allows accurate and real-time replication of data from 100+ sources of data such as REST APIs straight to your desired destination/BI Tool such as Tableau.  

Visit our Website to Explore Hevo

Give Hevo a try and Sign Up up for a 14-day free trial today! You can now transfer data from sources like REST API to your target destination like Tableau for Free using Hevo!

No-code Data Pipeline for Tableau