How to add swagger in spring boot
1- add dependency:
<dependency>
<groupId>org.springdoc</groupId>
<artifactId>springdoc-openapi-starter-webmvc-ui</artifactId>
<version>2.7.0</version>
</dependency>
2- in spring security(if you are using it), allow following url patterns:
/v3/api-docs/** /swagger-ui/**
and there you have it! swagger is correctly configured in spring boot