Questions Tagged With openapihttps://answers.axonivy.com/tags/openapi/?type=rssquestions tagged <span class="tag">openapi</span>enFri, 01 Sep 2017 07:02:51 -0400Can we use Swagger in Ivy Project?https://answers.axonivy.com/questions/2842/can-we-use-swagger-in-ivy-project<p>Hi all</p> <p>Now i'm using Axon ivy 6.3. In my project, i have created an Restful API following the <a href="https://swagger.io/docs/specification/about/">OpenAPI Specification</a> </p> <p>Now i want to use Swagger to generate YAML file from those API (follow this <a href="https://github.com/swagger-api/swagger-core/wiki/Swagger-Core-Jersey-2.X-Project-Setup-1.5">guideline</a> and this <a href="https://stackoverflow.com/questions/34340330/generate-yaml-or-json-file-from-swagger-documentation">post</a>). </p> <p>Here is my web.xml <img alt="alt text" src="https://answers.axonivy.com/upfiles/Untitled_uG151Fy.png"></p> <p>and this is my Servlet:</p> <pre><code>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); } } </code></pre> <p>But nothing happen after i restart ivy. Has anybody tried it before?</p> <p>Thanks</p>trungdvFri, 01 Sep 2017 07:02:51 -0400https://answers.axonivy.com/questions/2842/can-we-use-swagger-in-ivy-projectswaggerrestopenapi