CLI for automating and exploring the Microsoft Graph

Minimum PowerShell version


Installation Options

Copy and Paste the following command to install this package using PowerShellGet More Info

Install-Module -Name autographps -RequiredVersion 0.32.0

You can deploy this package directly to Azure Automation. Note that deploying packages with dependencies will deploy all the dependencies to Azure Automation. Learn More

Manually download the .nupkg file to your system's default download location. Note that the file won't be unpacked, and won't include any dependencies. Learn More


Adam Edwards


(c) 2020 Adam Edwards.

Package Details



MSGraph Graph AADGraph Azure MicrosoftGraph Microsoft-Graph MS-Graph AAD-Graph GraphExplorer REST CRUD GraphAPI autograph poshgraph Windows Linux MacOS


Add-GraphRelatedItem Find-GraphPermission Get-Graph Get-GraphChildItem Get-GraphItem Get-GraphRelatedItem Get-GraphItemUri Get-GraphResourceWithMetadata Get-GraphLocation Get-GraphType Get-GraphUri Get-GraphUriInfo New-Graph New-GraphItem New-GraphItemRelationship New-GraphObject Remove-Graph Remove-GraphItem Remove-GraphItemRelationship Set-GraphItem Set-GraphLocation Set-GraphPrompt Show-GraphHelp Update-GraphMetadata


Core Desktop


Release Notes

## AutoGraphPS 0.32.0 Release Notes

This release includes major breaking changes in command names, fixes significant defects in type-related functionality, and adds several features to existing commands. Some commands, such as `Get-GraphChildItem`, gain completely new behaviors.

### New dependencies

* AutoGraphPS-SDK 0.21.0
* Microsoft.Identity.Client (MSAL) 4.14.0
* Microsoft.IdentityModel.Clients.ActiveDirectory (ADAL) 5.2.7

### Breaking changes

* Includes breaking changes from [AutoGraphPS-SDK 0.19.0]( -- `Get-GraphItem` and `Remove-GraphItem` from `AutoGraphPS-SDK` have been renamed to `Get-GraphResource` and `Remove-GraphResource`
* `Get-GraphItemWithMetadata` has been renamed to `Get-GraphResourceWithMetadata`
* `Get-GraphUri` has been renamed to `Get-GraphUriInfo`
* New implementations of `Get-GraphItem` and `Remove-GraphItem` are introduced in this module -- previously they were part of `AutoGraphPS-SDK` and had different functionality than the new version in this module

### New features
* New commands for write operations, and other commands as well!
 * `Add-GraphRelatedItem`: creates a new entity in the graph that is associated with an existing entity through a relationship (i.e. an *OData navigation property*)
 * `Get-GraphRelatedItem`: returns the items related from one entity to a second entity through a relationship property (*OData navigation property*)
 * `Get-GraphUri`: returns the URI of an entity given the type and id, or for a URI with a relationship
 * `New-GraphItem`: creates a new item in the graph
 * `New-GraphItemRelationship`: creates an association from one entity in the graph to a second entity through a relationship property (*OData navigation property*) of the first entity
 * `New-GraphObject`: creates a deserialized reprsentation of an item in the graph or of data structures referenced in the graph. The representation can be converted to the same JSON format used to serialize data in requests to the graph
 * `Remove-GraphItemRelatonship`: removes the association from one entity to a second entity
 * `Set-GraphItem`: updates an existing entity in the graph
* `Get-GraphType` now supports tab-completion for output, so commands like select can be used interactively when building commands in the shell
* New `Get-GraphItem` command: a command with this name was in previous versions of the dependency module `AutoGraphPS-SDK`; this new command supports type-aware access of objects by `id` and other type-related facilities.
* New `Remove-GraphItem` command: a command with this name was in previous versions of the dependency module `AutoGraphPS-SDK`; this new command supports type-aware removal of objects by `id` and other type-related facilities.
* `Get-Graph` now returns an object with additional fields providing more information about the context of the Graph:
 * `Id`: The `Id` field is a guid that uniquely identifies the mounted Graph. If the same graph endpoint is mounted again, it will have a different `Id`. The property can be used for cases such as hashing.
 * `CreationTime`: The time, in the local time zone, at which the graph was mounted
 * `LastUpdateTime`: The time, in the local time zone, at which the graph was last updated by the `Update-GraphMetadata` command. If no such update occurred, the time is the same as the `CreationTime` property
 * `LastTypeMetadataSource`: The source of the type metadata used to define the graph when it was first mounted or last updated, which ever is ost recent. The source is either a URI to an http metadata source like$metadata or the path to a local file containing the same format of data as that hosted at the http URI.
* The `ContentColumns` parameter of `Get-GraphChildItem` and `Get-GraphResourceWithMetadata` has been replaced by the `ContentOnly` parameter which has the following behavior: Instead of returning a uniform `PSCustomObject` with standard members including a `Content` member to access the actual content returned by Graph, the command just returns the actual content, just like the `Get-GraphResource` command.
* The `Get-GraphChildItem` command now also returns children of a type's entityset if applicable
* The `Get-GraphChildItem`, `Get-GraphItem`, and `Get-GraphResourceWithMetadata` commands now support the following parameters (with parameter-completion where applicable):
 * Paging parameter support: `First`, `Skip`, `IncludeTotalCount` parameters are now supported (as they are for the `Invoke-GraphRequest` and `Get-GraphResource` commands of `AutoGraphPS-SDK`).
 * `Expand`: Navigation properties may now be expanded (with parameter completion)
 * `Search`: For supported entities, an API-defined search query may be specified
 * `Sort`, `Descending`: Sorting by specified property (with parameter completion) may be specified
* The `Get-GraphChildItem` and `Get-GraphItem` commands support the `SimpleMatch` parameter that uses a heuristic approach for "casual" graph queries without the need for OData syntax
* Parameter completion is also supported for the `Expand` and `Sort` commands of `Invoke-GraphRequest` and `Get-GraphResource` when this module is installed.
* `Show-GraphHelp` supports complex types
* `Get-GraphType` supports the `TransitiveMembers` parameter and `MemberFilter` parameters
* Various pipeline improvements have been made to most commands to ensure consistency across commands and enable useful scenarios. In general, pipelines should be easy for the typical PowerShell user to exploit and should adhere to the *Principle of Least Astonishment*.

### Fixed defects

* Graph API versions including `v1.0` and `beta` included multiple namespaces for API metadata after March 2020. Types outside of the `` namespace were invisible to AutoGraphPS commands -- this has been fixed with support for multiple namespaces.
* Test execution in CI requires special module-specific logic to rename the AutoGraphPS-SDK modules installed for testing to lower case
* The `ContentColumns` parameter of `Get-GraphChildItem` and `Get-GraphResourceWithMetadata` has been regressed for several releases due to a syntax error which is now fixed.
* Inherited properties were absent from objects generated by `New-GraphObject`
* Inherited properties may be selected for the `Property` argument of `New-GraphObject`
* Fixed race condition in `Update-GraphMetadata` where some commands like `New-GraphObject` and `Get-GraphType` would not reflect the update
* Numerous parameter set fixes to `*-GraphItem*` commands including addressing consistency issues with the parameter sets
* Numerous fixes from commands included from the `AutoGraphPS-SDK` module


Version History

Version Downloads Last updated
0.42.0 32 2/19/2023
0.41.0 372 12/30/2021
0.40.0 259 10/26/2021
0.39.0 216 10/20/2021
0.38.0 289 6/14/2021
0.37.1 234 5/5/2021
0.37.0 216 5/5/2021
0.36.0 235 2/27/2021
0.35.0 251 9/26/2020
0.34.0 209 9/26/2020
0.33.0 209 9/26/2020
0.32.1 254 6/20/2020
0.32.0 (current version) 223 5/24/2020
0.31.0 253 2/4/2020
0.30.0 218 2/1/2020
0.29.0 289 11/6/2019
0.28.0 232 10/24/2019
0.27.0 216 10/23/2019
0.26.0 225 10/16/2019
0.25.0 220 10/7/2019
0.24.0 218 9/24/2019
0.23.0 308 3/18/2019
0.22.0 260 2/3/2019
0.21.1 230 1/19/2019
0.21.0 226 1/14/2019
0.20.0 228 1/8/2019
0.19.0 224 1/7/2019
0.18.2 222 1/6/2019
0.18.1 222 1/5/2019
0.18.0 223 1/4/2019
0.17.0 225 1/2/2019
0.16.1 247 10/30/2018
0.16.0 233 10/15/2018
0.15.1 229 9/30/2018
0.15.0 224 9/24/2018
0.14.0 227 9/16/2018
Show less