Canvas App Inventory Sync to Dataverse
Scheduled flow uses Power Apps for Admins to list all canvas apps across all environments, then upserts each record into a Dataverse custom table. Foundation pattern for any COE reporting dashboard.
Provided as-is, without warranty of any kind. Review and test each pattern in a non-production environment before deploying it to live automations. See our Terms.
Overview
This flow provides a foundation pattern for Center of Excellence (COE) reporting by automatically syncing canvas app metadata from the Power Apps for Admins connector into a Dataverse custom table. Running on a daily schedule, it captures every canvas app in the target environment — including display name, app ID, owner details, and creation/modification timestamps — and writes each record to a dedicated inventory table. This data layer enables Power BI dashboards, compliance audits, and governance automation.
Use Case
IT Admins and platform governance teams need a reliable, up-to-date inventory of all canvas apps in their tenant. Manual inventories drift within days. This flow automates the collection so that downstream reporting (adoption dashboards, orphaned app detection, license auditing) always has fresh data.
Flow Architecture
Recurrence - Daily Sync
RecurrenceFires daily at 06:00 UTC.
Initialize varEnvironmentName
InitializeVariableReads the flowlibs_PAEnvironmentName environment variable into a string variable.
Initialize varSyncTimestamp
InitializeVariableCaptures utcNow() so every record in the batch shares the same sync timestamp.
Initialize varAppCount
InitializeVariableInteger counter for tracking how many apps were processed.
Get All Canvas Apps as Admin
Power Apps for Admins (Get-AdminApps)Retrieves up to 250 canvas apps from the target environment.
Apply to Each App
ForeachFor each app in body/value returned by Get All Canvas Apps as Admin: creates a Dataverse inventory record with the app's display name, app ID, environment, owner display name, owner email, created date, modified date, and the shared sync timestamp; then increments varAppCount by 1.
Environment Variables
| Schema name | Type | Default | Description |
|---|---|---|---|
| flowlibs_PAEnvironmentName | String | <your-tenant-id> | The environment ID to scan for canvas apps (format: default-{tenant-guid}). Reusable across governance flows. |
Connectors & Connections
| Connector | API name | Actions used |
|---|---|---|
| Power Apps for Admins | shared_powerappsforadmins | Get-AdminApps (Listing all canvas apps in the environment) |
| Microsoft Dataverse | shared_commondataserviceforapps | CreateRecord (Creating inventory records in the custom table) |
Note — All connections are referenced as solution connection references; the flow is portable between environments as long as a connection is mapped at import time.
Customization Guide
Almost every realistic variant of this flow can be implemented by changing environment variable values. A few cases require small edits inside the flow definition — those are called out explicitly below.
- Deploy in your environment
- Import the FlowLibsCanvasAppInventorySync solution into the target environment, update the flowlibs_PAEnvironmentName environment variable current value to your environment's ID (format: default-{tenant-guid}), authorize both connection references (Power Apps for Admins and Dataverse — the authorizing user needs System Administrator or Power Platform Admin role), and turn on the flow.
- Add pagination
- The $top parameter is set to 250. For environments with more apps, add a Do Until loop with nextLink handling to page through all results.
- Add upsert logic
- Create an alternate key on flowlibs_appid and switch the CreateRecord action to UpdateRecord (Upsert) to avoid duplicate rows on re-runs.
- Add email summary
- After the Apply to Each, add an Outlook SendEmailV2 action that uses varAppCount to report how many apps were synced.
- Multi-environment scan
- Wrap the entire flow in another Apply to Each that iterates over a list of environment IDs to sync inventory across multiple environments in one run.
Key Expressions
The flow is intentionally light on Power Fx / WDL gymnastics — the heaviest expressions are the branch-name concatenation and the approval outcome check. They are listed below in the order they appear in the flow.
EXPR.01Read environment variable
Used in Initialize varEnvironmentName to read the solution env var.
EXPR.02Batch sync timestamp
Used in Initialize varSyncTimestamp to capture a single timestamp shared by every record in the batch.
EXPR.03Iterate apps array
Used in Apply to Each App to loop over the canvas-app array returned by Get-AdminApps.
EXPR.04Map app display name
Used in Create Inventory Record to map the app's display name into flowlibs_name.
EXPR.05Map app GUID
Used in Create Inventory Record to map the app ID into flowlibs_appid (the 'name' field on the Get-AdminApps response is the app GUID).
EXPR.06Map owner display name
Used in Create Inventory Record to map the owner display name into flowlibs_ownerdisplayname.
EXPR.07Map owner email
Used in Create Inventory Record to map the owner email into flowlibs_owneremail.
EXPR.08Map created timestamp
Used in Create Inventory Record to map the app's creation timestamp into flowlibs_appcreatedon.
Comments
Sign in to join the conversation.
Sign inNo comments yet. Be the first to share your experience with this flow.