Re: How paginate through get folders bulk API

Murali_Nagula
Level 2

How paginate through get folders bulk API

I am trying to retrieve the folders in bulk using the following API:

http://developers.marketo.com/rest-api/endpoint-reference/asset-endpoint-reference/#!/Folders/getFol...

 

I have kept the  maxReturn=200 but have more than 200 folders. I have gone through the posts and they suggest to use offset but doesn't mention how? The response object doesn't return total_count or any indicator which tells me there is a next batch/page ? How do I know I have reached the last url call? What should I use for to derive 'have next url' and next url parameters. We are using Snaplogic as integration tool.

1 REPLY 1
Casey_Grimes
Level 10

Re: How paginate through get folders bulk API

The offset you receive in the response from the endpoint lets you page through total results per the max return you've set--so you'd continue paging through the results via offset until you hit a number under 200. At that point, you'd have your count of folders. There's no meta "total" value, as the results themselves are what you're supposed to tabulate to figure that out.