Daniel Kaplan
Daniel Kaplan

Reputation: 67514

Can spring restdocs generate live documentation like swagger?

As a developer, I prefer spring restdocs. But as a consumer of the documentation, I find the swagger live documentation to be very compelling. Here's the ubiquitous example: http://petstore.swagger.io/

Is there a way to document my rest apis with spring restdocs but generate live documentation like the swagger petstore with it? If so, how do you do this?

Upvotes: 3

Views: 459

Answers (1)

Andy Wilkinson
Andy Wilkinson

Reputation: 116311

No, it's not possible out of the box. REST Docs is intended to be extensible so you could add the functionality yourself but it would be a significant undertaking.

I'm the lead of the REST Docs project and support for live documentation is of interest, but it's not a particularly high priority at the moment. In my experience, live documentation can be useful as a playground but does a poor job of actually documenting a service. My focus at the moment is on producing accurate and well-structured documentation. Using REST Docs with Slate can give you a big jumpstart on the latter if you're looking for something more guiding than Asciidoctor's blank canvas.

Upvotes: 7

Related Questions