I'm looking at OpenAPI generation and I see three main forms:
I really like the look of go-restful when it comes to adding hundreds of api endpoints. You define your service (actual business logic) and you define your routes with request/response structs and you're done. Validation, decoding/encoding, swagger docs, etc... is all taken care of - but you can only use HTTP. https://github.com/emicklei/go-restful-openapi/blob/dec9f41f12/examples/user-resource.go
Next you have go-kit which requires additional definitions for decoding, but also allows you to define different transports (HTTP, gRPC, cli, and even NATS!) still, for rest-only servers seems like overkill to have to write all that boilerplate code for each service method. https://github.com/go-kit/examples/blob/master/stringsvc4/main.go#L153-L205
Last we have goa which is similar to go-restful in which you write your service and design spec (for rest, grpc, etc..) but different in that you use code generation to write all the implementations (only http and grpc supported?) and encoding/decoding logic for request/response types. https://github.com/goadesign/examples/blob/175371c1d3/basic/calc.go
(What is interesting is that goa can actually use gokit: https://github.com/goadesign/plugins/blob/v3/goakit/README.md)
So are there any other choices here? I'd like to stick with sqlc for model generation based on written SQL queries and limit the amount of typing and wrangling I have to do when plugging a service + store interface into an actual webserver/cli/queue/grpc instance so the outside world can interact with it.
todo: add https://github.com/pacedotdev/oto