Microsoft just announced that the Power BI admin Scanner API (WorkspaceInfo) will now include even more valuable metadata such as scheduled refresh settings and RLS configuration. The Scanner API is where you can get a complete extract of all the artifacts in your Power BI tenant.
We can now also get this low level information:
- Scheduled refresh settings
- RDL data source properties
- Dataset sub-artifact metadata content
- RLS configuration
- Datamart metadata
This is an addition to “names of dataset tables and columns” and the “DAX and mashup expressions” that was already possible to get.
Enable the admin tenant settings
If you want to extract both the existing and new metadata information, you will need to enable it up in the admin tenant settings – or get a friend to do it! Find the “Admin API settings” block and either enable it for the entire organization or only to the same subset that you allow to query the read-only admin API’s.
Specify it in the API request
I have chosen not to include it in my Integration Pipeline as it then only will work for the ones who has enabled the tenant setting. But it’s quite easy to make the change. Locate the “PL_PowerBIWorkspaceInfoScanResult” pipeline and open the “Post WorkspaceInfo” activity. Then find the “URL” under “Settings”.
The box is ridiculous small, so I recommend copying the content into notepad or similar. It should look like this:
You will then need to add two more URI parameters so the string will become like this:
And then copy the URL back into the box and save/publish the pipeline.
Next time you run the “PL_PowerBIWorkspaceInfo” pipeline you will get the information as part of the JSON response. If you want to query the information with the Synapse SQL serverless endpoint, then check out my other blog post. I haven’t yet extended my scripts to include the new metadata, so you will need to do a little work yourself. Probably a good idea to make specific queries for each type of metadata, as most of them is contained in an array and then will “explode” the output.