So I have an api which returns a number of pages (page: 1) in a query as well as data.
I have the repeat for the products and inserts working well, but I want to somehow repeat the whole thing so when it finishes page one the it will start again and add www.url/api?page=2 and so on until it gets to the last page (for example 38)
What would be the best way to do this. Here is my action upto now
Put a Repeat step right before āAPI Action: apiā, and place everything under it. You need a variable to keep track of the current repeat (maybe the Repeat itself has one? Maybe called index or something). In the API call you insert the counter variable (?page={{counter}})
Or, a less error-prone solution (especially as you donāt need to worry about variables colliding or whatever), at the end put a Redirect step to redirect to the current URL with a ?page=$_GET[āpageā]+1
(and in the API Call, you get the $_GET[āpageā])
Would that work?
I had a bit of trouble to understand your context, so donāt be afraid to ask if something in my question doesnāt make sense