Bold BI Dashboards embedding in React with Python using Embedded SDK
A GitHub link has been provided to get the sample application, which demonstrates the rendering of a single dashboard and a list of dashboards in your Bold BI server and followed by steps to create a new embedding application in React with Python on your own.
NOTE: The best way to get started would be to read the Getting Started section of the documentation first. The Getting Started guide provides enough information that you need to know before working on the sample.
Prerequisites
How to run the sample
-
Please get the React with Python sample from GitHub.
-
Please make sure that you have enabled embed authentication on the
embed settingspage. If it is not currently enabled, please refer to the provided image or detailed instructions for enabling it.
-
To download the
embedConfig.jsonfile, please click on this link for reference. Additionally, you can refer to the following image for visual guidance.

-
Please copy the downloaded
embedConfig.jsonfile and paste it into the designated location within the application. Make sure to place it in the application exactly as shown in the following image.
ServerUrl Dashboard Server BI URL (ex: http://localhost:5000/bi, http://demo.boldbi.com/bi) SiteIdentifier For Bold BI Enterprise edition, it should be like site/site1. For Bold BI Cloud, it should be empty string.Environment Your Bold BI application environment. (If it is cloud analytics server, use `BoldBI.Environment.Cloud`; if it is your own server, use `BoldBI.Environment.Enterprise`). DashboardId Item id of the dashboard to be embedded in your application. EmbedSecret Get your EmbedSecret key from the Embed tab by enabling the Enable embed authenticationin the Administration pageUserEmail UserEmail of the Admin in your Bold BI, which would be used to get the dashboard ExpirationTime Token expiration time. (In the EmbedConfig.json file, the default token expiration time is 10000 seconds). -
Run the python application using the command “python manage.py runserver” The application will be running on port number 8000.

-
Once you provide these details, run the command
npm install. After all the packages are installed, run the commandnpm start.
NOTE: By default, we display the dashboard embedding without the dashboard listing sidebar. To enable the dashboard list, you need to navigate to the
dashboardlistingURL (e.g.,https://localhost:3000/dashboardlisting).
How this sample works
-
In the React application, we use the
BoldBI.create()method, which includes the dashboard details and server information. ThetokenGenerationUrlAPI member has been provided with a Python application that uses thetokenGenerationmethod.
-
The tokenGeneration API is the intermediary that contacts the Bold BI application to retrieve the dashboard details with token.

-
Once the token is generated, it will be returned to the
Dashboard.jsfile and the dashboard will start to render it.