
Generate a Typed Go Client From an OpenAPI Document
Generate a typed Go client from an OpenAPI file with oapi-codegen, then wrap it: auth by request editor, Go errors from problem documents and a drift check.
Tag
22 articles

Generate a typed Go client from an OpenAPI file with oapi-codegen, then wrap it: auth by request editor, Go errors from problem documents and a drift check.

Build a todo app in Go with templ, HTMX and SQLite where every action works as a plain form post and upgrades to fragment updates, with tests for both paths.

Design bulk endpoints in Go: atomic versus partial modes, per-item results by index, savepoints, idempotent refs, limits, and 100 creates in 1.2 ms not 18.

Build a CRUD API in Go with the standard library: a natural key, PUT upserts, ETag and If-Match locking, and a store contract tested on memory and SQLite.

Build a webhook receiver in Go that checks an HMAC signature on the raw body, rejects stale and replayed events, answers fast and processes in the background.

Generate a Go net/http server from an OpenAPI file with oapi-codegen: config, the interface, validation middleware and what generated code leaves unchecked.

Build a typed Go client for a JSON API: context on every call, one generic request helper, an APIError you can test with errors.Is, and paging as an iterator.

Build an HTTP load balancer in Go with round robin and least connections, active health checks with rise and fall thresholds, and passive failure marking.

Add full-text search to a Go site with SQLite FTS5: stemming, bm25 ranking, highlighted snippets, search as you type and safe handling of raw user queries.

Build a blog engine in Go that embeds Markdown files, parses front matter, hides drafts and scheduled posts and serves index, tag and post pages.