When using $search
to perform a query on messages in the Microsoft Graph API, the numerous pages of the response can be traversed using the odata.nextLink
parameter (which itself contains a skiptoken).
I have noticed that for certain search queries, I will at some point not receive a nextLink
property to follow and therefore I cannot continue to load the next pages of the result set, despite there definitely being more results to load. I have verified this by comparing in Outlook and with other filter queries.
Steps to reproduce:
In Graph Explorer, enter the following query:
https://graph.microsoft.com/v1.0/me/messages?$search="to:[your email address]"&$top=25
When the results load, click on the value of
@odata.nextLink
to load the next pageContinue to follow the
@odata.nextLink
until nonextLink
parameter is returned in the resultsYou will notice that you haven't reached the beginning of the inbox (chronologically) but there is no
@odata.nextLink
property to follow
I can only assume this is a bug with the API - I don't see anything in the documentation about a page limit (https://msdn.microsoft.com/office/office365/api/complex-types-for-mail-contacts-calendar#UseODataqueryparametersSearchrequests).
Is anyone able to help? This problem essentially renders the $search
functionality useless for us.