I am trying to deserialize JSON that i receive from a webservice. The JSON looks like that:
{ "data":
[
{"name": "john", "company": "microsoft"},
{"name": "karl", "company":"google"}
]
}
My model which i want to deserialize into:
public class employee {
public string name {get; set;}
public string company {get; set;}
}
The problem is, that i cannot deserialize using System.Text.Json because of that object name "data". How can i make the deserializer to unwrap / ignore the data tag and just start from whatever is inside that tag?