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

Announcements

News and Announcements icon
Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Power Automate / how to get the Azure D...
Power Automate
Unanswered

how to get the Azure DevOps Connector to return multiple pages when querying users

(0) ShareShare
ReportReport
Posted on by

When using the Azure DevOps Connector in Microsoft flow to query the ADO api users. It only returns 500 users. How can I get it to return the all of the users?

 

flow.JPG

 

I think I need it to pass back in the continuationToken in the header and return the next page of results. but it doesnt give no default way of doing this.

 

Does anyone know how to get the full set of results back? It only returns a subset.

 

Thanks

Categories:
I have the same question (0)
  • yashag2255 Profile Picture
    24,769 Super User 2024 Season 1 on at

    Hi @InnComing 

     

    As per the API documentation, the list users also returns a continuation string that can be passed further in another http action to get the next set of users: https://docs.microsoft.com/en-us/rest/api/azure/devops/graph/users/list?view=azure-devops-rest-5.1

     

    Hope this Helps!

     

    If this reply has answered your question or solved your issue, please mark this question as answered. Answered questions helps users in the future who may have the same issue or question quickly find a resolution via search. If you liked my response, please consider giving it a thumbs up. THANKS!

  • Community Power Platform Member Profile Picture
    Microsoft Employee on at

    we have like over 10,000 users. I don't want to run the http action 10 times. Do you know how to do a while loop in power automate? e.g.

    while continuation != 'null' keep returning users until it returns all users. 

     

    many thanks!!

  • yashag2255 Profile Picture
    24,769 Super User 2024 Season 1 on at

    Hi @Anonymous / @InnComing 

     

    Yes. You can intialize an integer variable and add the number of users in the org to the value of this variable. Now, add a do until action and then set it to run until this variable value is less than 0. 

     

    Intialize another variable to store the continuation string and then check if that string is empty then do send a request without that and once the request is sent, set the variable to that string. when the string has value, send the request with the string to get the next set of users and after this again add the set variable action to set the new continuation string. Remember to add an increment variable action after every http request and select the first variable you initialized and for the increment value type in -500 (as you have confirmed that it returns 500 users. you can also use the length function to check the number of users returned from the previous action and subtract that from the primary variable)

     

    The loop will run until the number of users are returned as specified in the variable. 

     

    Hope this Helps!

     

    If this reply has answered your question or solved your issue, please mark this question as answered. Answered questions helps users in the future who may have the same issue or question quickly find a resolution via search. If you liked my response, please consider giving it a thumbs up. THANKS!

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

Introducing the 2026 Season 1 community Super Users

Congratulations to our 2026 Super Users!

Kudos to our 2025 Community Spotlight Honorees

Congratulations to our 2025 community superstars!

Leaderboard > Power Automate

#1
Haque Profile Picture

Haque 293

#2
David_MA Profile Picture

David_MA 262 Super User 2026 Season 1

#3
Expiscornovus Profile Picture

Expiscornovus 223 Most Valuable Professional

Last 30 days Overall leaderboard