Skip to content
This repository has been archived by the owner on Jan 16, 2024. It is now read-only.

Asana/swagger-parser

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

See https://github.com/swagger-api/swagger-parser for README info.

This is a fork that looks into a common wrapper on all requests and responses

All I did was put:

// Look into "data" wrapper
if (model instanceof ObjectSchema) {
    ObjectSchema op = (ObjectSchema) model;
    if (op.getProperties() != null && op.getProperties().containsKey("data")) {
        Schema underWrapper = op.getProperties().get("data");
        if (underWrapper != null) {
            mediaType.setSchema(underWrapper);
            model = underWrapper;
        }
    }
}

To both the request and response parsing inside:

swagger-parser-v3/src/main/java/io/swagger/v3/parser/util/InlineModelResolver.java

Packages

No packages published

Languages

  • Java 100.0%