I’ve been using Postman to write tests for an API and things were going well. I have been able to load the response into a object and then interrogate the object to identify is a subset of the expected search responses have been included.
The API now pages the response providing the next URL which could be used to retrieve the next page of content.
The only way I can think to pull out all of the search results is to load the URL into some sort of global variable and use the runner to re-rerun the same test, updating the next URL each time until no further URL is provided by the API. This sounds horrendous because if I’m looking for certain test results then the fulfilled results will all need to go into global environments and then checked once there are no more pages to load.
Am I missing something obvious? Is there any easier way to evaluate a paged search response?