Weave Code
Weaver
Helps Laravel developers discover, compare, and choose open-source packages. See popularity, security, maintainers, and scores at a glance to make better decisions.
Feedback
Share your thoughts, report bugs, or suggest improvements.
Subject
Message

Laravel Sentry Laravel Package

zing/laravel-sentry

zing/laravel-sentry integrates Sentry error tracking with Laravel, making it easy to capture exceptions, report failures, and monitor application health in production. It provides a simple way to connect your app to Sentry with minimal configuration and keeps error reporting consistent across your s...

View on GitHub
Deep Wiki
Context7

Product Decisions This Supports

  • Observability depth vs. platform defaults: This package is a thin, single-purpose middleware layer that enriches Sentry's per-request context (user identity, request metadata, tags) inside a Laravel app. It is a lever for the question "is our default error-reporting context good enough to debug production incidents, or do we need request-scoped enrichment?" — not a lever for choosing an error-tracking vendor.
  • Build vs. buy vs. configure: The realistic decision is configure vs. write ~50 lines of middleware yourself. Because the package is narrow, MIT, and effectively unmaintained in terms of community signal, the honest framing is "shortcut for a small convenience," not a strategic dependency. Adopt only if it demonstrably saves a sprint of glue code.
  • Roadmap input for incident response / MTTR work: If your roadmap includes reducing mean-time-to-resolution or improving on-call ergonomics, this is a candidate ticket under "improve error context," scoped to hours, not a quarter. It supports a decision to invest in observability hygiene in small increments.
  • Use cases where it fits: Internal tools, admin dashboards, and Laravel services where you already run Sentry, want user/tenant tags attached to every event, and where a middleware-based approach matches your existing request lifecycle rather than a service-provider bootstrapping hook.
  • What it does not support: It does not replace sentry/sentry-laravel (the first-party SDK), does not cover tracing/performance beyond what Sentry natively captures, and should not be used as an argument for standardizing on Sentry across the org. Treat it as a garnish on an existing Sentry integration, never as the integration itself.

When to Consider This Package

Adopt (cautiously) when all of the following hold:

  • You already have sentry/sentry-laravel installed and working; this is additive context, not a replacement.
  • You specifically need middleware-scoped context enrichment — e.g., you want tags set after auth/tenant resolution, per-route, or conditionally by middleware group — rather than global config.
  • Your team is comfortable treating it as vendored/forkable code. With 1 GitHub star, 0 dependents, and a single maintainer, expect to own the code. MIT license makes forking and inlining viable.
  • The middleware ordering semantics match your stack (context set before controllers/handlers run, and surviving exception capture).

Look elsewhere — or just write it yourself — when:

  • You need a guaranteed support SLA, security response, or a maintained release cadence. Zero dependents is a strong signal that no one is stress-testing upgrades against Laravel version bumps.
  • You're on a Laravel version at the bleeding edge; a niche package with no downstream users is unlikely to be validated against new framework releases.
  • sentry/sentry-laravel's built-in SendDefaultPii, user-context integration, or a Scope::configureScope call in a small service provider already covers the need. Test this first — it very likely does.
  • You require performance tracing, session replay, or log aggregation — out of scope by design.
  • You're a regulated or audited environment where a 1-star dependency in the request path needs justification your review board won't accept.

Verdict for the roadmap: evaluate as a code snippet, not a dependency. Budget a spike of a few hours: read the middleware, decide whether to depend on it or copy the pattern into your own App\Http\Middleware\SentryContext. The latter carries near-zero risk and identical benefit.

How to Pitch It (Stakeholders)

To executives: This is a small, free utility that makes production error reports more useful — when something breaks, the report tells us which user, which tenant, which request was affected instead of just a stack trace. That shortens incident diagnosis. It is not a new vendor, contract, or platform commitment; the license is MIT and the integration surface is one middleware in the request pipeline. Cost is engineering hours, not dollars. Because the project has effectively no community adoption, we should treat it as a pattern to borrow rather than a library to depend on — we get the benefit with none of the supply-chain risk.

To engineering: The package is a ~middleware wrapper that pushes request/user context into the active Sentry scope. It sits on top of sentry/sentry-laravel; it does not replace it. Recommendation is a timeboxed spike: (1) confirm the first-party SDK doesn't already give us this via configureScope in a service provider, (2) if it doesn't, evaluate the middleware's ordering and PII handling, (3) default to inlining the ~50 lines into our own middleware rather than adding a 1-star, zero-dependent dependency to the request path. Either outcome is a win — we either get a cheap observability improvement or we confirm we don't need it. Watch the PII angle: attaching user identifiers to Sentry events needs a deliberate decision, not a default.

Weaver

How can I help you explore Laravel packages today?

Conversation history is not saved when not logged in.
Prompt
Add packages to context
No packages found.
shitoudev/permissionmanager
johannesclimacus/laravel-tui
hocvt/seotools
vitalybaev/sypexgeo
amphibee/themosis-ignition
gito-me/fast-excel
frankyso/laravel-ipaymu
geolize-studio/laravel-chile
boomerangui/chat
jinas/dhivatar
store-doc/laravel-storage-driver
plus-it/laravel-translation-manager
diephp/perhaps
diephp/telegraph
osmaviation/spreadsheet
microsoft/fluentui-system-icons
mmccook/php-json-canonicalization-scheme
middlewares/firewall
qubiqx/montapacking
nyoncode/laravel-package-console