Quicksight Dashboard using existing Template

Garima Shrivastava
ITTStar Technology Blogs
4 min readFeb 12, 2021

Overview: A template is an entity in QuickSight that encapsulates the metadata and allow you to store the visual configuration and data schema associated with a dashboard and then easily replicate the dashboard for different sets of users or different data, within or across accounts.

The Amazon QuickSight APIs can be invoked via the AWS Software Development Kit (SDK) or the AWS Command Line Interface (CLI).

In this blog, we will be creating a template & use this template to replicate the same dashboard for different data using the AWS Software Development Kit (SDK).

Introduction: we have stored two tables table1 and table2 in S3 bucket which have the same schema. Now using boto3 client we will be creating data sources in Quicksight to access respective tables from S3 and create datasets in Quicksight.

Using the first dataset we will be creating the analysis & template. Now using this template, we will be building dashboard and replicate the same dashboard using the second dataset.

I am going to walk you through the process step by step:

Step1: We will be importing boto3 client to connect with the AWS Quicksight.

Step2: To access your data from your database or data storage, you’ll need to create a data source in QuickSight. We have stored our data in S3 bucket, so we need to create a manifest json file which saves the bucket name and location of your data in S3. You can see the data source API command will create a dataset “qs_test2” in Quicksight and store the data in Spice. Using this dataset, we are creating one analysis “qs_test2 analysis”.

Step3: Next step is to create a template from this analysis using create-template API. Now we can either publish the dashboard “Demo Dashboard3” directly from the console or we can call create-dashboard API to create the Dashboard.

Here, we are calling the create-dashboard API, where you will define a SourceEntity, (in this case, the template we just created), permissions, and any dashboard publish options, as shown in the configuration used for create-dashboard-cli-input.json

Step4: In this step we will be replicating the same Dashboard using Template and new dataset ARN. Till now we were working with first dataset “qs_test2”. Now we will be creating new dataset “qs_test21” which we will be using to replicate the same dashboard.

Once dataset is created, we will be using the template which we created in last step and will call create-dashboard API to replicate the same dashboard using this dataset. Will name this dashboard “Demo Dashboard 5” since it has been created using “qs_test21” dataset.

Summary: templates allow you to store the visual configuration and data schema associated with a dashboard and then easily replicate the dashboard for different sets of users or different data, within or across accounts.

Special Thanks to my Team. Please find below link to read my latest blog;

  1. https://aws.plainenglish.io/access-management-group-in-quicksight-account-f9a96fa49ba2

…………………Thanks for reading this blog……………….

Authors: Garima Shrivastava(Data Scientist)/Suresh Guntapalli(Data Engineer)

--

--