Skip to main content

Notifications

Community site session details

Community site session details

Session Id :
Power Apps - Power Apps Governance and Administ...
Answered

Get Apps as Admin does not return all apps from the environment

(0) ShareShare
ReportReport
Posted on by 16

Hello everyone
I am building a flow that returns all apps and flows created in the last 7 days in the default environment and sends them as a table in an email to the governance team.
The part with the flows works as expected. But Get apps as admin only returns a part of the apps in the environment. The account executing the flow has admin rights and apps are returned but not all.

The problem shouldn't be that there are too many apps, since only 53 are returned in total with a page sizeset to 500. One of the apps that was not found is a simple canvas app that was specially created as a test.

I have not found anything about restrictions on what is returned, except that model driven apps are not found, which cannot be the problem here, as it is a canvas app.

 

Does anyone have an idea what the problem could be and how to get a list of all the apps back?

 

Thank you very much!

Categories:
  • Volker Steltenkamp Profile Picture
    10 on at
    Get Apps as Admin does not return all apps from the environment
    For those of you who desperatly tried to get this to work with the Power Apps for Admins Connector in PowerApps I found this solution:

    Create a control in a Canvas App with an "OnSelect" property, eg a Button and paste this in this property:
     
    //Get the nextLink first
    Set(varAppsinEnvNextLink;PowerAppsforAdmins.GetAdminApps(<YourEnvironmentID>;{'api-version':"2023-06-01"}).nextLink);;
    //Extract the SkipToken from the nextLink
    Set(varSkipToken;(Right(varAppsinEnvNextLink;Len(varAppsinEnvNextLink)-Find("skiptoken=";varAppsinEnvNextLink)-9)));;
    //First Round: Returns about 48 Apps regardless of '$top' value!
    ClearCollect(colAllAppsinEnv;PowerAppsforAdmins.GetAdminApps(<YourEnvironmentID>;{'api-version':"2023-06-01";'$top':("200")}).value);;
    //Second Round: Returns the next about 43 Apps using the first SkipToken
    Collect(colAllAppsinEnv;PowerAppsforAdmins.GetAdminApps(<YourEnvironmentID>;{'api-version':"2023-06-01";'$skiptoken':varSkipToken}).value);;
     
    //Third Round: Get the next nextLink, extract the skipToken and collect the next amount of Apps
    Set(varAppsinEnvNextLink1;PowerAppsforAdmins.GetAdminApps(varEnvDetails.name;{'api-version':"2023-06-01";'$skiptoken':varSkipToken}).nextLink);;
    Set(varSkipToken1;(Right(varAppsinEnvNextLink1;Len(varAppsinEnvNextLink1)-Find("skiptoken=";varAppsinEnvNextLink1)-9)));;
    Collect(colAllAppsinEnv;PowerAppsforAdmins.GetAdminApps(<YourEnvironmentID>;{'api-version':"2023-06-01";'$skiptoken':varSkipToken1}).value);;
     
    Hope this helps someone out. Don´t ask why it has to be so complicated!
  • Mx81 Profile Picture
    860 on at
    Get Apps as Admin does not return all apps from the environment
    Thanks  @Azel.  Pagination works for me.
    Just for all other readers: Page Size changing did not change anything (for me).
     
  • PowerNaps Profile Picture
    16 on at
    Re: Get Apps as Admin does not return all apps from the environment

    Hi @Azel ,

     

    i tried it and it looks like it works for now. All test apps are included. 

    I will have an eye on it if it works as intended.

    The confusing part is that there were not enough apps in the environment to break the normal pagination. But as long as it works now thats fine. Thank you @Azel 
    I will accept the solution for now and will reopen it if it stopps returning all apps.

  • Verified answer
    Azel Profile Picture
    11 on at
    Re: Get Apps as Admin does not return all apps from the environment

    For any one still looking for answer , you need to set up the settings tab for pagination as below:

    Azel_0-1720727831094.png

     

  • PowerNaps Profile Picture
    16 on at
    Re: Get Apps as Admin does not return all apps from the environment

    Hi @Baudelaire,

     

    unfortunately not yet. The strange thing is that list Flows as Admin works without problems and returns the entire list without problems.

  • Baudelaire Profile Picture
    106 on at
    Re: Get Apps as Admin does not return all apps from the environment

    @PowerNaps  Did you resolve this?  I had the same exact issue with a flow I created for governance (highly visible output to global security team) and used the same connector as you.  The connector returned about 75% of the apps.  The account used is a PP Admin.  Using the same exact account, I run PowerShell and get the FULL list.  If this is yet another half-baked connector, Microsoft needs to own it and let people know so they can build solutions using something else.  If there is some trick to get it to return everything, then publish that.  I almost let a violation app stay live because the connector missed it.  Thankfully I saw it accidentally in the admin center and removed it. 

     

  • velegandla Profile Picture
    202 Super User 2025 Season 1 on at
    Re: Get Apps as Admin does not return all apps from the environment

    @PowerNaps 

    The flow should be an extension for our CoE, so that the governace team is informed when new things are created in the default environment. So they get only a list of newly created apps and flows and don't have to look through the inventory. 


    Can you filter the view of Flows in the "Power Platform Admin view" from the starter kit and send an automated email instead of creating a new flow, which would fetch the flows again?

     

    ====================================================

    If this response helped you in any way, please give kudos by clicking the 'Thumbs Up'/'Like' button and/or marking it as an 'Accepted Solution'. This helps others by providing a quick way to identify likely solutions to their issues.

    https://www.linkedin.com/in/devendravelegandla/ 

  • PowerNaps Profile Picture
    16 on at
    Re: Get Apps as Admin does not return all apps from the environment

    Yes i used the Admin account that also runs the CoE and is used for all the admin work in the Power Platform Admin Center as well so i'm sure it has the needed rights. Also i don't get an error if i run the Flow and it is returning a list of apps but it is not complete. In addition the List Flows as Admin V2 step works as intended in the same flow. 

     

    The flow should be an extension for our CoE, so that the governace team is informed when new things are created in the default environment. So they get only a list of newly created apps and flows and don't have to look through the inventory. 

  • velegandla Profile Picture
    202 Super User 2025 Season 1 on at
    Re: Get Apps as Admin does not return all apps from the environment

    @PowerNaps 

     

    Is your account got Power Platform admin rights? 

     

    I tried with my account which is Power Platform admin and returned all the Power Apps. 

     

    Also, can you validate the account with PowerShell commandlets?

    https://learn.microsoft.com/en-us/powershell/module/microsoft.powerapps.administration.powershell/get-adminpowerapp?view=pa-ps-latest#example-4 

     

    Also, other option is leveraging starter kit. Once you configure it, you get all the inventory. 

    https://learn.microsoft.com/en-us/power-platform/guidance/coe/setup 

     

    ====================================================

    If this response helped you in any way, please give kudos by clicking the 'Thumbs Up'/'Like' button and/or marking it as an 'Accepted Solution'. This helps others by providing a quick way to identify likely solutions to their issues.

    https://www.linkedin.com/in/devendravelegandla/ 

     

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Paul Stork – Community Spotlight

We are honored to recognize Paul Stork as our July 2025 Community…

Congratulations to the June Top 10 Community Leaders!

These are the community rock stars!

Announcing the Engage with the Community forum!

This forum is your space to connect, share, and grow!

Leaderboard > Power Apps

#1
WarrenBelz Profile Picture

WarrenBelz 791 Most Valuable Professional

#2
MS.Ragavendar Profile Picture

MS.Ragavendar 410

#3
mmbr1606 Profile Picture

mmbr1606 275 Super User 2025 Season 1

Featured topics