With the spring-boot-starter-jsondoc integrating JSONDoc with Spring Boot application is really simple. Here are the steps:
Declare the dependency to spring-boot-starter-jsondoc:
Configure JSONDoc in application.properties file
See Configuration for more information about JSONDoc configuration properties.
Enable JSONDoc on you configuration class
At this point it is possible to start up the application and go to http://localhost:8080/jsondoc to see the documentation (provided that you wrote the documentation on your services and objects), ready to be used with jsondoc-ui or with your custom documentation viewer.
Optional (but recomended): use jsondoc-ui-webjar to see the documentation
Declare the dependency to the jsondoc-ui-webjar project:
And now you can go to http://localhost:8080/jsondoc-ui.html, insert http://localhost:8080/jsondoc in the box and get the documentation.
In case you are using @EnableWebMvc annotation, then you need to also register resource handlers for static ui resources, in particular: