Goal: Show SWAGGER Code Generation simple example with Spring Boot
- Describe your API using Swagger Editor -
- Create simple Spring Boot Project - https://start.spring.io/
- Add maven dependencies - see
./pom.xml
file or use SpringFOX https://springfox.github.io/springfox/docs/current/ - Describe Swagger Codegen Plugin Execution https://github.com/swagger-api/swagger-codegen
- Compile project to generate sources - see
How to Build
block - Star this Repository ;) Spring Boot How to - https://spring.io/guides/gs/spring-boot/ Swagger Example - https://www.baeldung.com/spring-boot-rest-client-swagger-codegen
Install Maven
https://maven.apache.org/install.html\
Clone project
Use next command line command to quickly generate swagger sources in ./target
folder
mvn clean compile -P !generate-api-only
Or use generation of API only
mvn clean package