Example 1: Code snippet Import-Module Microsoft.Graph.DirectoryObjects Get-MgDirectoryObject -DirectoryObjectId $directoryObjectId This example shows how to use the Get-MgDirectoryObject Cmdlet.