NSwag change controller description

Add [OpenApiTag("RenameName")] to your controller like below:

using NSwag.Annotations;

[Route("api/[controller]")]
[ApiController]
[OpenApiTag("User Location")]
public class RefUserLocationController : ControllerBase
{...}

Result: enter image description here

Note:

I use NSwag.AspNetCore version 13.8.2.So the SwaggerTag is obsolete,if you used the older version of nswag,you could use [SwaggerTag("User Location")].

CLICK HERE to find out more related problems solutions.

Leave a Comment

Your email address will not be published.

Scroll to Top