Hey WW,
Good news — most of this is doable via PowerShell or the Power Platform admin connectors, though the solution-to-app/flow linkage is the tricky bit.
Linking Apps & Flows to Solutions
The connection lives in the msdyn_solutioncomponent and msdyn_solution tables in Dataverse. You can query these via the Dataverse Web API or PowerShell using Get-AdminPowerAppSolution (though that cmdlet is limited). The more reliable path is the Dataverse API:
GET https://{env}.api.crm.dynamics.com/api/data/v9.2/solutions?$select=uniquename,friendlyname,solutionid
Then cross-reference solutioncomponents filtered by componenttype (29 = Flow, 67 = Canvas App) to get the component IDs, and map those back to the flow/app owner via Get-AdminFlow or Get-AdminPowerApp.
For the GUID-named solutions — unfortunately that's SharePoint's doing when it auto-creates solutions for list/library automations. There's no clean way to rename them in bulk, but you can filter them out by checking ismanaged = false and correlating the createdby field.
Finding everything owned by a specific user
For your immediate problem (the high-API-usage user), this PowerShell combo will get you there fast:
$userId = "user@domain.com"
Get-AdminFlow -EnvironmentName "{env-guid}" | Where-Object { $_.Internal.properties.creator.userPrincipalName -eq $userId }
Get-AdminPowerApp -EnvironmentName "{env-guid}" | Where-Object { $_.Owner.userPrincipalName -eq $userId }
Inactivity-based cleanup (your 60-day goal)
For flows, Get-AdminFlow returns lastEnabledTime but not last run time — for that you need the flow run history via:
GET /providers/Microsoft.ProcessSimple/environments/{env}/flows/{flowId}/runs?$top=1&$orderby=startTime desc
You can wrap this in a scheduled Power Automate flow or PowerShell script, check the last run date, and then call Remove-AdminFlow / Remove-AdminPowerApp if it's over 60 days. Just be careful with auto-delete — worth sending an owner notification first and giving a grace period.
FWIW — the ownership tracking + inactivity cleanup loop is exactly what we kept rebuilding manually, which eventually led us to build a tool (Impliancy) to handle it automatically (indexing assets by owner, flagging inactivity, reminders before deletion). It's free while in beta if you want a shortcut, but the PowerShell route above will absolutely get you there too.
Hope that helps point you in the right direction — happy to share more specific script snippets if useful.