A Spring Boot starter that adds a /swagger-ui/ endpoint containing API documentation.
Questions tagged [springfox-boot-starter]
33 questions
6
votes
1 answer
Swagger 3.0.0: Can't disable in production without SwaggerConfig and @Profile
I'm upgrading to SpringFox Swagger 3.0.0 from 2.x, which introduces the Spring Boot starter springfox-boot-starter dependency that obviates the need for the 2.x-based SwaggerConfig:
/**
* NO LONGER NEEDED
…

Geyser14
- 1,385
- 3
- 14
- 32
5
votes
3 answers
How to disable springfox import on openApi generation?
I would like to replace openapi generator plugin from 5.0.0 to 5.1.0. If I build my project it automatically imports import springfox.documentation.annotations.ApiIgnore; to my all generated by API interfaces.
How can I ignore this implementation?

Makar Shokarev
- 103
- 7
4
votes
2 answers
Refused to apply style because its MIME type ('application/json') is not a supported stylesheet MIME type, and strict MIME checking is enabled
I added swagger-ui to my spring-boot service application and I've got some error like that when visiting the /swagger-ui/ link.
Error in browser console please see the image(click this link)
My reference in swagger is from…

Daniel
- 93
- 3
- 8
4
votes
0 answers
'Ambiguous search mapping detected.' exception is thrown when springfox-boot-starter 3.0.0 is implemented in Spring Boot 2.3.6
An 'java.lang.IllegalStateException: Ambiguous search mapping detected.' exception is thrown when I try to implement springfox-boot-starter 3.0.0 in Spring Boot 2.3.6.
I have two overloaded methods public abstract Collection abc(int) and public…

Man Dee
- 61
- 2
3
votes
3 answers
SpringFox Boot starter: How to disable swagger-ui for production profile?
I am using the io.springfox springfox-boot-starter v 3.0.0,
According to the documentation, this Spring Boot setup would disable the swagger endpoint for prod:
@Configuration
@Profile({"!prod && swagger"})
public class SwaggerConfig implements…

Jeroen Kransen
- 1,379
- 3
- 19
- 45
2
votes
2 answers
Can I get /swagger-ui.html to redirect to /swagger-ui/
At springfogx-swagger-ui 3.0.0 my Spring Boot app ends up with the Swagger UI at http://myapp.example.com:8080/swagger-ui/. My users are used to seeing that URL as http://myapp.example.com:8080/swagger-ui.html. Is there a way I can set up a redirect…

Bob Kuhar
- 10,838
- 11
- 62
- 115
2
votes
0 answers
How to Map response error model in swagger 3.0.0?
I am upgrading my swagger config from 2.9 to 3.0.0 via springfox-boot-starter and I am following https://springfox.github.io/springfox/docs/snapshot/ - very useful.
I am stuck at upgrading below method:
Current implementation:
private…

nanosoft
- 2,913
- 4
- 41
- 61
1
vote
1 answer
Swagger UI OpenAPI 3, query parameters displayed as an object instead of value-changeable fields
Previously in SpringBoot v2.5.7, I had this Spring REST controller method. It had a TestCriteria type DTO, as the path param.
@GetMapping(path = "/test")
public void test(TestCriteria testCriteria) {
}
And the TestCriteria class was like…

code99
- 227
- 4
- 11
1
vote
0 answers
io.springfox:springfox-boot-starter:3.0.0 does not work
I use openjdk-17 and spring 3 (with jakarta)
I want to use
io.springfox:springfox-boot-starter:3.0.0
As I understood it should work without any configurations.
build.gradle
plugins {
id 'java'
id 'org.springframework.boot' version '3.0.0'
…

bleschunov
- 41
- 6
1
vote
0 answers
Run time error while calling v3/api-docs in spring fox 3.0.0
I have upgraded spring boot version from 2.2.7 to 2.7.4. I also upgraded springfox version from 2.9.2 to 3.0.0.
io.springfox
springfox-boot-starter
…

Prem
- 91
- 1
- 14
1
vote
0 answers
springfox-boot-starter 3.0.0 : Unable to infer base url
Because of the vulnerability CVE-2019-17495 in swagger 2.5.2 we are forced to upgrade swagger 3. I have read the documentation here https://springfox.github.io/springfox/docs/snapshot/#migrating-from-existing-2-x-version
Our is Spring boot…

Anish Sharma
- 115
- 1
- 2
- 9
1
vote
1 answer
Error starting ApplicationContext. To display the conditions report re-run your application with 'debug' enabled. How can I solved Problem?
Error starting ApplicationContext. To display the conditions report re-run your application with 'debug' enabled.
2022-04-17 14:36:06.192 ERROR 6200 --- [ restartedMain] o.s.boot.SpringApplication : Application run…

Zekeriya İshak
- 65
- 1
- 1
- 5
1
vote
2 answers
Can't get swagger2 to display swagger-ui.html
The problem
Am learning java spring boot and my problem is getting the swagger front-end to load from http://localhost:8080/swagger-ui.html#/
I get the console message as follows:
WARN 23432 --- [nio-8080-exec-9] o.s.web.servlet.PageNotFound …

mikepoole72
- 65
- 2
- 9
1
vote
0 answers
In springfox 3 (swagger) how do i get useful documentation for a requestbody of a list of objects?
This seems like a very basic functionality for springfox swagger, yet I cannot find how to make it work.
What I would like to see:
@GetMapping('foos')
public ResponseEntity updateFoo(@RequestBody @Parameter List foos) {
// do stuff
}
Should…

Sonja
- 103
- 1
- 2
- 9
1
vote
1 answer
"Ambiguous search mapping detected" thrown after adding Springfox 3.0.0 to SpringBoot
I have a SpringBoot application (spring-boot-starter-parent:2.4.0) and I want to use Swagger. I followed this Baeldung-Tutorial, and I am unfortunately getting this exception on startup:
org.springframework.context.ApplicationContextException:…

hba
- 13
- 3