Open
Description
Content & configuration
Swagger/OpenAPI definition:
openapi: 3.1.0
info:
title: Test
version: '0.0.1'
paths:
/example:
post:
summary: Example endpoint
operationId: example_endpoint
parameters: []
requestBody:
required: true
content:
multipart/form-data:
schema:
type: object
required:
- required_field
properties:
required_field:
type: string
minLength: 1
optional_field:
type: string
example:
required_field: foo
responses:
"200":
description: OK
Swagger-UI configuration options:
SwaggerUI({
// I am using https://editor-next.swagger.io/
})
Is your feature request related to a problem?
Clicking the "Try it out" button for my example endpoint gives the following initial form state:
Instead of using the example provided.
Describe the solution you'd like
I would like the initial form state to be the following
(required_field="foo" and optional_field omitted) to reflect the example given.
Describe alternatives you've considered
I've played around with different ways of specifying the request body and the example. Nothing seems to produce this result in the swagger UI.