Commands › Exchange Online
Get-ComplianceCase
For more information, see Security & Compliance PowerShell. Use the Get-ComplianceCase cmdlet to different types of compliance cases in the Microsoft Purview compliance portal. See the CaseType parameter for a list of these case types.
Quick start script
# Get-ComplianceCase — quick start (serv365.ai)
# 1. Connect (app-only shown; interactive: omit the certificate parameters)
Connect-ExchangeOnline -CertificateThumbprint $thumb -AppId $appId -Organization $org
# 2. Run and inspect
Get-ComplianceCase | Format-List
# 3. Export for evidence / drift tracking
Get-ComplianceCase | Export-Clixml .\ComplianceCase-$(Get-Date -Format yyyyMMdd).xml
Syntax
Get-ComplianceCase [-Identity] <ComplianceCaseIdParameter>]
[-CaseType <ComplianceCaseType>]
[-DomainController <Fqdn>]
[-RecentOnly]
[-RoleGroup <String>]
[<CommonParameters>]
Parameters (5)
Reference facts derived from Microsoft documentation, © Microsoft, licensed CC BY 4.0; restructured with original guidance by serv365.ai.