I retrieve data with a GET and then use the values in a POST. There is a field whose response I want to increment by 1 by default. So if the response from the GET is 5 I want to post 6. To get the content from the GET and write it to the variables to use as POST I wrote the following in Tests:
valueincomeRelationshipNumber = bodydata._embedded[0].incomeRelationshipNumber
console.log(“value of incomeRelationshipNumber:” + valueincomeRelationshipNumber)
pm.environment.set(“Income Ratio No.”, valueincomeRelationshipNumber);