Skip to content

Get-MgDirectoryRole with GA => insufficient privilege #856

@UnknownB81

Description

@UnknownB81

Hello,

Powershell : 5.1
OS : Windows 10
Microsoft.Graph.Authentication 1.7.0 installed
Microsoft.Graph.Identity.DirectoryManagement 1.7.0 installed

I used Connect-MgGraph and I ckecked my context with Get-MgContext. I'm connected with my Global Admin.
I'd like to list all directory role or GA. I used Get-MgDirectoryRole or Get-MgDirectoryRole -DirectoryRoleId 'a2d10e79-df32-47fc-86ef-64d199860810'.
Result :
**_Get-MgDirectoryRole : Insufficient privileges to complete the operation.
At line:1 char:1

  • Get-MgDirectoryRole -DirectoryRoleId 'a2d10e79-df32-47fc-86ef-64d1998 ...
  •   + CategoryInfo          : InvalidOperation: ({ DirectoryRole...ndProperty =  }:<>f__AnonymousType41`3) [Get-MgDire
     ctoryRole_Get2], RestException`1
      + FullyQualifiedErrorId : Authorization_RequestDenied,Microsoft.Graph.PowerShell.Cmdlets.GetMgDirectoryRole_Get2_**
    
    

Thanks
Mathias

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions