File tree 2 files changed +13
-10
lines changed
2 files changed +13
-10
lines changed Original file line number Diff line number Diff line change
1
+ from sempy_labs ._kql_dashboards import (
2
+ list_kql_dashboards ,
3
+ create_kql_dashboard ,
4
+ delete_kql_dashboard ,
5
+ create_workspace_montiring_dashboard ,
6
+ )
1
7
from sempy_labs ._graphQL import (
2
8
list_graphql_apis ,
3
9
create_graphql_api ,
511
517
"delta_analyzer" ,
512
518
# "dax_perf_test",
513
519
# "dax_perf_test_bulk",
520
+ "list_kql_dashboards" ,
521
+ "create_kql_dashboard" ,
522
+ "delete_kql_dashboard" ,
523
+ "create_workspace_montiring_dashboard" ,
514
524
]
Original file line number Diff line number Diff line change 7
7
_base_api ,
8
8
_create_dataframe ,
9
9
_conv_b64 ,
10
+ generate_guid ,
10
11
)
11
12
from uuid import UUID
12
13
import requests
@@ -90,25 +91,17 @@ def create_kql_dashboard(
90
91
payload ["description" ] = description
91
92
92
93
if content :
93
- # platform_payload = ''
94
94
payload ["definition" ] = {
95
95
"format" : None ,
96
96
"parts" : [
97
97
{
98
98
"path" : "RealTimeDashboard.json" ,
99
- "payload" : content ,
99
+ "payload" : _conv_b64 ( content ) ,
100
100
"payloadType" : "InlineBase64" ,
101
101
},
102
- # {
103
- # "path": ".platform",
104
- # "payload": platform_payload,
105
- # "payloadType": "InlineBase64"
106
- # }
107
102
],
108
103
}
109
104
110
- payload = _conv_b64 (payload )
111
-
112
105
_base_api (
113
106
request = f"v1/workspaces/{ workspace_id } /kqlDashboards" ,
114
107
method = "post" ,
@@ -165,7 +158,7 @@ def create_workspace_montiring_dashboard(
165
158
"clusterUri" : cluster_uri ,
166
159
"database" : database_id ,
167
160
"name" : db_name ,
168
- "id" : "b7d7ce56-c612-4d4f-ab1a-1a6f6212efd0" ,
161
+ "id" : generate_guid () ,
169
162
"workspace" : workspace_id ,
170
163
}
171
164
]
You can’t perform that action at this time.
0 commit comments