[SalesForce] Consume REST API pagination

I am new to the Salesforce/Marketing Cloud APIs and need to consume the Contact API (attribute search) for part of a solution that I am providing a client. I'm successfully getting expected data returned from my call, but the page, pageSize, and count fields of the returned data structure make it clear that there is the potential for pagination. The documentation for the request JSON doesn't have anything that stands out to me as being related to pagination, so what is the approach to handling paged data in this API?

Best Answer

There is documentation under 'Search Contacts', for example, located in the Marketing Cloud API reference material

You can append the $page to your request URL, for example:

www.exacttargetapis.com/contacts/v1/contacts/search?$page=2

You can return, initially, up to 50 pages with 50 results per page for a max of 2500. But there are ways to continue the request to get more than the initial 2500.

Related Topic