I need to transform this json array:
[
{
"timestamp": "2025-01-19T17:00:00Z",
"absoluteDeviationsX": [10, 11, 12 ]
},
{
"timestamp": "2025-01-20T17:00:00Z",
"absoluteDeviationsX": [20, 21, 22 ]
]
}
]
to:
[
{
"timestamp": "2025-01-19T17:00:00Z",
"absoluteDeviationsX0": 10,
"absoluteDeviationsX1": 11,
"absoluteDeviationsX2": 12,
},
{
"timestamp": "2025-01-20T17:00:00Z",
"absoluteDeviationsX0": 20,
"absoluteDeviationsX1": 21,
"absoluteDeviationsX2": 22,
}
]
with JSONata.
I need this to process data in Infinity plugin in Grafana.