using System.Collections.Generic;
public static void Main()
var s = "{\"featureTypes\": {\n \"featureType\": [\n {\n \"name\": \"PrimitiveGeoFeature\",\n \"href\": \"http://localhost:8080/geoserver/restng/workspaces/sf/datastores/sf/featuretypes/PrimitiveGeoFeature.json\"\n },\n {\n \"name\": \"archsites\",\n \"href\": \"http://localhost:8080/geoserver/restng/workspaces/sf/datastores/sf/featuretypes/archsites.json\"\n }\n ]\n }\n}";
var o = new JsonSerializerOptions
PropertyNameCaseInsensitive = true
var t = JsonSerializer.Deserialize<Test>(s, o);
Console.WriteLine(t.FeatureTypes.FeatureType.Count());
public GeoserverFeatureTypes FeatureTypes {get;set;}
public class GeoserverFeatureTypes
public IEnumerable<GeoserverFeatureType> FeatureType { get; set; }
public class GeoserverFeatureType
public string Name { get; set; }
public string Href { get; set; }