Forum Discussion

ggraham's avatar
ggraham
Occasional Visitor
3 years ago

Annotations on model properties in SwaggerUI

I have built a ASP.Net Core 3.1 Web API, and I am interested in auto-generating documentation for my clients. I've followed the very simple instructions to install either NSwag or Swashbuckle in my project found here: Microsoft Docs and in both cases I can see documentation for my APIs, but there are no descriptions on the model properties.

Java seems to have an @ApiModelProperty annotation for this, but I don't see a similar attribute in .Net. Is it possible to add descriptions for Model properties in either of these swagger implementations, that would show up in Schema section in the Swagger UI?

No RepliesBe the first to reply