go-architecture

Solid

Structure Go 1.22+ services — standard cmd/internal layout, constructor-based dependency injection, HTTP routing (net/http ServeMux vs chi vs echo/gin/fiber), and type-safe database access with sqlc + pgx. Use when laying out a new Go project, choosing a router or DB layer, or wiring dependencies. Do NOT use for goroutines/channels patterns (go-concurrency) or language idioms (go-core-idioms).

API & Backend 22 stars 3 forks Updated yesterday MIT

Install

View on GitHub

Quality Score: 82/100

Stars 20%
45
Recency 20%
100
Frontmatter 20%
70
Documentation 15%
100
Issue Health 10%
50
License 10%
100
Description 5%
100

Skill Content

# Go Architecture Opinionated, 2026-current guidance for structuring Go backend services. Favors the standard library and small, composable libraries over heavy frameworks. **Use when:** - Laying out a new Go module or service (directory structure, `cmd/`, `internal/`) - Choosing an HTTP router (stdlib `net/http` ServeMux, chi, echo/gin/fiber) - Choosing a database layer (sqlc + pgx, GORM) or wiring queries - Wiring dependencies (constructors, DI without a framework) - Reviewing an existing Go service for structural / architectural issues **Do NOT use for:** - Writing tests, benchmarks, fuzzing, coverage — use `go-testing-quality` - SOLID line-limit / interface-placement enforcement — use `fuse-solid:solid-go` - Non-Go backends (Laravel, Next.js, Rust) — use the matching expert - Frontend / UI work — use `fuse-design` or a framework expert --- ## Decision Map | Question | Load | |----------|------| | Where do files/packages go? | [project-layout.md](references/project-layout.md) | | Which HTTP router? How do I route? | [http-routing.md](references/http-routing.md) | | How do I talk to the database? | [database-access.md](references/database-access.md) | | How do I wire dependencies? | [dependency-injection.md](references/dependency-injection.md) | | I need a full working example | [templates/rest-service.md](references/templates/rest-service.md) | --- ## Core Principles (2026) 1. **Standard library first.** Since Go 1.22 the `net/http.ServeMux` supports method mat...

Details

Author
fusengine
Repository
fusengine/agents
Created
6 months ago
Last Updated
yesterday
Language
TypeScript
License
MIT

Integrates with

Similar Skills

Semantically similar based on skill content — not just same category