I want my OpenAPI spec to display the list of both the objects like below but I'm unable to do so.
[
{
"studentID": 1,
"studentName": "Ram"
},
{
"studentID": 2,
"studentName": "Shyam"
}
]
Swagger Spec in editor.swagger.io:

I want my OpenAPI spec to display the list of both the objects like below but I'm unable to do so.
[
{
"studentID": 1,
"studentName": "Ram"
},
{
"studentID": 2,
"studentName": "Shyam"
}
]
Swagger Spec in editor.swagger.io:

example keyword should be at the same level of items:
200:
description: success response
content:
application/json:
schema:
type: array
items:
properties:
studentID:
type: integer
studentName:
type: string
example:
- { "studentID": 1, "studentName": "Ram" }
- { "studentID": 2, "studentName": "Shyam" }