Share via


Controlling page size in Graph API

Question

Wednesday, May 17, 2017 10:11 AM

Looking at msdn.microsoft.com/en-us/library/azure/ad/graph/howto/azure-ad-graph-api-supported-queries-filters-and-paging-options

I see that it says that the default page size is 100 and the maximum page size is 999.

I don't see any way of configuring the page size. I have tried everything that I could think of but nothing has worked so far.

Is it actually possible to change it or do I have to live with the default value of 100?

All replies (3)

Tuesday, May 23, 2017 8:04 AM

Refer to the paging section in the link - https://github.com/Microsoft/api-guidelines/blob/master/Guidelines.md#98-pagination


Friday, February 23, 2018 5:17 PM

You can use $top=999 (or any number from 1 to 999) to change the default value of 100.
Check out here https://developer.microsoft.com/en-us/graph/docs/concepts/paging
and here the parameters you can use in the query https://developer.microsoft.com/en-us/graph/docs/concepts/query_parameters%C2%A0 
Note that not every Graph object supports $top. Not all resources or relationships support paging. For example, queries against directoryRoles do not support paging. This includes reading role objects themselves as well as role members.


Friday, February 23, 2018 9:18 PM

Thanks for updating the forum with the solution that worked for you.