1

I am using Spring-boot for java application. I am able to disable the REST API endpoints followed by this. But I want to disable swagger-ui.html for particular profiles. How to do this?

In pom.xml

    <dependency>
        <groupId>io.springfox</groupId>
        <artifactId>springfox-swagger2</artifactId>
        <version>2.3.1</version>
    </dependency>

    <dependency>
        <groupId>io.springfox</groupId>
        <artifactId>springfox-swagger-ui</artifactId>
        <version>2.2.2</version>
    </dependency>
Community
  • 1
  • 1
SST
  • 2,054
  • 5
  • 35
  • 65

1 Answers1

0

You can see this link : sorry for my answer a little bit short but i can't comment,it's explained here https://stackoverflow.com/a/1790230/4871427

Community
  • 1
  • 1
Hohenheim
  • 1,545
  • 1
  • 12
  • 28
  • Thanks for you reply. I want to disable swagger-ui.html only for particular profiles(example: @Profile("dev")). But I should be accessible REST API endpoints while passing parameters. – SST Feb 24 '16 at 04:06
  • this link maybe could help you : personnaly i didn't try it but seems leg it : http://stackoverflow.com/a/6392926/4871427 – Hohenheim Feb 24 '16 at 08:14