openapi_spec library

openapi_spec, Library for OpenAPI specification parsing and generation

# activate openapi_spec
dart pub global activate openapi_spec

# see usage
openapi_spec --help

Classes

ApiCallback
Text
ClientGeneratorOptions
Components
Holds a set of reusable objects for different aspects of the OAS. All objects defined within the components object will have no effect on the API unless they are explicitly referenced from properties outside the components object. https://swagger.io/specification/#components-object
Contact
Text
Discriminator
Text
Encoding
Text
Example
Text
ExternalDocs
Allows referencing an external resource for extended documentation. https://swagger.io/specification/#external-documentation-object
Text
Info
Text
License
Text
The Link object represents a possible design-time link for a response
MediaType
Text
OAuthFlow
OAuthFlows
OpenApi
The OpenAPI Specification (OAS) defines a standard,language-agnostic interface to RESTful APIs
OpenId
Open ID protocol configuration
Operation
Describes a single API operation on a Path.
Parameter
Text
PathItem
Describes the operations available on a single Path.
RequestBody
Text
Response
A container for the expected responses of an operation.
Schema
The Schema object allows the definition of input and output data types. These types can be objects, but also primitives and arrays
SchemaGeneratorOptions
Security
A declaration of which security mechanisms can be used for this operation.
SecurityScheme
Text
Server
Text
ServerGeneratorOptions
ServerVariable
Text
Tag
Adds metadata to a single tag that is used by the Operation object. It is not mandatory to have a Tag object per tag defined in the Operation object instances.
Xml
Text

Enums

ApiKeyLocation
GeneratorCase
HttpSecurityScheme
IntegerFormat
The format of the integer value
NumberFormat
The format of the number value
OpenApiFormat
SchemaType
StringFormat
The format of a string

Extensions

ApiCallbackPatterns on ApiCallback
Adds pattern-matching-related methods to ApiCallback.
ComponentsPatterns on Components
Adds pattern-matching-related methods to Components.
ContactPatterns on Contact
Adds pattern-matching-related methods to Contact.
DiscriminatorPatterns on Discriminator
Adds pattern-matching-related methods to Discriminator.
EncodingPatterns on Encoding
Adds pattern-matching-related methods to Encoding.
ExamplePatterns on Example
Adds pattern-matching-related methods to Example.
ExternalDocsPatterns on ExternalDocs
Adds pattern-matching-related methods to ExternalDocs.
HeaderPatterns on Header
Adds pattern-matching-related methods to Header.
InfoPatterns on Info
Adds pattern-matching-related methods to Info.
LicensePatterns on License
Adds pattern-matching-related methods to License.
LinkPatterns on Link
Adds pattern-matching-related methods to Link.
MediaTypePatterns on MediaType
Adds pattern-matching-related methods to MediaType.
OAuthFlowPatterns on OAuthFlow
Adds pattern-matching-related methods to OAuthFlow.
OAuthFlowsPatterns on OAuthFlows
Adds pattern-matching-related methods to OAuthFlows.
OpenApiPatterns on OpenApi
Adds pattern-matching-related methods to OpenApi.
OpenIdPatterns on OpenId
Adds pattern-matching-related methods to OpenId.
OperationPatterns on Operation
Adds pattern-matching-related methods to Operation.
ParameterPatterns on Parameter
Adds pattern-matching-related methods to Parameter.
PathItemPatterns on PathItem
Adds pattern-matching-related methods to PathItem.
RequestBodyPatterns on RequestBody
Adds pattern-matching-related methods to RequestBody.
ResponsePatterns on Response
Adds pattern-matching-related methods to Response.
SchemaPatterns on Schema
Adds pattern-matching-related methods to Schema.
SecurityPatterns on Security
Adds pattern-matching-related methods to Security.
SecuritySchemePatterns on SecurityScheme
Adds pattern-matching-related methods to SecurityScheme.
ServerPatterns on Server
Adds pattern-matching-related methods to Server.
ServerVariablePatterns on ServerVariable
Adds pattern-matching-related methods to ServerVariable.
TagPatterns on Tag
Adds pattern-matching-related methods to Tag.
XmlPatterns on Xml
Adds pattern-matching-related methods to Xml.