I have a collection with multiple post requests (create account, create address etc.) and a json file as input that looks like this:
Json data file
{
"testdata": {
"accountlist": [
{
"bankname": "BARCLAYS BANK UK PLC",
"accountnumber": "00004005000"
},
{
"bankname": "Bank of America",
"accountnumber": "00004005001"
},
{
"bankname": "Citigroup",
"accountnumber": "00004005002"
},
{
"bankname": "Wells Fargo",
"accountnumber": "00004005003"
},
{
"bankname": "U.S. Bancorp",
"accountnumber": "00004005004"
},
{
"bankname": "PNC Financial Services",
"accountnumber": "00004005005"
}
],
"adresslist": [
{
"city": "Edinburg",
"street": "14 Nile Grove"
},
{
"city": "Copenhagen",
"street": "Frederiksborggade 12"
},
{
"city": "London",
"street": "Piccadilly 421"
}
]
}
}
POST Create Account body
{
"bankname": "{{bankname}}",
"accountnumber": "{{accountnumber}}"
}
POST Create Address body
{
"city": "{{city}}",
"street": "{{street}}"
}
How can I get the testdata.accountlist array into the POST Create Account as input for each iteration and the testdata.addresslist into the POST Create Address as input for each iteration?