-
Notifications
You must be signed in to change notification settings - Fork 244
Home
The OpenAPI Compiler (openapic
) is a tool for reading and processing API models described by the OpenAPI Specification. API models can be in JSON or YAML and referenced with local file names or URLs. openapic
reads specified models, checks for errors, and generates a binary Protocol Buffer representation of the API that can be used by other tools and openapic
plugins. These tools and plugins can use models and support code that allow efficient, statically-typed access to OpenAPI models.
openapic
currently supports OpenAPI 2.0 with compiler and protocol buffer code that is automatically generated from the OpenAPI 2.0 schema. Applications and plugins can be built from code generated from OpenAPIv2.proto.
Go code for a sample application can be found in apps/report/main.go.
openapic
uses a Plugin Architecture to support creation of OpenAPI tools in any language that is supported by protoc
, the Protocol Buffer compiler. Sample plugins are in the plugins directory.
-
As the OpenAPI 3.0 schema develops,
openapic
will be extended to support both versions of OpenAPI. -
We are working to provide a way to generate Extension Compiler Plugins that will parse OpenAPI vendor extensions.