protoc-gen-openapi

command
v3.10.13 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Aug 24, 2023 License: Apache-2.0 Imports: 6 Imported by: ? modules, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

README

protoc-gen-openapi

Generate an OpenAPI 3 spec for the Micro API from your Micro service proto.

Todo

  • Read proto files
  • Output OpenAPI3 JSON spec
    • Info.Title comes from the proto package name
  • Build a map of "Schemas" (one for each "message")
    • Field descriptions from code
    • Possible to use references? Not for v1
  • Add a "Path" for each proto "service" method
    • Summary is proto filename and service.method
    • Description is comments from code
    • app/json RequestBody payload from message "input" schema
    • app/json Response payload from message "output" schema
      • Default error payloads
  • Add a "Server" for each Micro platform API endpoint (dev / prod etc)
  • Auth with API token (according to docs)
  • Parameters
    • Namespace (as a header)
    • Namespace (as a hostname component, but this invites errors)
    • Service name (as first part of the URL path)

References aren't working (request/responses should reference a schema)

Documentation

The Go Gopher

There is no documentation for this package.

Directories

Path Synopsis

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL