Can we use Swagger in Ivy Project?
Hi all
Now i'm using Axon ivy 6.3. In my project, i have created an Restful API following the [OpenAPI Specification][1]
Now i want to use Swagger to generate YAML file from those API (follow this [guideline][2]). [guideline][2] and this [post][3]).
Here is my web.xml
![alt text][3]text][4]
and this is my Servlet:
public class ApiScanner extends HttpServlet {
private static final long serialVersionUID = -4192689550210212169L;
@Override
public void init(ServletConfig config) throws ServletException {
super.init(config);
BeanConfig beanConfig = new BeanConfig();
beanConfig.setVersion("1.0.0");
beanConfig.setSchemes(new String[]{"http"});
beanConfig.setHost("localhost:8081");
beanConfig.setBasePath("/ivy/api/designer");
beanConfig.setResourcePackage("ch.axonivy.fintech.mybank.website.dossier.api");
beanConfig.setScan(true);
}
}
But nothing happen after i restart ivy.
Has anybody tried it before?
Thanks
[1]: https://swagger.io/docs/specification/about/
[2]: https://github.com/swagger-api/swagger-core/wiki/Swagger-Core-Jersey-2.X-Project-Setup-1.5
[3]: https://stackoverflow.com/questions/34340330/generate-yaml-or-json-file-from-swagger-documentation
[4]: https://answers.axonivy.com/upfiles/Untitled_uG151Fy.png