I am trying to create a conditional workflow using setNextRequest. This workflow should do subsequent API call only when statuscode of current call is 201
My test looks something like this
var returnData = JSON.parse(responseBody);
tests["status code"] = (responseCode.code === 201);
if (responseCode.code == 201) {
postman.setNextRequest('ConfigurationModel-Module');
}
But even when my API response is 409 subsequent API call are triggered in postman runner