Commands › SharePoint Online

Get-SPODataAccessGovernanceInsight

SharePoint Online Microsoft.Online.SharePoint.PowerShell Get-*

Lists various 'Data Access Governance' (DAG) reports in SharePoint admin center.

Quick start script

# Get-SPODataAccessGovernanceInsight — quick start (serv365.ai)
# 1. Connect (app-only shown; interactive: omit the certificate parameters)
Connect-SPOService -Url https://$org-admin.sharepoint.com

# 2. Run and inspect
Get-SPODataAccessGovernanceInsight -ReportEntity <ReportEntityEnum> -ReportID <Guid> | Format-List

# 3. Export for evidence / drift tracking
Get-SPODataAccessGovernanceInsight | Export-Clixml .\SPODataAccessGovernanceInsight-$(Get-Date -Format yyyyMMdd).xml

Syntax — 2 parameter sets

GetAllReportsParameterSet

Get-SPODataAccessGovernanceInsight -ReportEntity <ReportEntityEnum> [-Workload <WorkloadEnum>]
 [-ReportType <ReportTypeEnum>] [<CommonParameters>]

GetReportParameterSet

Get-SPODataAccessGovernanceInsight -ReportID <Guid> [<CommonParameters>]

Parameters (4)

ParameterTypeRequiredWhat it controls
-ReportEntity ReportEntityEnum yes Specifies the entity that could cause oversharing and hence tracked by these reports.
-ReportID Guid yes Specifies the ID of the particular report to be fetched.
-ReportType ReportTypeEnum Specifies the time period of data of the reports to be fetched. A 'Snapshot' report will have the latest data as of the report generation time. A 'RecentActivity' report will be based on data in the last 28 days.
-Workload WorkloadEnum Specifies the datasource of the reports to be fetched i.e., reports for SharePoint sites or for OneDrive accounts.

Reference facts derived from Microsoft documentation, © Microsoft, licensed CC BY 4.0; restructured with original guidance by serv365.ai.