Skip to content
This repository was archived by the owner on Nov 8, 2024. It is now read-only.
This repository was archived by the owner on Nov 8, 2024. It is now read-only.

Generating JSON body for unknown schema formats #175

@kylef

Description

@kylef

Given the following OpenAPI 2 document where we have a JSON response which an unknown format we will not generate a JSON body and a user will be cfaced with the following warning:

warning: (3) Unable to generate application/json example message body out of JSON Schema - line 13

NOTE, the solution for users facing this is to either not use unknown format's, or to provide a full example at the root of your schema to use instead of generating a body from the schema.

swagger: '2.0'
info:
  version: '1.0'
  title: Example
produces:
  - application/json
paths:
  /questions:
    get:
      responses:
        200:
          description: Successful Response
          schema:
            type: string
            format: unknown

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions