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 Request Logger Laravel Package

prettus/laravel-request-logger

Laravel middleware that logs every HTTP request and response to the database. Configurable logging per route, sensitive data redaction, custom log profiles, and Eloquent model integration make it a simple way to audit and debug API traffic in Laravel apps.

View on GitHub
Deep Wiki
Context7

Product Decisions This Supports

  • Observability feature investment: Whether to add request/response logging to Laravel services for support, debugging, and incident triage without adopting a full APM platform.
  • Build vs. buy vs. fork: Whether a lightweight open-source middleware is sufficient, or whether engineering should build a small internal middleware around Laravel’s logging stack. Given the package’s age, the safer strategic decision is likely “use as reference or fork,” not “adopt as a long-term dependency.”
  • Support and customer-success tooling: Enabling faster reproduction of customer-reported API issues by capturing request metadata, status codes, timing, and selected payload context.
  • API audit and compliance scoping: Informing requirements for request trails, retention, PII redaction, access controls, and audit-grade logging. This package can demonstrate the pattern but is unlikely to satisfy strict compliance needs without significant hardening.
  • Incident-response roadmap: Prioritizing correlation IDs, structured logs, error context, and retention policies so engineering can trace failures across services.
  • Legacy Laravel maintenance decisions: For older Laravel/PHP applications, deciding whether to add low-cost request visibility now versus schedule a broader observability upgrade.
  • Use cases to validate: internal admin/API debugging, integration troubleshooting, webhook request tracing, customer support escalation, and lightweight usage/error monitoring.

When to Consider This Package

Consider it when:

  • The product runs on a legacy Laravel version compatible with the package’s 2018-era release.
  • The need is simple HTTP request logging—method, URL, status, duration, selected headers/body context—not full distributed tracing.
  • Engineering can vendor, fork, or wrap the middleware and own compatibility, security review, and maintenance.
  • Logs will go into an existing Laravel logging/monitoring pipeline with clear retention and access controls.
  • The team needs a time-boxed proof of concept or reference implementation rather than a strategic platform dependency.
  • Volume is modest, and logging overhead/redaction can be tested before rollout.

Look elsewhere when:

  • The application is on modern Laravel/PHP and needs maintained compatibility.
  • Requirements include PII redaction, compliance-grade audit trails, tamper resistance, or strict retention.
  • The product needs structured logging, correlation IDs, distributed tracing, APM, or alerting.
  • Traffic volume is high and logging performance/backpressure must be actively managed.
  • The organization requires vendor-supported or actively maintained dependencies.
  • The goal is product analytics or business event tracking—this is infrastructure logging, not an analytics tool.

Given 241 GitHub stars and a last release in 2018, treat it as a small, aging utility, not a safe default. Validate compatibility and security before any production commitment.

How to Pitch It (Stakeholders)

Executive summary: This package is a lightweight Laravel middleware for logging HTTP requests. It can improve debugging and support response time by making it easier to answer “what request failed, when, and with what result?” However, it is an old open-source utility—last released in 2018—so it should not become a strategic dependency without engineering ownership.

Engineering pitch: It offers a quick reference implementation for request/response logging in Laravel. If adopted, fork or wrap it, add redaction and correlation IDs, test performance, and pin compatible framework versions. Prefer building a thin internal middleware if the app is modern or if compliance requirements are meaningful.

Business value: Low-cost visibility into API traffic can reduce mean time to resolution, improve customer support, and support incident reviews. Primary risk: unmaintained code and potential exposure of sensitive request data. Recommendation: run a short proof of concept only if the app is on a compatible legacy stack; otherwise use it as a pattern and build a small owned solution.

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.
diephp/sequences
users-au/socialite-provider
twidpay/twid-logger
mrnewport/laravel-plaid
mrnewport/laravel-repo
mrnewport/laravel-docsign
mrnewport/laravel-stow
mrnewport/laravel-flow
mrnewport/laravel-priceable
mrnewport/laravel-nestedterms
fredmeng/laravel-apidoc-generator
itstructure/laravel-multilingual-tools
pdustdar/elasticsearch
markupai/php-sdk
rlacerda83/lumem-microservice-shipment
uni-method/symfony-lib
tacticmedia/scim-server-bundle
neika-ai/symfony-bundle
mattleads/agent-publishing-bundle
glavweb/framework-bundle