Spring Rest API with Swagger – Fine-tuning exposed documentation

I tackled details of integration, documentation creation as well as exposition of documentation using Swagger and its module Swagger UI. One of obvious shortcomings that might be serious concern for people managing their API documentation is fine-grained control over what is published and what stays hidden. There are several reasons to decide to hide something from users. First might be the lack of relevance of introspected information that just don’t belong to the documentation. Other big issue might be security concerns as well as the design of API documentation itself.

Continue reading “Spring Rest API with Swagger – Fine-tuning exposed documentation”

Spring Rest API with Swagger – Exposing documentation

Once you create API documentation it is important to make it available to the stakeholders. In ideal case, this published documentation would be flexible enough to account for any last-minute changes and also be easy to distribute (in terms of costs as well as time needed to accomplish this). To make this possible we will make use of what was accomplished in my previous post detailing the process of creation of API documentation. Using Swagger UI module in combination with published API documentation in json allows us to create simple HTML documentation that may be used to interact with the APIs as well.

Continue reading “Spring Rest API with Swagger – Exposing documentation”

Spring Rest API with Swagger – Creating documentation

The real key to making your REST API easy to use is good documentation. But even if your documentation is done well, you need to set your company processes right to publish it correctly and on time. Ensuring that stakeholders receive it on time is one thing, but you are also responsible for updates in both the API and documentation. Having this process done automatically provides easy way out of trouble, since your documentation is no longer static deliverable and becomes a living thing. In previous post, I discussed how to integrate Swagger with your Spring application with Jersey. Now it’s time to show you how to create documentation and publish it for others to see.

Continue reading “Spring Rest API with Swagger – Creating documentation”

Spring Rest API with Swagger – Integration and configuration

Nowadays, exposed APIs are finally getting the attention they deserve and companies are starting to recognize their strategic value. However, working with 3rd party APIs can be really tedious work, especially when these APIs are not maintained, ill designed or missing any documentation. That’s why I decided to look around for ways to provide fellow programmers and other team members with proper documentation when it comes to integration. One way to go is to use WADL, which is a standard specifically designed to describe HTTP based web applications (like REST web services). However there are few drawback when using WADL that made me look elsewhere for solutions how to properly document and expose API documentation.

Continue reading “Spring Rest API with Swagger – Integration and configuration”

RESTful Java with JAX-RS 2.0

In the age of APIs, it is more obvious than ever that significant part of business value of many organizations (or their products) stems from their exposed interfaces. One of the most popular architectural styles to design and build such an API is REST. RESTful web services were introduced to Java in JSR 311 and the specification got name JAX-RS. At the time of writing this review JAX-RS reached version 2.0 and 2.1 is being drafted. Realizing this I felt the need to brush up on my previous knowledge of this technology and see what it has to offer. In my search for study resources I came across an awesome book called RESTful Java with JAX-RS 2.0 by Bill Burke, software architect and developer from Red Hat with years of experience working with REST and related technologies.

Continue reading “RESTful Java with JAX-RS 2.0”