I'm having issues with the Graph API not returning sites and mixing up paged results.
This query
GET https://graph.microsoft.com/v1.0/sites?search=*
Returns a list of some sites … with duplicates, and missing sites.
I have a continuous list of sites beginning with "es0001" up to "es1000", I used all @odata.nextLink
s, with following result (not exhaustive):
es0086
es0090
es0090
es0100
es0105
I can confirm the missing sites do exist on tenant-admin.sharepoint.com (and Get-SPOSite
returns these as well). In total I got 994 of those sites listed, that is 5 missing without accounting for duplicates … of which 693 were no duplicates. Or rather: 300 returned sites were duplicates of sites already returned by the API in a previous page (or duplicate on the same page), and didn't return those 300, now missing, sites.
I cannot understand how a paginated result is so screwed up to miss and return wrong information.
Adding $orderby=name
makes this marginally better to not have as much duplicates, but there are missing sites still.
I would've uploaded some sample files, but this site fails with a 503 error upon uploading.