Closed pawp81 closed 2 years ago
Same error here as a GA : Invoke-RestMethod : {"odata.error":{"code":"Authorization_RequestDenied","message":{"lang":"en","value":"Insufficient privileges to complete the operation."},"requestId":"3c9XXXXXXX6e","date":"2021-05-07T18:20:54"}} Au caractère C:\Program Files\WindowsPowerShell\Modules\AADInternals\0.4.6\MDM.ps1:795 : 9
+ CategoryInfo : InvalidOperation : (System.Net.HttpWebRequest:HttpWebRequest) [Invoke-RestMethod], WebException
+ FullyQualifiedErrorId : WebCmdletWebResponseException,Microsoft.PowerShell.Commands.InvokeRestMethodCommand
Sorry for the late response, I didn't receive any notifications due to misconfigured settings. Anyways, I'll have a look at this some point later this week. Global Admin should have all permissions, so probably Microsoft have made some changes. I assume they have limited this to certain clients (and/or custom apps).
After enrolling device to Intune if I try to set it as compliant with Set-AADIntDeviceCompliant I receive following error: Invoke-RestMethod : {"odata.error":{"code":"Authorization_RequestDenied","message":{"lang":"en","value":"Insufficient privileges to complete the operation."},"requestId":"7f1ca352-fcb8-4f69-bbef-f47eda0beb69","date":"2021-03-24T18:37:56"}} At C:\Program Files\WindowsPowerShell\Modules\AADInternals\0.4.6\MDM.ps1:795 char:9
What permissions user needs to have to run Set-AADIntDeviceCompliant?