How to handle pagination using MS Dynamics data actions

How should I approach the data action from the MS Dynamics data action connector to handle pagination? The goal is to define the page number and page size to navigate through records.

For instance, I am using the Get Contact By Phone Number data action. In my case, the phone number is related to multiple contacts. So I want my GET request to choose a specific record, such as the second record/contact that has that phone number.

With PureCloud API you can use the pageSize and pageNumber properties. But pagination is handled differently by each web service. I am looking for a similar solution however with MS Dynamics 365.

Any ideas how MS Dynamics 365 allows you to navigate through records? I am only able to find the $top query option that MS Dynamic supports but this only allows you to define how many results you want to fetch from MS Dynamics. It doesn't allow you to choose the next record for instance or maybe the third record.

Example of $top query option:
GET cc_WebAPI_ServiceURI/accounts?$select=name&$top=3 HTTP/1.1
Accept: application/json
OData-MaxVersion: 4.0
OData-Version: 4.0

There seem to be at least a couple of ways you could approach this:

You could get multiple results back from MS Dynamics and process them in architect. Here is a write-up that can get you going in the right direction:

Another approach is that you could use the odata.maxpagesize header and @odata.nextLink link to iterate through results 1 at a time.
https://msdn.microsoft.com/en-us/library/gg334767.aspx#bkmk_specifyNumber

This topic was automatically closed 31 days after the last reply. New replies are no longer allowed.