-
Notifications
You must be signed in to change notification settings - Fork 12
Open
Description
I was using a demo openapi spec file (Swagger Petstore - OpenAPI 3.1) and I discovered that when obtaining Schema using OpenApi.components.schema, the schema object's property shows example field as null but the content I provide has value as ["doggie"]. Here's the schema for Pet
Pet:
required:
- name
- photoUrls
type: object
properties:
id:
type: integer
format: int64
examples: [10]
name:
type: string
examples: [doggie]
category:
$ref: '#/components/schemas/Category'
photoUrls:
type: array
xml:
wrapped: true
items:
type: string
xml:
name: photoUrl
tags:
type: array
xml:
wrapped: true
items:
$ref: '#/components/schemas/Tag'
status:
type: string
description: pet status in the store
enum:
- available
- pending
- sold
xml:
name: petI used OpenApi.fromString(source: content, format: OpenApiFormat.json); to parse the spec.
Metadata
Metadata
Assignees
Labels
No labels