Quantcast
Channel: Developer topics
Viewing all articles
Browse latest Browse all 17905

API- Get Last Refresh of all reports of a workspace

$
0
0

I am looking to develop a solution to alert me when any report does not automatically refresh overnight. 

The powerbi rest API seems to be the easiest way to accomplish this

 

I can get a full list of all the reports in my workspace using this: 

Get https://api.powerbi.com/v1.0/myorg/groups/GROUP_ID/datasets

 

which returns something like this:

{
"id": "ID",
"name": "Call Dashboard",
"addRowsAPIEnabled": false,
"configuredBy": "EMAILadress",
"isRefreshable": true,
"isEffectiveIdentityRequired": false,
"isEffectiveIdentityRolesRequired": false,
"isOnPremGatewayRequired": true
},

 

Which gives me a complete list of all the reports but doesnt include the last refresh date

 

Now if i use something like this:

Get https://api.powerbi.com/v1.0/myorg/groups/Group_ID/datasets/DATA_SET_ID/refreshes/?$top=1

 

It gives me:

{
"id": ID,
"refreshType": "Scheduled",
"startTime": "2018-04-18T04:00:31.857Z",
"endTime": "2018-04-18T04:08:49.203Z",
"status": "Completed"
}

 

So basically my question is how can i combine those to return a full list of all reports including the last refresh of each one.

Searched through the google as well as this site but couldn't find any direction 


Viewing all articles
Browse latest Browse all 17905

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>