{
“temperature”: {“value”: body.temp, “timestamp”: when * 1000},
“humidity”: {“value”: body.humidity, “timestamp”: when * 1000}
}
I’m surprised that your first test worked with the comma present at the end…
When I try it in jsonata site ( https://try.jsonata.org/ ) with the comma, I get the error “The symbol “}” cannot be used as a unary operator”.
Also, I don’t know if you did a cut&paste in your message but the double quote is not handled correctly by jasonata because it’s not the correct one: “ vs " .
The cut and paste quotes explains why I was not able to use JSONata site properly.
Can you explain more about the different double quotes? Apparently this one " comes from typing on the keyboard, and this one “ comes from cutting and pasting in some odd way. What a subtle difference!
I don’t know how you get this character but if you paste it in an ASCII converter, you get 0xE2809C . It seems to be a character using UTF-8 3 bytes encoding.
The other double quotes character in the same ASCII converter is 0x22.