MQTT and {,},",: marks

Dunno. Is there some reason you’re not building up your JSON string like the example you have already looked at?

+ means join strings together into one string.
"first " + "second " + "third "
Strings don’t have to be literals
“before " + myItem.state.toString + " after”