mAPI-ng correlates RED metrics with Go runtime, deployment, and downstream signals and, when an endpoint breaks, ranks the likely causes with the evidence behind each, not another graph to read.
One middleware call and one environment variable. No Prometheus or Grafana to operate.
Free tier · no card · absent key = no-op, safe to ship
When an endpoint goes red, the detail page doesn't hand you ten charts to correlate by hand. It ranks the likely cause from signals already collected, and tells you how to prove it wrong.
GET /v1/checkout."mAPI-ng targets the onboarding, interpretation, and operational cost of the OTel + Prometheus + Grafana stack, not its flexibility. It gives you RED metrics and a ranked, evidence-backed diagnosis for every Go endpoint, with nothing to operate. It does not replace full distributed tracing or custom dashboards.
When an endpoint goes red, the detail page ranks 8 cause families from signals it already loads, each with its evidence and a falsifier that says what would rule it out. Confidence is a discrete tier, never a fake percentage, and when nothing explains the anomaly it says Unattributed rather than inventing a cause.
One required input: MAPING_KEY. Service name is inferred from the binary, instance from the hostname, flush timing and sketch params from defaults. An absent key makes the middleware a no-op, so adding mAPI-ng is always safe, and activation is decoupled from the code change.
The client aggregates per-endpoint metrics in-process into a DDSketch before sending. The server stores compact Summaries in ClickHouse and rolls them up through 1-minute, 1-hour and 1-day tiers. More data ingested per second, less disk used, faster queries than raw-event pipelines. The ~77× disk figure assumes ~300 B per raw event.
go get github.com/arhuman/maping/client go get github.com/arhuman/maping/client/gin
Core client has no web-framework deps. The Gin adapter is a separate module, so it never leaks into your binary unless you use it.
import (
maping "github.com/arhuman/maping/client"
mgin "github.com/arhuman/maping/client/gin"
)
rec := maping.NewRecorder(
maping.WithService("my-api"))
r.Use(mgin.MiddlewareWithRecorder(rec))
Mount it above gin.Recovery(). Service and instance are inferred, no further wiring.
export MAPING_KEY=mk_live_…
The only required input. It carries both the secret and the collector endpoint. Absent = no-op.