Embed MicroStrategy Library home page
The Embedding SDK allows you to quickly integrate a MicroStrategy Library home page into a web application in a responsive manner. It also provides resources to add functionality such as toggling the navigation bar and sidebar, and getting group data for the current user.
There are three basic steps for embedding a MicroStrategy Library home page.
-
In the initial page of your web application, add a link to the MicroStrategy JavaScript Embedding SDK.
<script src="{YOUR_LIBRARY_SERVER_URL}/javascript/embeddinglib.js"></script>
Replace
{YOUR_LIBRARY_SERVER_URL}
with your actual MicroStrategy Library Server URL, e.g., https://demo.microstrategy.com/MicroStrategyLibrary. -
Create a
<div>
as the placeholder where you want to embed the Library home page.<div id="LibraryHomePageContainer"></div>
-
Call the
microstrategy.embeddingContexts.embedLibraryPage(props)
method when the application has finished loading.microstrategy.embeddingContexts.embedLibraryPage({
serverUrl: "{YOUR_LIBRARY_SERVER_URL}",
placeholder: document.getElementById("LibraryHomePageContainer"),
});
To help you get started, we have provided a number of simple applications with sample code and explanations.
-
Properties for an embedded MicroStrategy Library home page
Describes the properties that can be set for an embedded MicroStrategy Library home page.
-
Describes which Embedding SDK APIs are available on the MicroStrategy Library home page.