spring-rest-docs

Generate and publish Spring REST Docs from MockMvc or WebTestClient test snippets via Asciidoctor.

Updated Apr 9, 2026
One-click install
npx skills add https://github.com/ririnto/sinon --skill spring-rest-docs
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: spring-rest-docs
Source: https://github.com/ririnto/sinon/tree/main/plugins/spring/skills/spring-rest-docs
Command: npx skills add https://github.com/ririnto/sinon --skill spring-rest-docs

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes references (resource) components.

What problem does it solve?

Automates generation and publishing of Spring REST Docs from MockMvc or WebTestClient tests, enabling accurate API documentation.

Core Features & Use Cases

  • Generate and publish REST docs from MockMvc or WebTestClient tests.
  • Publish snippets via Asciidoctor for integrated docs workflows.
  • Keep API contract documentation aligned with tests as the project evolves.

Quick Start

Configure and run your test suite to generate REST Docs snippets and publish the resulting Spring REST Docs documentation.

Frequently Asked Questions about spring-rest-docs

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I generate Spring REST Docs from MockMvc or WebTestClient tests?

Spring REST Docs are generated from MockMvc or WebTestClient test snippets and published via Asciidoctor. This approach keeps API contract documentation accurate and aligned with tests as the project evolves.

Do I need Asciidoctor integration to publish Spring REST Docs snippets?

Yes, Asciidoctor integration is required to publish Spring REST Docs. The workflow takes generated test snippets and compiles them into integrated API documentation using the Asciidoctor pipeline.

Can I use WebTestClient with Spring REST Docs to document REST API endpoints?

Yes, WebTestClient is fully supported for generating Spring REST Docs. You can use it alongside MockMvc to produce snippets that document your REST API endpoints accurately from your tests.

What is the best way to keep REST API documentation aligned with tests in a Spring project?

The best way to align REST API documentation with tests is generating Spring REST Docs from test snippets. This ensures the API contract is verified during testing and published through Asciidoctor automatically.

What limitations exist when publishing Spring REST Docs via Asciidoctor?

Publishing Spring REST Docs via Asciidoctor requires configured Spring REST Docs dependencies in tests. Documentation generation is limited to projects using MockMvc or WebTestClient and depends on test suite execution to produce snippets.