In general, it is good practice to create a model that your JSON will be deserialized into. To answer your question though if your JSON was in the format
[{key1: value1},{key2: value2}]
you would be able to use a
List<Dictionary<string,object>>()
If you were sure that your values were always string values you could do
List<Dictionary<string,string>>()
As JSON values can be strings (wrapped in quotes), integers (no quotes) or null.
So your Web API controller could be something like this:
[HttpPost]
public IHttpActionResult ReceiveJSON([FromBody]List<Dictionary<string,string>> in_json)
{
// And then one way to iterate over each 'json node' passed
foreach(var dict in in_json)
{
// Do something with dictionary object
}
return Ok(in_sjon);
}
What version of ASP.Net Web API will you be using?