Embed visualizations
You can use the embedding feature in Imply Polaris to create links to read-only visualizations. You can share links or embed them in third-party apps to provide non-Polaris users with a way to view visualizations outside the Polaris UI.
The embedding feature also generates API specs that you can use to programmatically create embedded visualizations.
Prerequisites
Users with the AdministerEmbedLinks
permission can configure embedding links in Polaris. For information on permissions, see Permissions reference.
Create an embedding link
Follow these steps to create an embedding link:
Click Embedding in the left pane.
The page lists all embedding links created in the Polaris UI. Click the API generated tab to see links created with the Embedding API.
Click New embedding link.
To create a link to a data cube, select the data cube and click Configure view. You can add filters, dimensions and measures to restrict the data to include in the embedded view. Click Save when you've finished setting up the view.
To create a link to a dashboard, select the dashboard and click Save.
Complete the Embed View dialog:
- Name: Enter a name for your embedding link.
- Description: Enter an optional description.
- Select Hide surrounding controls, show visualization only to hide the left navigation panel and header bar as shown below:
- Access filter: You can optionally apply a SQL condition to the underlying data. See Create an access filter for more information.
Click the API spec tab if you want to generate the link via API.Click Generate link when you've finished configuring the link.
From the confirmation dialog you can preview the link in a new tab and copy the link to your clipboard.
To create an embedding link from a data cube:
Go to the data cube page and click the alerts and reports ellipsis in the top right corner, then select Embed this view.
Complete the Embed View dialog as outlined above, then generate the link.
To create an embedding link from a dashboard:
Go to the dashboard page and click the embedding ellipsis in the top right corner, then select Embed this view.
Complete the Embed View dialog as outlined above, then generate the link.
Manage access to embedding links
Once you create a link and share or embed it in a third-party app, anyone can access it and view all of its underlying data.
If you configure a data cube or dashboard to restrict access to specific Polaris users or groups, these restrictions don't apply to embedding links. A warning icon appears in Polaris when you create a link for a restricted data cube or dashboard.
You can, however, create an access filter to limit the data displayed by an embedding link. Access filters allow you to apply a SQL predicate to an embedded visualization's underlying data.
Create an access filter
You can create a single access filter for each embedding link. If you want to create multiple access filters for the same data cube or dashboard, create multiple links.
In the Access filters field for an embedding link, enter a SQL query to select data for the filter. Preface column names with t.
—for example, t.cityName = 'Berlin' OR t.cityName = 'Munich' AND t.channel = '#de.wikipedia'
.
Manage embedding links
Click Embedding in the left pane to manage embedding links.
For each link, you can:
- Click the Copy icon to save the link to your clipboard.
- Click the View details icon to view information about the link.
- Click the open menu ellipsis to edit or delete the link.
Edit a link
Click the name of a link to edit its details:
After you edit and save the link fields, you can click API call at the top of the page to view and copy the updated API request.
Embed a link
Once you have your embedding link or API request, you can use it to embed a webpage or app to provide read-only access to the visualization.
For example, you could embed a link in a webpage using an iframe
tag as follows:
<iframe src="https://example.imply.io/e/9c45f08fa351bb9fc4" title="Example embedded visualization"></iframe>
Learn more
See the following topics for more information:
- Manage data cubes for creating and editing data cubes.
- Visualize data for using Polaris visualization features to draw insights from your data.