A Go RESTful API boilerplate built on stdlib + SQLite + sqlc with full observability (OpenTelemetry, Tempo, Loki, Grafana).
# Install dependencies
go mod download
# Run DB migrations
make migrate
# Start hot-reload dev server
make devThe API is available at http://localhost:4040/api. Swagger UI at http://localhost:4040/swagger/.
| Layer | Technology |
|---|---|
| HTTP | Echo v5 |
| Database | SQLite (modernc — pure Go, no CGO) |
| SQL codegen | sqlc |
| Validation | go-playground/validator v10 |
| API docs | swaggo/swag (OpenAPI) |
| Tracing | OpenTelemetry (OTLP HTTP) |
| Metrics | Prometheus |
| Logs | slog + Loki |
make dev # hot-reload server (air)
make run # run without hot-reload
make migrate # apply DB migrations
make check # fmt + vet + lint + test (full quality gate)
make sqlc # regenerate sqlc Go code
make swagger # regenerate OpenAPI docs
make build # build binaries
make obs/up # start observability stack (Grafana, Tempo, Loki, Prometheus)
make obs/down # stop observability stackFull architecture, patterns, conventions, and developer guide are in CLAUDE.md, including:
- Directory structure and module layout
- Modular monolith architecture
- Key coding patterns (handler pipeline, error handling, validation, DI)
- HTTP API reference
- How to add a new domain (
/new-domainskill) - Observability stack setup
- SQLite configuration notes