Skip to content

Commit 0420978

Browse files
committed
Learn Editor: Update api-power-bi.md
1 parent 6172673 commit 0420978

File tree

1 file changed

+27
-17
lines changed

1 file changed

+27
-17
lines changed

defender-endpoint/api/api-power-bi.md

Lines changed: 27 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -24,6 +24,7 @@ ms.date: 12/18/2020
2424
[!INCLUDE [Microsoft Defender XDR rebranding](../../includes/microsoft-defender.md)]
2525

2626
**Applies to:**
27+
2728
- ../microsoft-defender-endpoint.md
2829
- [Microsoft Defender XDR](/defender-xdr)
2930

@@ -42,12 +43,14 @@ The first example demonstrates how to connect Power BI to Advanced Hunting API,
4243
1. Open Microsoft Power BI.
4344

4445
2. Select **Get Data** \> **Blank Query**.
46+
4547
:::image type="content" source="../media/power-bi-create-blank-query.png" alt-text="The Blank Query option under the Get Data menu item" lightbox="../media/power-bi-create-blank-query.png":::
4648

4749
3. Select **Advanced Editor**.
50+
4851
:::image type="content" source="../media/power-bi-open-advanced-editor.png" alt-text="The Advanced Editor menu item" lightbox="../media/power-bi-open-advanced-editor.png":::
4952

50-
4. Copy the below and paste it in the editor:
53+
4. Copy the code snippet below and paste it in the editor:
5154

5255
```
5356
let
@@ -103,36 +106,43 @@ The first example demonstrates how to connect Power BI to Advanced Hunting API,
103106

104107
:::image type="content" source="../media/power-bi-set-credentials-organizational-cont.png" alt-text="The sign-in confirmation message in the Organizational account menu item" lightbox="../media/power-bi-set-credentials-organizational-cont.png":::
105108

106-
Now the results of your query appear as a table and you can start to build visualizations on top of it!
107-
108-
You can duplicate this table, rename it, and edit the Advanced Hunting query inside to get any data you would like.
109+
Now the results of your query appear as a table and you can start to build visualizations on top of it! You can duplicate this table, rename it, and edit the Advanced Hunting query inside to get any data you would like.
109110

110111
## Connect Power BI to OData APIs
111112

112-
The only difference from the previous example is the query inside the editor. Follow steps 1-3 above.
113+
The only difference from the previous example and this example is the query inside the editor.
113114

114-
At step 4, instead of the code in that example, copy the following code, and paste it in the editor to pull all **Machine Actions** from your organization:
115+
1. Open Microsoft Power BI.
115116

116-
```
117-
let
117+
2. Select **Get Data** \> **Blank Query**.
118+
119+
:::image type="content" source="../media/power-bi-create-blank-query.png" alt-text="The Blank Query option under the Get Data menu item" lightbox="../media/power-bi-create-blank-query.png":::
118120

119-
Query = "MachineActions",
121+
3. Select **Advanced Editor**.
120122

121-
Source = OData.Feed("https://api.securitycenter.microsoft.com/api/" & Query, null, [Implementation="2.0", MoreColumns=true])
122-
in
123-
Source
124-
```
123+
:::image type="content" source="../media/power-bi-open-advanced-editor.png" alt-text="The Advanced Editor menu item" lightbox="../media/power-bi-open-advanced-editor.png":::
124+
125+
4. Copy the following code, and paste it in the editor to pull all **Machine Actions** from your organization:
126+
127+
```
128+
let
129+
130+
Query = "MachineActions",
131+
132+
Source = OData.Feed("https://api.securitycenter.microsoft.com/api/" & Query, null, [Implementation="2.0", MoreColumns=true])
133+
in
134+
Source
135+
```
125136

126-
You can do the same for **Alerts** and **Machines**.
127-
You also can use OData queries for queries filters. See [Using OData Queries](exposed-apis-odata-samples.md).
137+
You can do the same for **Alerts** and **Machines**. You also can use OData queries for queries filters. See [Using OData Queries](exposed-apis-odata-samples.md).
128138

129139
## Power BI dashboard samples in GitHub
130140

131-
For more information, see the [Power BI report templates](https://github.com/microsoft/MicrosoftDefenderATP-PowerBI).
141+
See the [Power BI report templates](https://github.com/microsoft/MicrosoftDefenderATP-PowerBI).
132142

133143
## Sample reports
134144

135-
View the Microsoft Defender for Endpoint Power BI report samples. For more information, see [Browse code samples](/samples/browse/?products=mdatp).
145+
View the [Microsoft Defender for Endpoint Power BI report samples](/samples/browse/?products=mdatp).
136146

137147
## Related articles
138148

0 commit comments

Comments
 (0)