CLI for automating 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.25.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) 2019 Adam Edwards.

Package Details



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


Find-GraphPermissions Get-Graph Get-GraphChildItem Get-GraphItemWithMetadata Get-GraphLocation Get-GraphType Get-GraphUri New-Graph Remove-Graph Set-GraphLocation Set-GraphPrompt Show-GraphHelp Update-GraphMetadata


Core Desktop


Release Notes

# AutoGraphPS 0.25.0 Release Notes

This release is incorporates fixes for regressions introduced in the previous
release by the inclusion `AutoGraphPS-SDK` `0.11.1` by updating that dependency
to a new version. It also includes minor features from that version.

This release also includes release note omissions from the previous `0.24.0`

## New dependencies

* AutoGraphPS-SDK 0.12.0

## Breaking changes

## New features
New features in this release originate from the updated `AutoGraphPS-SDK` dependency:

* Added the `ReplyUrl` alias to the `AppRedirectUri` parameter of `Get-GraphToken`, `Connect-Graph` and `New-GraphConnection`
* `Get-GraphConnectionInfo` now includes a connection id guid property in its output to identify each unique connection

## Fixed defects
The bug fixes in this release originate from the updated `AutoGraphPS-SDK` dependency:

* `Test-Graph` command regression prevented targeting clouds other than `Public`
* `Connect-Graph` and `New-GraphConnection` regressions caused certain parameter sets to require all parameters
* Fix race condition with `Connect-Graph` due to MSAL changes with integrated token cache: `Connect-Graph` created
 a new token, which was immediately invalidated, requiring a reconnect when used with a command.
* Fix error output from `Get-GraphToken` due to invalid `$GraphEndpointUri` variable, which also prevented the `GraphResourceUri` parameter from functioning correctly.

## Addendum: omissions from 0.24.0 release notes
These release notes were omitted from the previous release because they actually
describe functionality originating in a dependency rather than this module. Nevertheless,
that functionality is experienced by the user simply as part of this module, so
the notes should have been included so that users could understand and assess the new behavior
including breaking changes.

These notes are included below as a correction.

### Breaking changes

* The `Connect-Graph`, `New-GraphConnection`, and `Get-GraphToken` commands now have the same parameter names where
 the parameters represent the same thing.
* Some command parameter names have been changed for clarity
* The `GrantedPermissions` parameter has been replaced with two new parameters in several commands that
 could take both app-only permissions and delegated permissions: `ApplicationPermisisons`
 and `DelegatedUserPermissions`
* The `Permissions` parameter in several commands auto-completed to both app-only and delegated
 permissions, but since only delegated permissions can be specified at runtime for these
 commands, auto-complete now only completes delegated permissions
* The `NoninteractiveAppOnlyAuth` parameter of several commands is no longer necessary -- the presence of
 `Confidential` and `ApplicationPermissions` parameters indicates the state this parameter represented
* The `ConsentForTenant` flag had an ambiguous meaning and was replaced by `ConsentAllUsers` for
 application management and consent-related commands

### New features

* App-only consent: The code defect in the MS Graph REST API blocking app-only consent was addressed,
 so now `New-GraphApplication`, `Set-GraphApplicationConsent`, `Get-GraphApplicationConsent`,
 and `Remove-GraphApplicationConsent` have been updated to support it
* In particular `New-GraphApplication` automatically consents confidential app-only apps because the
 Graph API for doing so is now fixed. Therefore the command o longer displays a warning when creating
 instructing the user to manually consent the app.
* `Connect-Graph` now returns `GraphConnectionInfo` object
* `Connect-Graph`, `New-GraphConnection`, and `Get-GraphToken` now support the new `GraphResourceUri`
 parameter which allows the caller to use a resource URI that is not the same as the actual
 graph endpoint used for REST. This is useful for test scenarios, such as those where a proxy
 is used to get to Graph -- the resource URI for token acquisition can be set to ``
 using the `GraphResourceUri` parameter, and the endpoint can be the proxy in front of Graph.

### Fixed defects

* Used `ErrorAction Ignore` instead of `SilentlyContinue` in numerous places throughout the code
 to avoid error stream pollution
* General error stream pollution cleanup


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 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 (current version) 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