Weave Code
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

Webpush Bundle Laravel Package

bentools/webpush-bundle

Symfony bundle to send Web Push notifications using the Web Push protocol. Manage user-to-subscription associations (multi-device and shared devices) with your own persistence (Doctrine or custom). Includes VAPID key generation and backend APIs for subscriptions.

View on GitHub
Deep Wiki
Context7

Product Decisions This Supports

  • Feature Expansion: Enables real-time push notifications for Symfony-based applications, enhancing user engagement (e.g., task assignments, order updates, or alerts). Directly supports cross-channel notifications (web, mobile via PWA) without requiring native apps.
  • Roadmap Prioritization: Justifies investment in progressive web apps (PWAs) or web-first notification strategies by reducing reliance on email/SMS for time-sensitive alerts. Aligns with trends like web3 notifications or server-sent events (SSE) alternatives.
  • Build vs. Buy: Avoids reinventing the wheel for Web Push Protocol compliance (VAPID keys, subscription management). Leverages battle-tested libraries (minishlink/web-push) while maintaining flexibility for customization.
  • Use Cases:
    • E-commerce: Order confirmations, shipping updates, abandoned cart reminders.
    • Productivity: Task assignments, deadline alerts (e.g., Trello/Asana-like apps).
    • Social/Community: Real-time activity feeds (e.g., comments, likes).
    • Internal Tools: Admin alerts for critical events (e.g., failed jobs, security breaches).
  • Monetization: Enables subscription-based models (e.g., premium notifications) or advertising via push campaigns.
  • Tech Stack Alignment: Ideal for Symfony monoliths or microservices needing decoupled notification services. Complements existing message queues (RabbitMQ, Kafka) for async processing.

When to Consider This Package

  • Avoid if:

    • Your app doesn’t support PWAs or lacks a web frontend (e.g., pure mobile/native apps). Requires client-side JavaScript (webpush-client).
    • You need native mobile push (APNs for iOS, FCM for Android). This package is web-only.
    • Your team lacks Symfony/PHP expertise or prefers a headless approach (e.g., Node.js/Go backends).
    • You require high-frequency notifications (>100k/month) without optimization (may need queueing like Symfony Messenger).
    • Compliance risks: VAPID keys must be secured (exposure via Twig templates is a trade-off for convenience).
  • Look elsewhere if:

    • You need multi-platform push (use Firebase Cloud Messaging or OneSignal).
    • Your stack is non-PHP (e.g., Ruby, Java, Python). Consider native SDKs or third-party APIs.
    • You prioritize offline-first reliability (this relies on browser service workers).
    • Your use case involves rich media/notifications (e.g., images/videos; may need custom payloads beyond JSON).

How to Pitch It (Stakeholders)

For Executives:

"This package lets us send real-time push notifications to users’ browsers—no app downloads required. Think of it as SMS for the web: instant alerts for orders, tasks, or critical updates, driving engagement and retention. It’s low-cost (MIT license, open-source), scalable (works with our existing Symfony stack), and future-proof (supports PWAs). For example, we could notify customers when their package ships or remind admins of urgent issues—without relying on emails that get ignored. It’s a quick win for user experience with minimal dev overhead."

ROI Hook:

  • "Reduce churn by keeping users informed in real-time (e.g., abandoned cart recovery)."
  • "Cut notification delivery costs vs. third-party services (e.g., OneSignal)."

For Engineering:

*"This is a Symfony-native Web Push implementation that handles the heavy lifting of VAPID key management, subscription storage, and notification dispatching. Here’s why it’s a smart choice:

  • Integrates seamlessly with Doctrine (or your ORM) for subscription persistence.
  • Decouples notification logic from business code via event listeners (e.g., trigger pushes on OrderPlaced).
  • Extensible: Customize UserSubscriptionManager for multi-user types (e.g., Customer vs. Admin).
  • Performance: Uses minishlink/web-push (a PHP port of the Web Push spec) for reliability.
  • Dev Experience: Clear docs, CLI for key generation, and a JavaScript client (webpush-client) for frontend integration.

Trade-offs:

  • Requires frontend JS (no backend-only solution).
  • VAPID keys must be secured (store in env vars, not config).
  • No built-in rate limiting—pair with Symfony Messenger for high volume.

Proposal:

  1. Spike: Test with a non-critical feature (e.g., dev-only alerts).
  2. Scale: Add to core workflows (e.g., order confirmations).
  3. Monitor: Track delivery rates and user engagement lift."*

Tech Deep Dive:

  • Architecture: Frontend → webpush-client → Backend (/webpush endpoint) → PushMessageSender → User devices.
  • Data Flow:
    graph TD
      A[User Subscribes] --> B[Frontend: webpush-client]
      B --> C[Backend: /webpush endpoint]
      C --> D[UserSubscription Entity]
      D --> E[Notification Trigger]
      E --> F[PushMessageSender]
      F --> G[User’s Browser]
    ```"
    
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.
terminal42/code-quality-tools
codifyo/ts-generator-bundle
andydefer/laravel-cluster
testo/fiber
mintobit/jobqueue
a4sex/maintenance-bundle
a4sex/entity-date-update
a4sex/client-identifier
a4sex/base-utilites
a4sex/key-value-storage
a4sex/micro-status
chilldev/dependency-injection-extra
datinglibre/datinglibre-app-api
biberltd/corebundle
bricre/symfony-bundle-test
biberltd/logbundle
dominium/http-adapter-bundle
dominium/google-analytics
a4sex/auto-clean-entity
christhompsontldr/laravel-inky