Giter Club home page Giter Club logo

swaggerplusplus's Introduction

swaggerplusplus

A proposal for transitioning between Swagger 2.0 and OpenAPI 3.0.x

Version 1.0.0-rc4

The key words "MUST", "MUST NOT", "REQUIRED", "SHALL", "SHALL NOT", "SHOULD", "SHOULD NOT", "RECOMMENDED", "NOT RECOMMENDED", "MAY", and "OPTIONAL" in this document are to be interpreted as described in BCP 14 RFC2119 RFC8174 when, and only when, they appear in all capitals, as shown here.

To aid the transition between Swagger 2.0 and OpenAPI 3.0.x, it is proposed to back-port the following features from the OpenAPI 3.0.0 specification (currently version 3.0.0) as specification extensions (formerly known as vendor extensions).

Tooling MAY make use of these features now, with minimal work required to support them in OpenAPI 3.0.x, definition authors MAY also use these features, knowing their API definition can be losslessly converted from swaggerplusplus to OpenAPI 3.0.x by any swaggerplusplus-compatible converter.

Features

Path Version 3.0.x Object New Extension Type Description
#/ servers x-servers [Server Objects] When converting to OpenAPI 3.0.x, this array is used in place of any servers array converted from Swagger 2.0 metadata
#/paths/{Path Item} servers x-servers [Server Objects]
#/paths/{Path Item}/{operation} servers x-servers [Server Objects]
#/paths/{Path Item}/{Operation} trace x-trace V2 Operation Object This MUST be a Swagger 2.0 Operation Object, it MUST be treated as per any other Operation Object, for the TRACE HTTP method
#/paths/{Path Item} summary x-summary String Also as per Apiary extension
#/paths/{Path Item} description x-description String Also as per Apiary extension
#/parameters OR #/paths/{Path Item}/parameters OR #/paths/{Path Item}/{Operation}/parameters deprecated x-deprecated Boolean Indicates the parameter is deprecated and SHOULD be transitioned out of use
#/paths/{Path Item}/{Operation} callbacks x-callbacks [Callback Objects]
* within Schema Object anyOf x-anyOf [Schema Object] Schema MUST be extracted and post-processed before being used for validation
* within Schema Object oneOf x-oneOf [Schema Object] Schema MUST be extracted and post-processed before being used for validation
* within Schema Object not x-not Schema Object Schema MUST be extracted and post-processed before being used for validation
* within Schema Object required x-required Array Where a property has been removed from required due to use of x-anyOf, x-oneOf or x-not, converters MUST merge these arrays when converting from swaggerplusplus to OpenAPI 3.0.x. When a converter converts from 3.0.x to swaggerplusplus it MUST remove any required properties hidden by x-anyOf, x-oneOf or x-not and move them into this array.
* within Schema Object nullable x-nullable Boolean Indicates whether the property is nullable or not.
* within Schema Object discriminator x-discriminator Discriminator Object A version 3.0.x discriminator object to replace the version 2.0 discriminator property.
* within Response Object links x-links Map {Link Object} Links or references to reusable Link Objects
#/ components/links x-links Map {Link Object} Contains reusable Link Objects
#/ components/callbacks x-callbacks Map {Callback Object} Contains reusable Callback Objects

Conversion

Converters MUST validate the specification extensions are of the expected type, and that mandatory properties (if any) are present. Failing that, they MUST leave the specification extension unchanged.

swaggerplusplus Tools

swaggerplusplus in the wild

Zappiti API

swaggerplusplus's People

Contributors

mikeralphson avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar

Forkers

isabella232

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.