This page explains how to embed a ThoughtSpot Liveboard in your Web page, portal, or application.
A ThoughtSpot Liveboard is an interactive dashboard that presents a collection of visualizations pinned by a user. ThoughtSpot Liveboards are available the following modes:
-
Classic experience mode
-
New experience mode
The new Liveboard experience can be turned off or on using the
liveboardV2parameter in theLiveboardEmbedSDK.
In the new Liveboard experience mode, the embedded Liveboard resizes to one-column layout if the screen width is 1024px or less. In classic experience mode, the embedded Liveboard adjusts its layout to two-column or one-column view to fit the screen width and orientation of the user’s device.
Import the LiveboardEmbed SDK library to your application environment:
npm
import {
LiveboardEmbed,
AuthType,
init,
prefetch,
EmbedEvent
}
from '@thoughtspot/visual-embed-sdk';ES6
<script type = 'module'>
import {
LiveboardEmbed,
AuthType,
init,
prefetch
}
from 'https://cdn.jsdelivr.net/npm/@thoughtspot/visual-embed-sdk/dist/tsembed.es.js';Initialize the SDK and define authentication attributes.
const liveboardEmbed = new LiveboardEmbed(document.getElementById('ts-embed'), {
frameParams: {
width: '100%',
height: '100%',
},
liveboardId: '<%=liveboardGUID%>',
fullHeight: true,
visibleVizs: [],
runtimeFilters: [{
columnName: '<column-name>',
operator: <RuntimeFilterOp>
values: ['value']
}],
});For more information Liveboard embed object, classes, methods, interface properties, and enumeration members, see the following pages:
Register event listeners.
liveboardEmbed.on(EmbedEvent.init, showLoader)
liveboardEmbed.on(EmbedEvent.load, hideLoader)For more information about events, see the following pages:
