New Amazon QuickSight API Capabilities to Accelerate Your BI Transformation

海外精选
re:Invent
Amazon QuickSight
海外精选的内容汇集了全球优质的亚马逊云科技相关技术内容。同时,内容中提到的“AWS” 是 “Amazon Web Services” 的缩写,在此网站不作为商标展示。
0
0
{"value":"Regular readers of this blog, and Amazon Web Services customers alike, know the benefits of infrastructure as code (IaC). It allows you to describe your infrastructure using a programming language to consistently deploy your infrastructure to multiple environments or Amazon Web Services Regions. Other benefits are the possibility to version-control your infrastructure using the same development tools and workflow you use to manage your application source code. IaC also offers the ability to programmatically validate part of the infrastructure before it is deployed.\n\nToday, we are expanding the capabilities of QuickSight APIs to allow programmatic creation and management of dashboards, analysis, and templates. These capabilities allow BI teams to manage their BI assets as code, similar to IaC. It brings greater agility to BI teams, and it allows them to accelerate BI migrations from legacy products through programmatic migration options.\n\nBusiness intelligence and IT operations (BIOps) are inspired by best practices learned over decades from DevOps. BIOps enable faster innovation for your customers, bringing them data insights quickly. Dashboards are usually developed and deployed manually due to the UI-driven nature of BI authoring. This presents a challenge for BIOps, as changes to dashboards during deployments might not be fully validated, leading to errors and downtime when changes are inadvertently moved to production. The new QuickSight APIs enable you to programmatically create and modify your QuickSight analyses and dashboards, enable version control on these assets in your code repository, and help to accelerate your migration to the Amazon Web Services Cloud.\n\nProgrammatic creation and management of analysis, templates, and dashboards also helps you to migrate assets from older BI solutions. Among all of the data and analytics workloads moving to the cloud, business intelligence tends to be among the last pieces to be migrated from the legacy, on-premises solutions. BI teams often have thousands of custom reports and dashboards, built over decades, that are tedious to migrate. Migrating these reports is time-consuming as BI teams need to spend months of work migrating each of these assets manually one by one.\n\n**++Terminology++**\nWith this launch, QuickSight adds a new```describe```\nset of APIs. We are also updating existing ```create```,```update```\n, and ```list ```API verbs. Altogether, these new and updated APIs allow you to work with the data model of analyses, templates, and dashboards for fine grain control via APIs.\n\n- A QuickSight analysis is the easy-to-use workspace for creating data visualizations, which are graphical representations of your data. Each analysis contains a collection of visualizations that you arrange and customize.\n- A QuickSight dashboard lets you share interactive visualizations or static reports from an analysis with other users.\n- A QuickSight template is an entity that encapsulates the metadata required to create an analysis or a dashboard. It abstracts the dataset associated with the analysis by replacing it with placeholders.\n\nThe new APIs (```DescribeAnalysisDefinition,DescribeTemplateDefinition, DescribeDashboardDefinition```) now allow developers to manage all supported charts and visual components.\n\n**++Let’s See It in Action++**\nLet’s imagine I want to programmatically create a QuickSight analysis.\n\nProgrammatically creating a new business intelligence analysis is a three-step process: create the data source that provides data for analyses, create a dataset based on the data source, and create the QuickSight analysis.\n\nThe first step when using QuickSight programmatically or through the user interface is to define your data sources. Data sources define the properties of the databases that have the data you want to analyze. Creating and managing data sources programmatically is not new. You can refer to the [QuickSight API Operations to Control Data Sources page](https://docs.aws.amazon.com/quicksight/latest/APIReference/qs-data.html).\n\nThe second step is to [create the dataset to link one or multiple data sources](https://docs.aws.amazon.com/quicksight/latest/user/create-a-data-set-existing.html). Again, [programmatically managing datasets](https://docs.aws.amazon.com/quicksight/latest/APIReference/API_CreateDataSet.html) is not new.\n\n\nWhen using the new```describe```API, analysis, dashboards, and templates are defined as JSON objects fully modeled in the Amazon Web Services SDK. In this demo, I am using the [Amazon Web Services Command Line Interface (CLI)](https://aws.amazon.com/cli/) that uses JSON objects. When you use Java or another Amazon Web Services SDK, you can programmatically manipulate all elements.\n\n\nThe easiest way to get started to programmatically create a new analysis or dashboard is to start with the definition of an existing one that you created in the console.\n\nThe third step is to create the analysis. I first call the```describe-analysis-definition```API to describe an existing analysis. I receive a JSON file that is the full response of the API call. I can inspect and modify the ```Definition```in the ```describe-analysis-definition```response to create a new analysis.\n```\naws quicksight describe-analysis-definition \\\n --aws-account-id 0123456789 \\\n --analysis-id linechart-kpi-donut-pivot\n> ./AWS\\ Blog\\ Sample\\ Code/linechart-kpi-donut-pivot.json\nBash\n```\n\nNote: This JSON file cannot be used directly without several modifications as input to the ```create```\n API.\n\nWhen I am ready to create a new analysis, I generate a JSON file using the```--generate-cli-skeleton```\n argument. Then, I copy the original or modified```Definition```\n object from my earlier call to ```describe-analysis-definition```into```create-sales-analysis.json```\n.\n\n```\naws quicksight create-analysis \\ \n --generate-cli-skeleton > create-sales-analysis.json\n\naws quicksight create-analysis \\\n --cli-input-json file://./AWS\\ Blog\\ Sample\\ Code/create-sales-analysis.json\n```\n\nThe ```Definition```\n field shares the same shape across dashboards, templates, and analyses, so the ```Definition```\n used to create our analysis can also be re-used to create a new dashboard if desired with the ```create-dashboard```\n API.\n\n```\naws quicksight create-dashboard \\\n --generate-cli-skeleton > create-dashboard.json\n```\n\nI can then modify```create-dashboard.json```to include the ```Definition```from my ```create-sales-analysis.json```\n file, as well as update other parameters, then make a call to \n```create-dashboard```\n.\n\n```\naws quicksight create-dashboard \\\n --cli-input-json file://./AWS\\ Blog\\ Sample\\ Code/create-dashboard.json\n```\n\nHere is an extract of the JSON file I used.\n\n![image.png](https://dev-media.amazoncloud.cn/b77426c0714b41aab276b0b8ffd83cf5_image.png)\n\nObviously, developing a dashboard using the API is an iterative process. Here is the result after several iterations.\n\n![image.png](https://dev-media.amazoncloud.cn/ff259ab104914917b78305faa128a2a0_image.png)\n\nI can apply the same technique to programmatically migrate assets from older BI solutions.\n\n**++Pricing and Availability++**\n[The new API allows you to define your business intelligence dashboard as programmable objects](https://docs.aws.amazon.com/quicksight/latest/APIReference/qs-assets.html). It will speed up migration from older BI tools. [QuickSight’s API documentation page](https://docs.aws.amazon.com/quicksight/latest/APIReference/qs-assets.html) has all the details.\n\nThe API is available at no additional charge to all [QuickSight Enterprise Edition customers](https://aws.amazon.com/quicksight/pricing/) in all Amazon Web Services Regions where [QuickSight is available](https://docs.aws.amazon.com/general/latest/gr/quicksight.html). [Amazon Web Services CloudFormation](https://aws.amazon.com/cloudformation/) support for the newly supported data models on these APIs is coming soon.\n\n**Go [build your first dashboard programmatically today! ](https://docs.aws.amazon.com/quicksight/latest/APIReference/qs-assets.html)**\n\n-- [seb](https://twitter.com/sebsto)\n\n![image.png](https://dev-media.amazoncloud.cn/648fa730455043de80429070938f34cd_image.png)\n\n## **[Sébastien Stormacq](https://aws.amazon.com/blogs/aws/author/stormacq/)**\nSeb has been writing code since he first touched a Commodore 64 in the mid-eighties. He inspires builders to unlock the value of the Amazon Web Services cloud, using his secret blend of passion, enthusiasm, customer advocacy, curiosity and creativity. His interests are software architecture, developer tools and mobile computing. If you want to sell him something, be sure it has an API. Follow him on Twitter @sebsto.\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n","render":"<p>Regular readers of this blog, and Amazon Web Services customers alike, know the benefits of infrastructure as code (IaC). It allows you to describe your infrastructure using a programming language to consistently deploy your infrastructure to multiple environments or Amazon Web Services Regions. Other benefits are the possibility to version-control your infrastructure using the same development tools and workflow you use to manage your application source code. IaC also offers the ability to programmatically validate part of the infrastructure before it is deployed.</p>\n<p>Today, we are expanding the capabilities of QuickSight APIs to allow programmatic creation and management of dashboards, analysis, and templates. These capabilities allow BI teams to manage their BI assets as code, similar to IaC. It brings greater agility to BI teams, and it allows them to accelerate BI migrations from legacy products through programmatic migration options.</p>\n<p>Business intelligence and IT operations (BIOps) are inspired by best practices learned over decades from DevOps. BIOps enable faster innovation for your customers, bringing them data insights quickly. Dashboards are usually developed and deployed manually due to the UI-driven nature of BI authoring. This presents a challenge for BIOps, as changes to dashboards during deployments might not be fully validated, leading to errors and downtime when changes are inadvertently moved to production. The new QuickSight APIs enable you to programmatically create and modify your QuickSight analyses and dashboards, enable version control on these assets in your code repository, and help to accelerate your migration to the Amazon Web Services Cloud.</p>\n<p>Programmatic creation and management of analysis, templates, and dashboards also helps you to migrate assets from older BI solutions. Among all of the data and analytics workloads moving to the cloud, business intelligence tends to be among the last pieces to be migrated from the legacy, on-premises solutions. BI teams often have thousands of custom reports and dashboards, built over decades, that are tedious to migrate. Migrating these reports is time-consuming as BI teams need to spend months of work migrating each of these assets manually one by one.</p>\n<p><strong><ins>Terminology</ins></strong><br />\nWith this launch, QuickSight adds a new<code>describe</code><br />\nset of APIs. We are also updating existing <code>create</code>,<code>update</code><br />\n, and <code>list </code>API verbs. Altogether, these new and updated APIs allow you to work with the data model of analyses, templates, and dashboards for fine grain control via APIs.</p>\n<ul>\n<li>A QuickSight analysis is the easy-to-use workspace for creating data visualizations, which are graphical representations of your data. Each analysis contains a collection of visualizations that you arrange and customize.</li>\n<li>A QuickSight dashboard lets you share interactive visualizations or static reports from an analysis with other users.</li>\n<li>A QuickSight template is an entity that encapsulates the metadata required to create an analysis or a dashboard. It abstracts the dataset associated with the analysis by replacing it with placeholders.</li>\n</ul>\n<p>The new APIs (<code>DescribeAnalysisDefinition,DescribeTemplateDefinition, DescribeDashboardDefinition</code>) now allow developers to manage all supported charts and visual components.</p>\n<p><strong><ins>Let’s See It in Action</ins></strong><br />\nLet’s imagine I want to programmatically create a QuickSight analysis.</p>\n<p>Programmatically creating a new business intelligence analysis is a three-step process: create the data source that provides data for analyses, create a dataset based on the data source, and create the QuickSight analysis.</p>\n<p>The first step when using QuickSight programmatically or through the user interface is to define your data sources. Data sources define the properties of the databases that have the data you want to analyze. Creating and managing data sources programmatically is not new. You can refer to the <a href=\"https://docs.aws.amazon.com/quicksight/latest/APIReference/qs-data.html\" target=\"_blank\">QuickSight API Operations to Control Data Sources page</a>.</p>\n<p>The second step is to <a href=\"https://docs.aws.amazon.com/quicksight/latest/user/create-a-data-set-existing.html\" target=\"_blank\">create the dataset to link one or multiple data sources</a>. Again, <a href=\"https://docs.aws.amazon.com/quicksight/latest/APIReference/API_CreateDataSet.html\" target=\"_blank\">programmatically managing datasets</a> is not new.</p>\n<p>When using the new<code>describe</code>API, analysis, dashboards, and templates are defined as JSON objects fully modeled in the Amazon Web Services SDK. In this demo, I am using the <a href=\"https://aws.amazon.com/cli/\" target=\"_blank\">Amazon Web Services Command Line Interface (CLI)</a> that uses JSON objects. When you use Java or another Amazon Web Services SDK, you can programmatically manipulate all elements.</p>\n<p>The easiest way to get started to programmatically create a new analysis or dashboard is to start with the definition of an existing one that you created in the console.</p>\n<p>The third step is to create the analysis. I first call the<code>describe-analysis-definition</code>API to describe an existing analysis. I receive a JSON file that is the full response of the API call. I can inspect and modify the <code>Definition</code>in the <code>describe-analysis-definition</code>response to create a new analysis.</p>\n<pre><code class=\"lang-\">aws quicksight describe-analysis-definition \\\n --aws-account-id 0123456789 \\\n --analysis-id linechart-kpi-donut-pivot\n&gt; ./AWS\\ Blog\\ Sample\\ Code/linechart-kpi-donut-pivot.json\nBash\n</code></pre>\n<p>Note: This JSON file cannot be used directly without several modifications as input to the <code>create</code><br />\nAPI.</p>\n<p>When I am ready to create a new analysis, I generate a JSON file using the<code>--generate-cli-skeleton</code><br />\nargument. Then, I copy the original or modified<code>Definition</code><br />\nobject from my earlier call to <code>describe-analysis-definition</code>into<code>create-sales-analysis.json</code><br />\n.</p>\n<pre><code class=\"lang-\">aws quicksight create-analysis \\ \n --generate-cli-skeleton &gt; create-sales-analysis.json\n\naws quicksight create-analysis \\\n --cli-input-json file://./AWS\\ Blog\\ Sample\\ Code/create-sales-analysis.json\n</code></pre>\n<p>The <code>Definition</code><br />\nfield shares the same shape across dashboards, templates, and analyses, so the <code>Definition</code><br />\nused to create our analysis can also be re-used to create a new dashboard if desired with the <code>create-dashboard</code><br />\nAPI.</p>\n<pre><code class=\"lang-\">aws quicksight create-dashboard \\\n --generate-cli-skeleton &gt; create-dashboard.json\n</code></pre>\n<p>I can then modify<code>create-dashboard.json</code>to include the <code>Definition</code>from my <code>create-sales-analysis.json</code><br />\nfile, as well as update other parameters, then make a call to<br />\n<code>create-dashboard</code><br />\n.</p>\n<pre><code class=\"lang-\">aws quicksight create-dashboard \\\n --cli-input-json file://./AWS\\ Blog\\ Sample\\ Code/create-dashboard.json\n</code></pre>\n<p>Here is an extract of the JSON file I used.</p>\n<p><img src=\"https://dev-media.amazoncloud.cn/b77426c0714b41aab276b0b8ffd83cf5_image.png\" alt=\"image.png\" /></p>\n<p>Obviously, developing a dashboard using the API is an iterative process. Here is the result after several iterations.</p>\n<p><img src=\"https://dev-media.amazoncloud.cn/ff259ab104914917b78305faa128a2a0_image.png\" alt=\"image.png\" /></p>\n<p>I can apply the same technique to programmatically migrate assets from older BI solutions.</p>\n<p><strong><ins>Pricing and Availability</ins></strong><br />\n<a href=\"https://docs.aws.amazon.com/quicksight/latest/APIReference/qs-assets.html\" target=\"_blank\">The new API allows you to define your business intelligence dashboard as programmable objects</a>. It will speed up migration from older BI tools. <a href=\"https://docs.aws.amazon.com/quicksight/latest/APIReference/qs-assets.html\" target=\"_blank\">QuickSight’s API documentation page</a> has all the details.</p>\n<p>The API is available at no additional charge to all <a href=\"https://aws.amazon.com/quicksight/pricing/\" target=\"_blank\">QuickSight Enterprise Edition customers</a> in all Amazon Web Services Regions where <a href=\"https://docs.aws.amazon.com/general/latest/gr/quicksight.html\" target=\"_blank\">QuickSight is available</a>. <a href=\"https://aws.amazon.com/cloudformation/\" target=\"_blank\">Amazon Web Services CloudFormation</a> support for the newly supported data models on these APIs is coming soon.</p>\n<p><strong>Go <a href=\"https://docs.aws.amazon.com/quicksight/latest/APIReference/qs-assets.html\" target=\"_blank\">build your first dashboard programmatically today! </a></strong></p>\n<p>– <a href=\"https://twitter.com/sebsto\" target=\"_blank\">seb</a></p>\n<p><img src=\"https://dev-media.amazoncloud.cn/648fa730455043de80429070938f34cd_image.png\" alt=\"image.png\" /></p>\n<h2><a id=\"Sbastien_Stormacqhttpsawsamazoncomblogsawsauthorstormacq_100\"></a><strong><a href=\"https://aws.amazon.com/blogs/aws/author/stormacq/\" target=\"_blank\">Sébastien Stormacq</a></strong></h2>\n<p>Seb has been writing code since he first touched a Commodore 64 in the mid-eighties. He inspires builders to unlock the value of the Amazon Web Services cloud, using his secret blend of passion, enthusiasm, customer advocacy, curiosity and creativity. His interests are software architecture, developer tools and mobile computing. If you want to sell him something, be sure it has an API. Follow him on Twitter @sebsto.</p>\n"}
0
目录
关闭
contact-us