Go openapi-generator

Open-source Go projects categorized as openapi-generator

Top 4 Go openapi-generator Projects

openapi-generator
  1. oapi-codegen

    Generate Go client and server boilerplate from OpenAPI 3 specifications

    Project mention: Show HN: BoGO – Generate Go back end services directly from SQL files | news.ycombinator.com | 2025-10-17

    Very cool, reminds me of both [sqlc](https://sqlc.dev) and [oapi-codegen](https://github.com/oapi-codegen/oapi-codegen)

    I'm not a fan of the enterprisey hexagonal-style code this generates, but I can understand where this might be useful for someone who does follow that.

    A question regarding evolution: it's rare that schemas stay constant. I'm not sure if this tool will lend itself well when the time comes to, say, add another table, though I might be misunderstanding here.

  2. Stream

    Stream - Scalable APIs for Chat, Feeds, Moderation, & Video. Stream helps developers build engaging apps that scale to millions with performant and flexible Chat, Feeds, Moderation, and Video APIs and SDKs powered by a global edge network and enterprise-grade infrastructure.

    Stream logo
  3. ogen

    OpenAPI v3 code generator for go

    Project mention: Rails for Everything | news.ycombinator.com | 2025-01-01

    With tools like ogen[1], one can take a single Swagger or OpenAPI doc and generate server code with request/response validation, Prometheus metrics, OpenTelemetry, and more.

    It can also generate clients and webhooks. Authentication is just declaring a SecurityScheme in the OpenAPI documentation then implementing a single function. The rest of the backend is just implementing a single interface. Unlike oapi-codegen, there is no need to tinker with middleware for authentication or logging.

    Pair this with a tool like sqlc[2] and SQLite's `pragma user_version`, and you get type-safe database code and database migrations for free. I will concede that adding SQLite is a manual process, but its just two imports added to main.go.

    Frontend is entirely your choice. Go's standard library provides good enough text templating that I don't miss ERB or Django-style templates. Using embed/fs, one can easily embed a bunch of assets into a single static binary, so deployment can be as simple as `go build` and moving a single binary.

    I actually have a hard time using languages besides Go for developing backends, because the code generation tools eliminate the boilerplate I frequently face in other languages while also avoiding the hundreds of dependencies that Spring Boot or Quarkus need.

    [1] https://ogen.dev/

  4. openapi-generator-go

    An opinionated OpenAPI v3 code generator for Go. Use this to generate API models and router scaffolding.

  5. go-oas3

    Open API v3 server code generator

NOTE: The open source projects on this list are ordered by number of github stars. The number of mentions indicates repo mentiontions in the last 12 Months or since we started tracking (Dec 2020).

Go openapi-generator discussion

Go openapi-generator related posts

  • Show HN: BoGO – Generate Go back end services directly from SQL files

    3 projects | news.ycombinator.com | 17 Oct 2025
  • Openapi-generator-go – Generate go code from an openapi spec

    1 project | news.ycombinator.com | 18 Oct 2021

Index

What are some of the best open-source openapi-generator projects in Go? This list will help you:

# Project Stars
1 oapi-codegen 7,909
2 ogen 1,941
3 openapi-generator-go 111
4 go-oas3 21

Sponsored
Stream - Scalable APIs for Chat, Feeds, Moderation, & Video.
Stream helps developers build engaging apps that scale to millions with performant and flexible Chat, Feeds, Moderation, and Video APIs and SDKs powered by a global edge network and enterprise-grade infrastructure.
getstream.io

Did you know that Go is
the 3rd most popular programming language
based on number of references?