Skip to Content

Finding Your IDs

Find a metric ID

Get the value for the metric-id attribute of dbn-metric, to embed one chart.

Use <dbn-metric> to show one metric instead of a whole dashboard. It needs the metric’s ID.

Steps

  1. Go to Data Studio > Data Apps and open your data app.
  2. Select the Embeds tab, then Add embed.
  3. Select the Workspace. For Embed type, select Metric.
  4. Select the Dashboard that holds the metric, then the Metric.
  5. Select Create embed.
  6. In the new row, copy the Key. Or select Get snippet and copy the metric-id value.
<dbn-metric token="GUEST_TOKEN" metric-id="monthly-revenue" style="display:block;height:400px"></dbn-metric>

You have the metric ID. Next, create a guest token.

The Metric ID column on a workspace’s metrics list on Home shows the same value.

If something goes wrong

  • The console says dbn-metric: no metric-id was set. Set metric-id. In HTML, write it in kebab case, not metricId.
  • The card does not load. The metric must be an embed of the data app the guest token was made for.

On this page