A compiler for APIs described by the OpenAPI Specification with plugins for code generation and other API support tasks.
This contains several improvements to protoc-gen-openapi
from @jeffsawatzky , including the ability to use proto annotations to add fragments to generated OpenAPI documents (#324). It also adds some missing OpenAPI compiler code that Jeff uncovered when testing the new fragment overlay feature - maps of strings were not properly exported in ToRawInfo()
methods in both OpenAPI packages (v2 and v3). Thanks, Jeff!
We had a series of problems related to a multi-module configuration and its reversion that all now appear to be fixed in this release. Individual components in the cmd
directory are now (again) part of the main module and can be independently installed with the following:
go install github.com/google/gnostic/cmd/disco@latest
go install github.com/google/gnostic/cmd/parse-linter-output@latest
go install github.com/google/gnostic/cmd/petstore-builder@latest
go install github.com/google/gnostic/cmd/protoc-gen-jsonschema@latest
go install github.com/google/gnostic/cmd/protoc-gen-openapi@latest
go install github.com/google/gnostic/cmd/report@latest
go install github.com/google/gnostic/cmd/report-messages@latest
go install github.com/google/gnostic/cmd/vocabulary-operations@latest
Verified with Go 1.16, 1.17, and 1.18beta1.
This adds a retract statement to go.mod
to exclude v0.6.0
from dependency updates. Thanks @morphar and @shenqidebaozi for quickly catching and fixing problems with the multimodule configuration!
This renames the former apps
directory to cmd
and adds a go.mod
for each cmd
subdirectory. These directories contain demonstrations and various gnostic-related applications, and putting each in a separate module clarifies dependencies and reduces the apparent dependencies of gnostic itself (as listed in the top-level go.mod
). Thanks @shenqidebaozi for making this change and @morphar for advising.
This also includes significant improvements to protoc-gen-openapi
from @morphar and @tonybase and a new protoc-gen-jsonschema
pluigin contributed by @morphar.
This adds a gnostic-based protoc plugin that generates OpenAPI for transcoded gRPC APIs. See AIP-127 for a description of transcoding.
It also includes JSON marshaling improvements and tests from @bvwells.
This update includes API vocabulary analysis features developed during the Summer of 2020 and improvements to error reporting that include line/column numbers for errors and more concise reporting of unmatched schemas. A few corner-case crashes were also fixed.
This fixes a minor error that caused Google Discovery Documents to fail to load after the yaml.v3 update.