web
You’re offline. This is a read only version of the page.
close
Skip to main content

Notifications

Announcements

Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Power Automate / Get files (properties ...
Power Automate
Answered

Get files (properties only) limited to 516 results

(0) ShareShare
ReportReport
Posted on by 2,307 Super User 2025 Season 2

I'm trying to get files from a SharePoint library, but no matter the top count, the Get files (properties only) connector only returns 516 items. The total number of items (files and folders) in the library is about 155,000.

I always get 516 items if the top count is set to higher than 516.

There is no longer any pagination option in the Get files (properties only) action, only the top count. Is this expected behaviour? Do I now need to use the Graph API to get more items using the Odata.nextlink property?

Categories:
I have the same question (0)
  • Verified answer
    v-alzhan-msft Profile Picture
    on at

    Hi @WillPage ,

     

    I have made a test on my side and as you said, the pagination function is no longer supported in the Get files action currently.

    And I'm afraid that the Get files action would always have the file limit such as 516 as you said, you couldn't use the Get files action to get the all 155,000 files currently and maybe the only way is take a try to use the Graph API to achieve the requirement.

     

    Best Regards,

    Alice

     

    Community Support Team _ Alice Zhang
    If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

  • Verified answer
    efialttes Profile Picture
    14,756 on at

    Hi!

    For 'Get items' you can activate pagination. For 'Get files' you need to use Graph API (as @v-alzhan-msft  suggests) or follow a 'Do Until' based strategy.

    If you are interested in this second approach, please check 'Using the Do Until method' section on this great article

    https://alextofan.com/2019/08/22/how-to-get-more-than-5000-item-from-sharepoint-online-in-flow/

    Article focuses on 'Get items' scenario but 'Using the Do Until method' section can be applied to 'Get files' also.

    Finally, from the figures you shared, I would expect the 'Do Until method' approach to be quite slow in terms of performance, since you will need more than 300 iterations

    Hope this helps

  • WillPage Profile Picture
    2,307 Super User 2025 Season 2 on at

    Thanks for that @efialttes I probably would have used that method if I'd seen it soon enough. Instead I used the Graph API lists endpoint to get the items and handled pagination myself using the odata.nextLink property, because the HTTP action in PA only supports a maximum of 100,000 items and I have more than that.

    I still hit a hard limit where the array variable I use to store the results reaches 100MB in size, but by then with $top=999 it's on page 140 and collected very nearly all the results. I could squeeze it in by being judicious with the $select query to reduce the size of the response.

     

    A word to the wise: Don't let document libraries get this big!

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

Forum hierarchy changes are complete!

In our never-ending quest to improve we are simplifying the forum hierarchy…

Ajay Kumar Gannamaneni – Community Spotlight

We are honored to recognize Ajay Kumar Gannamaneni as our Community Spotlight for December…

Leaderboard > Power Automate

#1
Michael E. Gernaey Profile Picture

Michael E. Gernaey 519 Super User 2025 Season 2

#2
Tomac Profile Picture

Tomac 296 Moderator

#3
abm abm Profile Picture

abm abm 232 Most Valuable Professional

Last 30 days Overall leaderboard