Defines the properties for creating an AnalyticsAgent component.
The agent supports two operating modes:
Single-context mode: Provide contextConfig to track a single analytics asset.
Multi-component mode: Omit contextConfig to automatically track all embedded AnalyticsDashboard and AnalyticsMetric components on the page.
Multi-org Note: In multi-org scenarios, always specify the orgUrl property to indicate which org the agent exists in. The orgUrl must be a Lightning URL (e.g., https://yourorg.lightning.force.com).
Type declaration
agentName?
optionalagentName: string
The custom display name for the agent. The default name is 'Analytics and Visualization'.
Optional. The context configuration for the agent.
When provided, the agent runs in single-context mode and tracks only the specified component.
When omitted, the agent runs in multi-component mode and automatically tracks all embedded AnalyticsDashboard and AnalyticsMetric components on the page.
idOrApiName
idOrApiName: string
Required. The ID of the Agentforce agent to embed.
showHeader?
optionalshowHeader: boolean
A boolean value indicating whether to display the agent’s header section or not. The default value is false.
showHeaderActions?
optionalshowHeaderActions: boolean
A boolean value indicating whether to display the agent’s header actions, information and restart session, or not. The default value is false.