I have a JSON class like this
{
"Items": {
"Item_1A": {
"prop1": "string",
"prop2": "string",
"prop3": 1,
"prop4": [{
"prop_x": 100
},
{
"prop_y": 200
}]
},
"Item2B": {
"prop1": "string",
"prop2": "string",
"prop3": 14,
"prop4": [{
"prop_z": 300
}]
}
}
}
How could I make it into C# classes? Here is what I have so far:
public class Info
{
public string prop1 {get;set;}
public string prop2 {get;set;}
public int prop3 {get;set;}
public Dictionary<string, List<int>> prop4 {get;set;}
}
public class Response
{
public Dictionary<string, List<Info>> Item {get;set;}
}
I tried to follow this link, but did not work Deserialize nested JSON into C# objects