Please note that if the reports are empty, you seem to be getting the error “An error occurred while processing this request” for some of the reports. Here are some further examples on what you can do. Invoke-RestMethod -Uri "$serviceRootURl/reports?api-version=beta" -Headers -ContentType "application/json" | select -ExpandProperty value $authenticationResult = $AuthContext.AcquireToken($resAzureGraphAPI, $clientCredential) $clientCredential = New-Object -TypeName ".ClientCredential"($clientID, $clientSecret) $clientSecret = "7dAkpp6sCfc3n6bfsBRoBYORnMFYeA7LsLVkQX rAn0=" Here is an example of application that gets an oauth token using ADAL and requests a list of all reports:Īdd-type -Path C:\GraphAPI\.51556\lib\net45\.dll ![]() As of writing, it actually seems it does not work with “read and write directory data” at all, only if you check “read directory data” does things start to work (you will see an error message like “Unable to check Directory Read access for appId”). ![]() The Reporting API only requires “read directory data”, not “read and write directory data”. Follow the same steps all the way to “permissions to other applications”. What you must first do, is to follow the first steps in this article to create your application. This time, we will use the new Repoting API. ![]() ![]() In an earlier article ( source) i demonstrated how to use the Azure AD Graph REST API to do things in Azure AD such as creating users, getting users and license users.
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. Archives
May 2023
Categories |