I have the following C# ASP.Net Core Web API controller method for creating an "entity" using a POST:
[HttpPost("example")]
[SwaggerResponse(200,"Ok")]
public async Task<IActionResult> Create([FromForm]MyModel create)
{
return Ok();
}
The model is defined as this:
public class MyModel
{
public string PropA { get; set; }
public string PropB { get; set; }
public List<OtherProp> Other { get; set; }
}
public class OtherProp
{
public string Prop1 { get; set; }
public string Prop2 { get; set; }
}
When this is shown in swagger, you can see the "Other" property array looks like this:
Instead of the broken down model. How do I get swagger to breakdown this model?
