What problem does it solve?
It solves the difficulty of diagnosing Go failures when errors lack structured context, consistent codes, low-cardinality messages, and stack traces that are useful for on-call debugging and APM grouping.
Core Features & Use Cases
- Structured context as error attributes: attaches domain, tags, user/tenant context, and arbitrary key-value data using a fluent builder instead of stuffing variable data into message strings.
- Error codes and public vs technical messages: sets machine-readable identifiers for routing/metrics and user-safe messages separate from developer-facing technical details.
- Stack traces and panic recovery: captures call stacks and converts panics to structured errors at goroutine boundaries with
.Recover()/.Recoverf().
- Layered wrapping across boundaries: promotes adding relevant context at handler/service/repository boundaries using
.Wrap()/.Wrapf() for end-to-end traceability.
- APM-friendly low-cardinality output: keeps the message stable while variable identifiers flow through
.With() attributes to preserve aggregation.
Quick Start
Use the golang-samber-oops skill to rewrite your existing Go error creation and wrapping so that variable identifiers (user ID, tenant ID, order ID) are added with With/User/Tenant attributes and the resulting error includes Code, Domain, and a public message where appropriate.