How to use karate dsl for API Automation testing where I am calling an api (test data) whose response is passed as request body for web api. There are multiple cases with different sets of data hence wanted to know if there is way to have only one scenario which can perform same steps for different data sets.
web api request structure (schema) is complex one like below
{
"date": 1624406400,
"AID": "IND",
"BID": "Z1",
"UserID": "User1",
"BD": [
{
"fromid": "01:00",
"toid": "02:00",
"pd": [
{
"P": 1,
"Q": 10,
},
{
"P": 2,
"Q": 11,
},
]
},
{
"fromid": "01:00",
"toid": "02:00",
"pd": [
{
"P": 1,
"Q": 10,
},
{
"P": 2,
"Q": 11,
}
]
}
]
}