Skip to content

Payload/Request Examples no longer generated #444

Closed
@bfs-natewallman

Description

@bfs-natewallman

When upgrading from 1.2.28 to 1.2.31 I noticed the Example Payloads stopped being generated.

Here is psuedo code of an interface I've defined that documents an endpoint that works perfectly fine in 1.2.28 but fails in 1.2.31:

`@Tag(name = "Examples", description = "Endpoints supporting creating and managing Items")
public interface CreateItemSwaggerDefinition {

@operation(
description = "Creates a item")
@RequestBody(
description = "Details of the Item to be created",
required = true,
content = @content(
schema = @Schema(implementation = ViewModel.class),
mediaType = MediaType.APPLICATION_JSON_VALUE,
examples = {
@ExampleObject(
name = "An example request with the minimum required fields to create.",
value = Examples.MINIMUM,
summary = "Minimal request"),
@ExampleObject(
name = "An example request with all fields provided with example values.",
value = Examples.FULL,
summary = "Full request") }))
ResponseEntity create(ViewModel viewModel);
}
`

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions