When I call the GetUsers REST API method for Microsoft Graph, I only get the first 100 users. The odata_nextLink is returned but how should I apply this odata_nextLink in the OutSystems REST API?
Found the mistake... When extracting the skiptoken from the nextLink I forgot to put in ignoreCase: True in the Index function... Now it works fine.
Could you edit your original post and select the forge component you use?
Hi Daniel,I am not using a forge component here. I am creating my own REST API methods for Microsoft Graph.
So your question is about Microsoft graph, not OutSystems?
Hello @Daniël Kuhlmann !
I have the same problem, and I do not get where and how I should add the odata_nextLink. Should I create a new REST API -call for the nextLink? If so, how should I call this method?If you or anyone else can help me, it would be much appreciated!
Hi Eric
I have not much idea about this one but please have a look if this component can help you: https://www.outsystems.com/forge/component-overview/5552/microsoft-graph-connector
Thank you.
Hi Manish,
I did but this component seems to ignore the fact that there can be more than 100 records to be retrieve. I tested it and it doesn’t work.
Hello @Eric Kuijper,
Never done it myself, but per this article you can retrieve the next page of results by sending the URL value of the @odata.nextLink property to Microsoft Graph.
@odata.nextLink
Regards,
AJ
Hi AJ,
Exactly this is what I am now trying. For some reason I can’t get the code to work. I have updated my REST API to include an optional skiptoken parameter. The server action that is calling the method checks whether the nextLink is non-empty and then extracts the skiptoken. Doesn’t work yet.
@Eric Kuijper So in the REST API-url you just put the full URL, e.g. the last one in the picture (screenshot from the article AJ referenced)?
Eric, if you can, can you descibe how you solved this in OutSystems?
Much appreciated!