Install-Module -Name Microsoft.PowerApps.Administration.PowerShell
Install-Module -Name Microsoft.PowerApps.PowerShell -AllowClobber
# Connect to your Power Platform environment
Add-PowerAppsAccount
# Set your environment ID
$environmentId = "your-environment-id"
# Get Usage Analytics data
$usageAnalytics = Get-PowerAppAnalyticsEntityUsageMetrics -EnvironmentId $environmentId (period parameters here..)
# Process Usage Analytics data
$usedEntities = @()
$usedAttributes = @()
foreach ($entity in $usageAnalytics.Entities) {
$usedEntities += $entity.EntityName
foreach ($attribute in $entity.Attributes) {
$usedAttributes += "$($entity.EntityName).$($attribute.AttributeName)"
}
}