Set up
go get github.com/lcbasu/pagerless-go@v0.2.0import (
"context"
"net/http"
pagerless "github.com/lcbasu/pagerless-go"
)
func main() {
pagerless.Init("") // reads PAGERLESS_KEY; without it every call is a no-op
defer pagerless.Close(context.Background())
mux := http.NewServeMux()
mux.HandleFunc("GET /orders/{id}", getOrder)
http.ListenAndServe(":8080", pagerless.Middleware(mux))
}What it catches
- Panics in handlers, reported and re-panicked so your own recovery still runs.
- Status and latency per route, using the Go 1.22+ pattern (
GET /orders/{id}). - A heartbeat, and a deploy marker from your VCS build info.
- Errors you report with
pagerless.Capture(err, pagerless.Route("job sync-orders")).
Scheduled jobs
err := pagerless.Monitor(ctx, "nightly-backup", pagerless.Schedule{Cron: "30 3 * * *"}, backup)Framework adapters
Each is its own module, so the core stays dependency-free: Gin, Echo, Fiber, chi and gorilla/mux, gRPC and Temporal. Structured logs: slog.SetDefault(slog.New(pagerless.SlogHandler(slog.NewJSONHandler(os.Stderr, nil)))) reports Error and above.
Go 1.24 or newer. npx pagerless connect adds all of this to each func main your Dockerfiles run, and wires the adapter for the framework it finds.
Questions
Does it use OpenTelemetry?
No. It is standard library only, with no dependencies. If you already export OpenTelemetry, you can also send that: see OpenTelemetry.
Where is the source?
pkg.go.dev/github.com/lcbasu/pagerless-go, MIT licensed.