Hi, I am looking how to handle cases when json format may vary between different client responses. On response
{
"data": [
{
"ID": "123",
"Name": "Queen"
},
{
"ID": "456",
"Name": "King"
}
]
}
we apply following jolt transform:
[
{
"operation": "shift",
"spec": {
"data": {
"*": {
"ID": {
"456": {
"@(2,Name)": "Name"
}
}
}
}
}
}
]
but some times response is coming without leading "{"data":
and our transformation fails. So, generally, how can we query json with JOLT if we know for instance that Name and ID are next to each other somewhere in the structure?