Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.

Reply
Anonymous
Not applicable

Creating a Dataflow to extract Power BI Audit Logs

I want to automate the process of pulling Audit Logs data from the Admin portal of Power BI. 

Can I create a dataflow to directly extract the audit log data from the Admin portal and dump it in some sort of a Common Data Model ?

ALSO, CAN A POWER QUERY DIRECTLY EXTRACT DATA FROM THE AUDIT LOGS FROM THE ADMIN PORTAL ?

Is there any way other than writing a PowerShell script to extract the audit log data ?

 

Please suggest

 

Thanks in advance.

2 ACCEPTED SOLUTIONS
v-piga-msft
Resident Rockstar
Resident Rockstar

Hi @Anonymous ,

By my research, I have not found the ways getting Power BI Audit Logs with power query or other ways.

So, I'm afraid that we may not create a Dataflow to extract Power BI Audit Logs currently.

Hope @GilbertQ have other ideas.

Best  Regards,

Cherry

 

Community Support Team _ Cherry Gao
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

View solution in original post

Hi there

Currently you have to extract the Audit Logs out into a CSV, which could then be read into a dataflow.

You would also currently have to be an Office 365 Admin to be able to extract data from the Audit Logs.




Did I answer your question? Mark my post as a solution!

Proud to be a Super User!







Power BI Blog

View solution in original post

5 REPLIES 5
Anonymous
Not applicable

Hi,

 

It is no longer needed to be a O365 admin to pull the data using PowerShell.

So far, the only way is to either pull the data using a PowerShell script or by downloading it from the website, but you can still automate it!

I did the following: I wrote a Powershell Script Function pulling data from a given day. This script can now be run automatically from microsoft flow using this method: 
http://johnliu.net/blog/2018/4/run-any-pnp-powershell-in-one-azurefunction-from-microsoft-flow
You can save all the pulled data in a sharepoint folder in whatever format you prefer, and load them all into power bi using this method:
https://devinknightsql.com/2013/08/13/extracting-data-from-multiple-files-with-power-query/

Works great so far.

v-piga-msft
Resident Rockstar
Resident Rockstar

Hi @Anonymous ,

By my research, I have not found the ways getting Power BI Audit Logs with power query or other ways.

So, I'm afraid that we may not create a Dataflow to extract Power BI Audit Logs currently.

Hope @GilbertQ have other ideas.

Best  Regards,

Cherry

 

Community Support Team _ Cherry Gao
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

Hi there

Currently you have to extract the Audit Logs out into a CSV, which could then be read into a dataflow.

You would also currently have to be an Office 365 Admin to be able to extract data from the Audit Logs.




Did I answer your question? Mark my post as a solution!

Proud to be a Super User!







Power BI Blog

Anonymous
Not applicable

Thanks for the response Gilbert. So, just being a Power BI Service Admin will not work, I will have to be an Office 365 Admin as well. Is that what you meant ?

So, a power query cannot pull the audit logs directly. I will have to use some sort of a powershell script to extract the data in a CSV first. Please correct if my understanding is incorrect Gilbert.

Hi there

Yes all of the above is correct.

You will need an Office 365 Admin account.
And then you can extract it into a CSV.




Did I answer your question? Mark my post as a solution!

Proud to be a Super User!







Power BI Blog

Helpful resources

Announcements
Microsoft Fabric Learn Together

Microsoft Fabric Learn Together

Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City

PBI_APRIL_CAROUSEL1

Power BI Monthly Update - April 2024

Check out the April 2024 Power BI update to learn about new features.

April Fabric Community Update

Fabric Community Update - April 2024

Find out what's new and trending in the Fabric Community.

Top Solution Authors
Top Kudoed Authors