The aim of this Spring REST Docs extension is to help you write even less - both code and documentation. You still get the same nice documentation as with Spring REST Docs itself. The main benefit is that writing less and moving the documentation closer to the code increases the maintainability of the documentation.
In Spring REST Docs you have to add the documentation for your JSON with a DSL in your test. We moved this documentation to the POJO that represents your JSON object. You just add Javadoc to the fields and it will end up in the documentation.
Learn more in the Introducing Spring Auto REST Docs article. The slides and the video recording from the Introducing Spring Auto REST Docs talk at Spring IO 2017 are also available.
Current 2.0.1 release reference guide (based on Spring REST Docs 2.x).
Current 1.0.13 release reference guide (based on Spring REST Docs 1.x).
Latest master 2.0.2-SNAPSHOT reference guide.
Older releases: 2.0.0, 1.0.12, 1.0.11, 1.0.10, 1.0.9, 1.0.8, 1.0.7, 1.0.6, 1.0.5, 1.0.4.
- Automatic documentation of request and response fields, path, query parameters and request headers using Jackson and Javadoc/KDoc
- Automatic documentation of field and parameter optionality and constraints using JSR 303 annotations
- Automatic documentation of entire endpoint with customizations
- A helper to document authentication
- Support for paging
- Convenient preprocessors
See the Getting started section in the documentation.
See the Building from source section in the documentation.
- Submit a Pull Request for any enhancement you made.
- Create an issue describing your particular problem.
- Ask and answer questions on Stack Overflow using the spring-auto-restdocs tag.
Spring Auto REST Docs is Open Source software released under the Apache 2.0 license.