Looping on same api

Dear All
i have a case of creating companies
each company has different number of employees
i need to loop on add employee details api, which contains uploading profile image
i tried to loop on number of employee and use postman.setNextRequest(“api name”); but i doesn’t work
i tried to add the the api script in the for loop, but i got Uploading files from scripts is not allowed

is their a solution for this case

Hi @rashabadri. Welcome to the Postman community!

Can you share how you used postman.setNextRequest(“api name”) to loop over a request. Ideally, I expect it to work if correctly done.

@gbadebo-bello the request has in the body, dataform with upload doc
fist run it take the doc and add it in the request
when looping on same request, the doc is not added to them

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