3

Info about technologies available here:

Spring REST Docs link

Rest Assured link

Ktor backend link

Main question is: Can I generate documentation with json payloads for ktor backend like I did it for Spring backend using Spring Rest Docs

Spring Rest Docs uses unit tests technique to generate json payload and descriptions snippets. This snippets in asciidoctor style used later for including to handwritten documentation.

nail
  • 715
  • 7
  • 20
  • 1
    I didn't try it out in a setup with Ktor, but it should work. REST-assured can be used to test any REST API and Spring REST Docs supports REST-assured. To demonstrate this, I once documented a part of GitHub's API: https://github.com/fbenz/dropwizard-restdocs-demo/blob/master/src/test/java/com/github/fbenz/resources/GitHubApiTest.java – Florian Benz Apr 03 '18 at 16:24
  • I have a similar situation, have you found out something? I know ktor doesn't really start a real web server for its tests and it's pretty problematic to use rest assured there – Roman T Aug 08 '19 at 08:26

0 Answers0