Graph API | get users

Abhay Chandramouli 1,056 Reputation points
2022-07-28T17:18:33.02+00:00

We have millions of users in ADB2C
I want to fetch all users at once.

or is there a way we can fetch page wise ?

Any solutions please ? It would be great to get all (millions) of users at once .. or we can have some pagination facility to call graph for each page one by one

Community Center | Not monitored
0 comments No comments
{count} votes

Accepted answer
  1. Vicky Kumar (Mindtree Consulting PVT LTD) 1,161 Reputation points Microsoft Employee
    2022-07-29T05:28:04.757+00:00

    Thanks for reaching out to us, if you want to get all user is through graph explorer you have to use pagination
    https://graph.microsoft.com/v1.0/users?$top=999 , You need to follow the @odata.nextLink URI until you reach the final page (which is simply a page without an @odata.nextLink value).

    ref doc - https://learn.microsoft.com/en-us/graph/paging

    the other way to get all user at once, you have to try in PowerShell by using Get-MgUser

    Hope this helps

    Thanks

    0 comments No comments

0 additional answers

Sort by: Most helpful

Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.