I have JSON which is a mapping of string to arbitrary data structures. Something like this:
{"One": 4,
"Two": "Hello",
"Three": [3,4,"super"],
...
}
I need to add an additional key to the mapping. It maps to an integer. After the addition, I need to serialize the data into JSON again, without losing anything of the original JSON.
How can I achieve this using Sarde? I've managed to deserialize JSON data whose structure is totally known to me. But in this case, I can only make the assumption that the JSON is a mapping at top-level.