From d47c6b97084c1b3ccabe55719d8e69852c78a0a6 Mon Sep 17 00:00:00 2001 From: Teodora Onaca Date: Tue, 5 Apr 2016 12:05:26 +0200 Subject: [PATCH] Update 2016-04-05-generate-swagger.md --- _posts/2016-04-05-generate-swagger.md | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/_posts/2016-04-05-generate-swagger.md b/_posts/2016-04-05-generate-swagger.md index c8833ad..1b224b1 100644 --- a/_posts/2016-04-05-generate-swagger.md +++ b/_posts/2016-04-05-generate-swagger.md @@ -1,5 +1,4 @@ - ---- +--- layout: post title: Generating Swagger from your API subtitle: How to quickly generate the swagger documentation from your existing API. @@ -8,7 +7,7 @@ tags: [devops] author: teodora_onaca author_email: teodora.onaca@haufe-lexware.com header-img: "images/bg-post.old.jpg" ---- +--- If you already have an existing API and you just want to generate the swagger documentation from it, there are a couple easy steps to make it work. First off, you should be familiar with Swagger and, in particular, with [swagger-core](https://github.com/swagger-api/swagger-core). Assuming that you coded your REST API using JAX-RS, based on which was your library of choice (Jersey or RESTEasy), there are several [guides](https://github.com/swagger-api/swagger-core/wiki/Swagger-Core-JAX-RS-Project-Setup-1.5.X) available to get you set up very fast. @@ -174,4 +173,4 @@ In order to fix this, use `@ApiParam(hidden=true)` for the subresource `@PathPar } -There might be more tips and tricks that you will discover once you start using the annotations for your API, but it will not be a slow learning curve and once you are familiar with swagger (both spec and core) you will be able to document your API really fast. \ No newline at end of file +There might be more tips and tricks that you will discover once you start using the annotations for your API, but it will not be a slow learning curve and once you are familiar with swagger (both spec and core) you will be able to document your API really fast.