What is a useful model which could bind a json object with arbitrary keys? Assume your json could look like:
{"@@hello": "address","#world": "address1","name": "address"}
or
{"@@hello": "address","#world": "address1","firstname": "foo", "lastname":"bar"}
or
{"@@hello": "address","#world": "address1","children": [{"name":"foo"},{"name":"bar"}]}
So that means you only know at run time how the json model looks like. My current state is, that it seems the best practice is to send the json object as string to the controller and deserialize the json string it to an object.
public ActionResult mappingNodes(string model) {
dynamic json = Newtonsoft.Json.JsonConvert.DeserializeObject(model);
}
Dictionary<string, object>? It's obviously not as nice as having a model, but I think it will be quite difficult to try and map the properties to a model.