Skip to main content
The 2026 Annual Developer Survey is live— take the Survey today!

Question list filters

Filter by
Sorted by
Tagged with
Filter by Employee ID
Score of 0
1 answer
140 views

I'm currently writing tests using RestAssuredMockMvc together with Spring REST Docs. Setup In my global spec setup, I configure the headers like this: package com.animore.config import com.fasterxml....
Score of 0
0 answers
93 views

Spring Rest Docs 3.x removed the preprocessor to modify request parameters. In the release notes, it is unclear how to do it now. I would love to see an example of how it can be done now. Anybody has ...
Score of 1
1 answer
134 views

Is there a way to produce RestDocs with the new (since Boot 3.4) MockMvcTester API? (Not using plain MockMvc?) I did not find any API on the new fluent style MockMvcTester. assertThat( ...
Score of 0
1 answer
195 views

I'm trying to document the API using Spring RESTDocs on Spring 3.3.2. However, the following error appears. Query parameters with the following names were not found in the request: [password, driverId,...
Score of 1
0 answers
150 views

I’m currently working on a Spring Boot project and I’m using the com.epages.restdocs-api-spec library version “0.18.2” to generate API documentation. However, I am having trouble documenting endpoints ...
Score of 1
1 answer
49 views

test { useJUnitPlatform() outputs.dir snippetsDir } asciidoctor { configurations "asciidoctorExtensions" inputs.dir snippetsDir dependsOn test doLast { copy{ from ("${asciidoctor....
Score of 1
1 answer
80 views

I am using spring docs 2.0.5 release version I am using gradle 8.6, and i refer to this example to configure asciidoctor -i refered below link https://github.com/spring-projects/spring-...
Score of 0
1 answer
46 views

spring boot 2.7.6 having issue while creating war using asciidoctor.jvm.convert 2.4.0 and spring docs 2.0.5 test { useJUnitPlatform() outputs.dir snippetsDir } asciidoctor { configurations "...
Score of 0
1 answer
283 views

I'm trying to write Spock test cases for my Spring Boot application (version: 2.7.5), and I want to generate AsciiDoc documentation using Spring REST Docs. Can someone provide a sample working code ...
Score of 0
0 answers
545 views

import static org.springframework.restdocs.request.RequestDocumentation.requestParameters; User java: cannot find symbol symbol: static requestParameters location: class org.springframework....
Score of 0
0 answers
135 views

I'm currently working with Spring Boot and JPA, and I'm using the @Builder pattern for my entity classes. For my primary key field id, I'm using @Id and @GeneratedValue(strategy = GenerationType....
Score of 0
1 answer
75 views

I am using Spring RestDocs to validate my REST APIs. One API is returning an array of generated values based on some input. I want to verify that the generated values in the response are correct. A ...
Score of 1
1 answer
154 views

Would you believe googling this returned a whopping two results! I'm trying to use Spring REST Docs (spring-restdocs-mockmvc) to generate API documentation for my service. Running on a macbook pro ...
Score of 0
0 answers
41 views

I want to run this project locally: https://github.com/spring-projects/spring-restdocs I cloned the project locally and I run ./gradlew asciidoctor successfully. But now how I can run the project ...
Score of 0
0 answers
565 views

I tried to write a test code using 'rest docs' in Spring Boot with kotlin. I am having an issue with injecting MockMvc to my test class. No qualifying bean of type Shouldn't @AutoConfigureMockMvc, @...
Score of 1
1 answer
1588 views

I was using spring-restdocs with SB2.7.9 Now we migrated to SB3.0.6. I am using gradle plugin (kotlin DSL) id("org.asciidoctor.jvm.convert") version "3.3.2" Libraries are versions: ...
Score of 0
2 answers
290 views

First I ask for your understanding of my poor eng. I'm writing test code for make api specification by Spring Rest Docs library. plugins { id 'java' id 'org.springframework.boot' version '2.7....
Score of 0
1 answer
684 views

How to documentation form list parameter? Controller @PostMapping("/sample") public void post(@ModelAttribute PostRequest request) { // ... } @Data public static class PostRequest { ...
Score of 2
1 answer
486 views

I'm generating documentation for APIs that are written in Python. I am using Spring Rest-Docs for this which works flawless. Now I must add a list of roles that are authorized to call the API to each ...
Score of 1
1 answer
6298 views

I have my api documentation generated by restdocs through unit tests. Although it works fine for most of my needs, I'm still lacking a bit of the nice swagger features, so I was trying to have the ...
Score of 0
1 answer
357 views

I am using MockMVC and Spring REST docs and am trying to generate a curl snippet that has the certificate in it. I imagine the certificate portion of the curl statement should look something like: --...
Score of 1
1 answer
325 views

Iam creating a POST endpoint named /transactions which should accept the below input. What is the best practice to send the input request like the below? Should i use a request body or a input stream ...
Score of 0
1 answer
335 views

I could convert openapi2 to adoc with Swagger2Markup, but it support only openapi2, not 3. https://github.com/Swagger2Markup/swagger2markup/issues and I read some issues on it, and i guess it still ...
Score of 2
2 answers
847 views

I'm trying to automatically document my configuration properties in order to create a html like the one on spring boot appendix for it's configuration. I see that I can enable configuration metadata ...
Score of 0
1 answer
228 views

Can I use Spring RestDocs to document APIs when the authorization mode is bearer? A pointer to a simple example would be appreciated, it doesn't seem the be available on the Spring RestDocs pages. ...
Score of 0
0 answers
372 views

I am using JWT authentication with Spring Security, where authentication requests have to contain the username and password in their body. I do not want the credentials I use in the test to be ...
Score of 0
0 answers
111 views

In my Rest Service i could have request country parameter by two way On in subOject from main User Object and an other way friendly is country code in String Could i in Spring RestsDocs says if ...
Score of 1
1 answer
354 views

I have a hard time trying to document the following: { "virtualFaxPermissions" : { "SOME_RANDOM_UUID" : [ "SOME_SPECIFIC_PERMISSION" ] } } I have tried to put a ...
Score of 0
0 answers
175 views

I want to display static pages using Spring Boot. I tried this configuration: plugins { id "java" id "org.asciidoctor.jvm.convert" version "3.3.2" } repositories ...
Score of 4
1 answer
7290 views

I have a custom Page to return when the user does a query with a Pageable. This Page has a generic parameter and I want to specify it in my Swagger documentation. Here is the current result: Where ...
Score of 0
1 answer
424 views

I am doing documentation for a REST service that returns this kind of JSON: { "CKM_RSA_PKCS_OAEP" : { "keyType" : "RSA", "canGenerateKey" : false, ...
Score of 0
1 answer
1514 views

In a JUnit 5 test, I'm trying to document my Spring Boot application API with the following: (...) this.webTestClient = WebTestClient.bindToApplicationContext(applicationContext) ....
Score of 0
1 answer
703 views

I have noticed that rest doc (HttpRequestSnippet.java) is setting APPLICATION_FORM_URLENCODED_VALUE as content type for PUT with request parameter and without request body. This should be corrected, ...
Score of 1
2 answers
615 views

I have configured a custom snippet directory with RestDocumentationExtension. How can I specify this snippet directory for the spring-restdocs-asciidoctor?
Score of 0
1 answer
226 views

Is it possible to generate snippet for a nested bean shared between different response structures ? Address model class Address { String state; Integer postcode; } Response from endpoint 1 (R1) { ...
Score of 7
1 answer
3213 views

I'm adopting Spring Rest Docs and the test successfully created *.adoc files. I made api-guide.doc file in src/docs/asciidoc directory to create html, but when I run asciidoc as a gradle task, it ...
Score of 0
1 answer
292 views

Writing all fields with the snippets description is not reliable solution is there any way to implement Model/Entity as a table with the fields and description, constraints, Type seprately. ...
Score of 0
1 answer
785 views

I am facing the issue while working with the asciidoc for my spring rest docs implemetation my adoc files as per my test cases is created in build/generated-snippets. I am having issue with creating ...
Score of 0
2 answers
773 views

PROBLEM I use Spring Rest Docs in my project. It is useful at development stage, but i don't want it to be available for ordinary users and search engines in production. RESEARCH I see no robot meta ...
Score of 0
1 answer
175 views

I'm trying to document inner constraint for Collections (NotBlank and Size) like: @Valid private List<@NotBlank @Size(min = 1, max = 100) String> someAnotherUsefulInformationList; Can I do ...
Score of 0
1 answer
1604 views

I am generating documentation using Spring REST docs and I am using the new annotation @AutoConfigureRestDocs instead of explicitly defining in the @BeforeEach method. The below test is currently ...
Score of 3
1 answer
2301 views

I had used SpringRestDoc and want to collapse Table of Contents. Below my index.adoc = Service Rest Docs API Document :doctype: book :icons: font :source-highlighter: highlightjs :toc2: left :theme: ...
Score of 0
1 answer
1262 views

I tried \n or br tag to make a newline, but it doesn't work. requestParameters( parameterWithName("name").description("This is the description <br/> in the table.&...
Score of 0
1 answer
1457 views

I'm having trouble documenting optional response fields with Spring Docs. My test code: mockMvc.perform(get("/foo").accept(MediaType.APPLICATION_JSON)) .andExpect(status().isOk()) ...
Score of 1
2 answers
2533 views

I have a Spring webflux application with the service below. @Configuration public class RouterConfiguration { @Autowired private RegistrationHandler regHandler; @Bean public ...
Score of 0
1 answer
908 views

I am using Spring webflux security for my application and trying to write Spring webflux restdocs. Getting unauthorized error for test cases. Is there anyway to by pass security for rest doc test ...
Score of 0
1 answer
1129 views

Recently switch to Gradle from Maven. Following this tutorial for continuous REST Doc build with Gradle. https://www.youtube.com/watch?v=k5ncCJBarRI&t=1490s Snippets are generating just fine when ...
Score of 0
1 answer
546 views

i have problems with Spring REST Docs and preventing deep-level documentation of fields within a request body: @Transactional @RequestMapping(path = "/edit", method = RequestMethod.POST) ...
Score of 0
0 answers
1371 views

I use spring rest docs to document my api. Now I want to document my document my path in the form of .../accounts/{userId} but I get .../accounts/123 The test part look as follows: mockMvc.perform(...
Score of 2
1 answer
318 views

I'm generating spring-restdocs snippets with rest assured in my integration tests. With maven and the failsafe plugin that defaults to the integration-test and verify phase. Problem is, that ...

1
2 3 4 5 6