I am using a DemoClass as my request class in which I have one header. I am using @HeaderParam annotation to do this. Here is my DemoClass -
@Request("Request class")
data class DemoClass(
@HeaderParam("Header required in request")
val xyz: String,
@PathParam("Name")
val name: String
)
On running the app and opening the documentation, I see the header xyz in request body instead of being shown as a header. Even when I make a request, I have to add xyz inside the request body instead of the header.
I checked a closed issue where header name in backticks and "-" was the solution suggested, but it still didn't work for me. Someone also suggested to use @OpenAPIName with @HeaderParam but the issue still persists. Any way to fix this?
I am using a
DemoClass
as my request class in which I have one header. I am using@HeaderParam
annotation to do this. Here is my DemoClass -On running the app and opening the documentation, I see the header
xyz
in request body instead of being shown as a header. Even when I make a request, I have to addxyz
inside the request body instead of the header.I checked a closed issue where header name in backticks and "-" was the solution suggested, but it still didn't work for me. Someone also suggested to use
@OpenAPIName
with@HeaderParam
but the issue still persists. Any way to fix this?