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

See when key Fabric features will launch and what’s already live, all in one place and always up to date. Explore the new Fabric roadmap

Reply
jenrom_flix
New Member

Enable programmatically logging to Log Analytics for Power BI Workspaces

I'm trying to find a way to automate the process of enabling query log offloading to Log Analytics for Power BI workspaces. My assumption was that this functionality would be available through the Fabric or Power BI REST API, but I haven't found any relevant endpoints in the documentation.

So far, the only method I’ve come across is through the Power BI Service UI, which is quite cumbersome and not scalable for our case.

 

Has anyone been able to automate this, or is it truly only possible via the UI?

5 REPLIES 5
v-hashadapu
Community Support
Community Support

Hi @jenrom_flix , Just checking in—were you able to resolve the issue?

 

If one of the replies helped, please consider marking it as "Accept as Solution" and giving a 'Kudos'. Doing so can assist other community members in finding answers more quickly.
Thank you!

v-hashadapu
Community Support
Community Support

Hi @jenrom_flix ,
I hope the information shared was helpful. If you have any additional questions or would like to explore the topic further, feel free to reach out. If any of the responses resolved your issue, please mark it "Accept as solution" and give it a 'Kudos' to support other members in the community.
Thank you!

v-hashadapu
Community Support
Community Support

Hi @jenrom_flix , Thank you for reaching out to the Microsoft Community Forum.

Please let us know if your issue is solved. If it is, consider marking the answers that helped 'Accept as Solution', so others with similar queries can find them easily. If not, please share the details.
Thank you.

v-hashadapu
Community Support
Community Support

Hi @jenrom_flix , Thank you for reaching out to the Microsoft Community Forum.

 

As of May 2025, enabling query log offloading to Azure Log Analytics for Power BI workspaces can only be done manually through the Power BI Service UI. There are no supported REST API endpoints, PowerShell cmdlets, or Microsoft Fabric APIs that allow this setting to be automated.

 

You can use Robotic Process Automation (RPA) tools like Power Automate Desktop or UiPath to simulate the manual steps in the UI. These tools can be configured to log into Power BI Service, navigate to each workspace and enable the Log Analytics connection. While this method can work, it is not officially supported by Microsoft, it is fragile (prone to breaking if the UI changes) and it requires careful handling of credentials and error checking. It should only be used with strong monitoring, regular testing and stakeholder awareness that this is a temporary solution.

 

To track and validate which workspaces have logging enabled, you can use the Power BI REST API (GET /admin/groups) to list workspaces and correlate that with data received in Log Analytics. This helps maintain visibility while relying on RPA. If this functionality is critical to your environment, it’s recommended to submit a request through the Fabric Ideas portal and get as many upvotes as possible, as Microsoft monitors it and features with most upvotes have more possibility to be released.

 

If this helped solve the issue, please consider marking it “Accept as Solution” and giving a ‘Kudos’ so others with similar queries may find it more easily. If not, please share the details, always happy to help.
Thank you.

BhavinVyas3003
Impactful Individual
Impactful Individual

Currently, enabling query log offloading to Log Analytics for Power BI workspaces can only be done via the Power BI Service UI. There are no direct API endpoints for automating this. However, you can use PowerShell cmdlets for some workspace management tasks, or combine Azure Automation and Logic Apps for scalable monitoring, though they won't directly enable log offloading.

Helpful resources

Announcements
May PBI 25 Carousel

Power BI Monthly Update - May 2025

Check out the May 2025 Power BI update to learn about new features.

May 2025 Monthly Update

Fabric Community Update - May 2025

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

Top Kudoed Authors