Megosztás a következőn keresztül:


Microsoft Graph PowerShell overview

The Microsoft Graph PowerShell SDK acts as an API wrapper for the Microsoft Graph APIs, exposing the entire API set for use in PowerShell. It contains a set of cmdlets that helps you manage identities at scale from automating tasks to managing users in bulk using Microsoft Entra ID. It will help administer every Microsoft Entra feature that has an API in Microsoft Graph.

The commands in Microsoft Graph PowerShell are autogenerated from the Microsoft Graph API schema making it easier to get faster updates and functionality. The cmdlet reference content is also autogenerated from the API reference.

Microsoft Graph PowerShell is the replacement for the Azure AD PowerShell and MSOnline modules and is recommended for interacting with Microsoft Entra ID.

Microsoft Graph PowerShell features & benefits

The Microsoft Graph PowerShell SDK provides the following benefits:

  • Access to all Microsoft Graph APIs: Microsoft Graph PowerShell is based on Microsoft Graph API. In addition to Microsoft Entra ID, the Microsoft Graph API includes APIs from other Microsoft services like SharePoint, Exchange, and Outlook, all accessed through a single endpoint with a single access token.
  • Supports PowerShell 7: Microsoft Graph PowerShell works with PowerShell 7 and later. It's also compatible with Windows PowerShell 5.1.
  • Cross-platform support: Microsoft Graph PowerShell works on all platforms including Windows, macOS, and Linux.
  • Supports modern authentication: Microsoft Graph PowerShell supports the Microsoft Authentication Library (MSAL) which offers more security. For example, you can use passwordless sign-in experiences.
  • Supports external identities: Users from other Microsoft Entra tenants can authenticate to services in your tenant with Microsoft Graph PowerShell.
  • Uses least privilege: Microsoft Graph PowerShell permissions aren't pre-authorized and users must perform one-time request for app permissions depending on their needs.
  • Advanced queries: Microsoft Graph PowerShell supports rich, advanced queries via eventual consistency. For example, you can get a near-instant count of all users using advanced queries.
  • Open source: Feature teams and the community can create great PowerShell experiences and share them with everyone.
  • Receives regular updates: Microsoft Graph PowerShell commands are updated regularly to support the latest Graph API updates.

Upgrade your environment to use the Microsoft Graph PowerShell SDK

To understand how to migrate from Azure AD PowerShell to Microsoft Graph PowerShell, follow the migration guide.

Install the Microsoft Graph PowerShell SDK

The Microsoft Graph PowerShell SDK is published on the PowerShell Gallery. Follow the Install the SDK instructions to install the Microsoft Graph PowerShell SDK.

Get started

To perform basic tasks, use the Get-started guide.

Next steps