When embedding dashboards externally, authentication is performed via OpenAPI. The embedding party is responsible for applying for the OpenAPI token to achieve custom permission control, which also avoids the need for repeated logins when users click the dashboard to access the system.
Caution: Before using the interfaces described in this document, please first understand the invocation method. For details, see Invocation Method.
First, refer to the OpenAPI overview to apply for a clientID / secret, and use the clientID / secret to obtain a JWT token.
Embed into desktop page
// 在嵌入的iframe url上带上jwtToken; // 注意OpenAPI鉴权路由前缀使用/bi-open/而不是/bi/; // SaaS环境 <iframe src=`uri/bi/datawind-open/.......?a=b&jwtToken=${jwtToken}` /> // 私有化部署 <iframe src=`uri/bi-open/.......?a=b&jwtToken=${jwtToken}` />
Embed into mobile page
// 在移动端嵌入的iframe url上带上jwtToken; // SaaS环境 <iframe src=`uri/bi/datawind-h5/.......?a=b&jwtToken=${jwtToken}` /> // 私有化部署 <iframe src=`uri/bi-h5/.......?a=b&jwtToken=${jwtToken}` />
Embedding party: The platform that embeds the system's dashboard into its own platform for user access, using but not limited to iframe methods
Browsing user: The user entity who browses the embedding party's page and may view the embedded dashboard page
Intelligent Data Insight user: The user entity on the Intelligent Data Insight platform
System administrator: The system administrator of Intelligent Data Insight (with the highest site-wide permissions)
Requirement description
The embedding party needs to display the dashboard of the Intelligent Data Insight product on its own platform and independently control permission management (or not perform permission control). For example, the embedding party has a BI (Business Intelligence) display page, and the product dashboard is embedded in this page. When a browsing user accesses this display page, if the embedding party determines that the browsing user has access permission to this page, the dashboard on this page is displayed unconditionally, ignoring the actual permissions of the browsing user in the Intelligent Data Insight product (or the browsing user may not even exist on the Intelligent Data Insight platform).
Usage process
(1) The system administrator applies for a client ID / secret with the binding type set to "system"
(2) When a browsing user visits the embedding party, the embedding party applies for an Intelligent Data Insight system token and sets proxyUser to the Intelligent Data Insight system user corresponding to the current browsing user.
DELETE /aeolus/api/open/v2/dashboard/dashboards
Permissions: Only dashboards for which you have management permissions can be deleted. Deleting other users' personal dashboards or directories is not supported.
Parameter | Type | Required | Example value | Description |
|---|---|---|---|---|
Authorization | string | Yes | xxx | Used for backend authentication and authorization. Format: Bearer jwt_token, where jwt_token is obtained through the JWT application API. |
Parameter | Type | Required | Example value | Description |
|---|---|---|---|---|
dashboards | array[int] | No | [1, 2] | List of dashboard IDs to be deleted |
Parameter | Level | Type | Description | Example value |
|---|---|---|---|---|
code | 1 | string | Return code. For definitions, refer to the "Error codes" section. | aeolus/ok |
msg | 1 | string | Prompt message | Success |
data | 1 | object | Data content | |
results | 2 | array[object] | Deletion result information | |
dashboard | 3 | int | Dashboard ID | 1 |
success | 3 | bool | Whether deletion was successful | true/false |
reason | 3 | string | Reason for failure, only valid when success is False | The resource has been deleted |
{ "code": "aeolus/ok", "data": { "results": [ { "dashboard": ******, "reason": "资源已被删除", "success": false }, { "dashboard": ******, "reason": null, "success": true } ] }, "msg": "成功" }
Background: Users enter information into a Lark spreadsheet through a third-party web form, then use this Lark spreadsheet to directly create a dataset, which is analyzed on the dashboard.
Based on this context, users can navigate from the dashboard to the data entry web page, enter data into the Lark sheet on the web page, and after clicking "Complete" on the web page, close the content pop-up and refresh the dashboard according to the updated Lark sheet.