cancel
Showing results for 
Search instead for 
Did you mean: 

Creating a skeleton for documenting response schema

Highlighted
Occasional Visitor

Creating a skeleton for documenting response schema

Hi, I am looking for something that helps me documenting an existing API. It seems that swaggerhub only ever generates a "description: Auto generated using Swagger Inspector" and does not analyse the response.

Does a tool exist that generates a schema skeleton from a response ?
Something that, from a response of:

Pets: [{
  name: 'bobby',
  type: 'dog'
}]

would generate something like:

components:
  schemas:
    xx123:
      properties:
        name:
          type: string
        type:
          type: string
    Pets:
      type: array
      items:
        $ref: "#/components/schemas/xx123"

 

1 REPLY
Moderator

Re: Creating a skeleton for documenting response schema

Hi Francen,

 

There is an open enhancement request in SwaggerHub to create requests and responses from JSON schema definitions in a Swagger\OAS3 spec.  This enhancement sounds similar to what you are asking for.  I will let you know when this enhancement has been implemented.

 

Regards,

Marcus

SmartBear Support


Did my reply answer your question? Give Kudos or Accept it as a Solution to help others.↓↓↓↓↓
Watch a new Video
Top Kudoed Authors