Skip to content
| Marketplace
Sign in
Visual Studio Code>Snippets>Microsoft 365 PowerShell SnippetsNew to Visual Studio Code? Get it now.
Microsoft 365 PowerShell Snippets

Microsoft 365 PowerShell Snippets

medhacloud

|
538 installs
| (0) | Free
50+ PowerShell snippets for Microsoft 365 administration - Exchange Online, SharePoint, Teams, Azure AD/Entra ID. By MedhaCloud Microsoft Partners.
Installation
Launch VS Code Quick Open (Ctrl+P), paste the following command, and press enter.
Copied to clipboard
More Info

Microsoft 365 PowerShell Snippets

50+ PowerShell snippets for Microsoft 365 administration and migration.

Professional M365 Migration Services: https://medhacloud.com/professional-services/migrations

Features

  • Connection snippets for all M365 services
  • License management
  • Migration batch management
  • Exchange Online administration
  • SharePoint Online management
  • Microsoft Teams administration
  • Azure AD / Entra ID user management
  • Pre-migration assessment tools

Usage

Type the snippet prefix in a PowerShell file and press Tab or Enter.

Available Snippets

Prefix Description
m365-exo-connect Connect to Exchange Online
m365-graph-connect Connect to Microsoft Graph
m365-spo-connect Connect to SharePoint Online
m365-teams-connect Connect to Microsoft Teams
m365-connect-all Connect to all M365 services
m365-licenses License usage report
m365-unlicensed Find unlicensed users
m365-mailbox-report EXO mailbox statistics
m365-migration-status Migration batch status
m365-migration-create Create migration batch
m365-spo-sites List SharePoint sites
m365-spo-storage SharePoint storage report
m365-teams-list List all Teams
m365-team-members Get team members
m365-aad-users Azure AD users report
m365-guests List guest users
m365-mfa MFA status report
m365-groups Export M365 groups
m365-ca Conditional Access policies
m365-premigration Pre-migration assessment
medhacloud-m365 Support information

About MedhaCloud

  • 9+ years of Microsoft expertise
  • 1,200+ active customers
  • ISO 27001:2022 & SOC 2 Type II certified
  • Microsoft Partner

Migration Services

  • Exchange to M365 Migration
  • G Suite to M365 Migration
  • SharePoint Migration
  • Teams Deployment
  • Hybrid Configuration

Links

  • M365 Migration: https://medhacloud.com/professional-services/migrations
  • Website: https://medhacloud.com
  • LinkedIn: https://linkedin.com/company/medhacloud
  • Twitter: https://x.com/medhacloud

License

MIT - MedhaCloud

  • Contact us
  • Jobs
  • Privacy
  • Manage cookies
  • Terms of use
  • Trademarks
© 2026 Microsoft