Attributes for the Lightning Web Component for Analytics Dashboards

The Lightning web component for CRM Analytics dashboards has attributes that can be set programmatically so you can create, render, and interact with a CRM Analytics dashboard on a page at runtime.

NameTypeRequired or OptionalDescription
asset-extended-metadataobjectOptionalSpecifies the extended metadata for the dashboard.
asset-idstringRequired if developer-name isn’t specified.Specifies the unique ID of the dashboard. You can get a dashboard’s ID, an 18-character code beginning with 0FK, from the dashboard's URL, or you can request it through the API. You can use this attribute instead of the developer-name, but you can't include asset-id if the name has been set. Either the developer-name attribute or the asset-id attribute is required.
asset-metadataobjectOptionalSpecifies the metadata for the dashboard.
contextstringOptionalSpecifies the context for the dashboard.
developer-namestringRequired if asset-id isn’t specified.Specifies the unique developer name of the dashboard. You can request the developer name through the API. You can use this attribute instead of the asset-id, but you can't include developer-name if the ID has been set. Either the developer-name attribute or the asset-id attribute is required.
enable-notificationsbooleanOptionalIndicates whether users can set and manage notifications on widgets (true) or not (false). The default is false.
enable-subscriptionsbooleanOptionalIndicates whether users can subscribe to widgets and manage their subscriptions (true) or not (false). The default is false.
filterstringOptionalSpecifies the state of the dashboard including any filters or selections that have been applied. See Filter and Selection Syntax for Embedded Dashboards.
heightintegerOptionalSpecifies the height of the dashboard in pixels. The default is 300.
hide-on-errorbooleanOptionalIndicates whether users see a dashboard that has an error (true) or not (false). When this attribute is set to true, if the dashboard has an error it doesn't appear on the page. When set to false, the dashboard appears but doesn’t show any data. An error can occur if a user doesn't have access to the dashboard or the dashboard is deleted. The default is false.
is-loadedbooleanOptionalIndicates whether the dashboard is fully loaded on the page (true) or not (false). The default is false.
open-links-in-new-windowbooleanIndicates whether links in the dashboard are opened in a new window (true) or not (false).
open-locationstringOptionalSpecifies where the dashboard opens if the user chooses to launch the dashboard in its own page.
page-idstringOptionalSpecifies the initial dashboard page to show.
record-idstringOptionalSpecifies the ID of the current entity in the context of which the dashboard is being shown.
show-headerbooleanOptionalIndicates whether the dashboard displays a header bar that includes dashboard information and controls (true) or not (false). The header bar automatically appears when either show-sharing or show-title is true. The default is false.
show-in-cardbooleanOptionalIndicates whether the dashboard displays in a card (true) or not (false).
show-post-to-slackbooleanOptionalIndicates whether the Post to Slack icon appears in the dashboard header (true) or not (false).
show-sharingbooleanOptionalIndicates whether to show the Share icon for a dashboard (true) or not (false). If set to true and the dashboard is shareable, then the dashboard shows the Share icon. If you choose to show the Share icon in the dashboard, the smallest supported frame size is 800x612 pixels. The default is false.
show-titlebooleanOptionalIndicates whether to show the dashboard's title above the dashboard (true) or not (false). The default is false.
widthintegerOptionalSpecifies the width of the dashboard in pixels.

Here’s an example of a CRM Analytics dashboard component with most of the attributes specified. This example shows custom values overriding the default values.