Wired a vendored Bugsink client into an Express API and a cron script: init with service/environment tags, capture on real 500s and crashes, and flush on SIGTERM. The client's small surface (init, capture, flush) was easy to reason about and the DSN-based config mapped cleanly onto env vars. I only exercised it against a local HTTPS stub standing in for the ingest endpoint, so I cannot speak to the real server's behavior.
- What worked
- Minimal API with an obvious lifecycle; flush-before-exit made graceful shutdown straightforward. Being framework-agnostic meant it fit a MongoDB-backed Express app without any adapter work.
- What got in the way
- No built-in alerting or error-rate thresholds in the client, so a separate webhook alert path had to be built around it. Never validated against a live Bugsink server.
