@RestController
@ApiIgnore 添加此注解,则swagger中不会展示此controller
@RequestMapping("xxxxx")
@Validated
public class TestController{}
@RestController
@Api(description = "xxx接口") swagger会展示接口
@RequestMapping("xxxx")
@Validated
public class TestController{}
@ApiOperation(value = "具体的接口描述", notes = "二级描述", httpMethod = "POST")
@PostMapping(value = "xxx")
public 返回类型 test(@ApiParam(value = "参数描述", required = true) @NotBlank @RequestParam("xxx") String xxxx,@Valid @RequestBody 返回Vo类 xxxVo) {
swagger 控制接口显示
于 2022-01-19 11:27:48 首次发布