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

Webhook Laravel Package

laravel-notification-channels/webhook

The Webhook notification channel lets you deliver Laravel notifications as HTTP POST requests to any URL. Define payloads with a simple toWebhook() method and send JSON to external services or custom endpoints using Laravel's standard notification API.

View on GitHub
Deep Wiki
Context7

Webhook Notifications driver

Frequently asked questions about Webhook
How do I install laravel-notification-channels/webhook in a Laravel app?
Run composer require laravel-notification-channels/webhook. Laravel package auto-discovery registers the channel, and you can publish optional configuration if your app needs it. Then add WebhookChannel::class to a notification's $via array and define toWebhook() returning a WebhookMessage.
How do I send a Laravel notification as an HTTP POST webhook?
Add WebhookChannel::class to the notification's $via array and implement toWebhook() to return a WebhookMessage with the JSON payload you want. The channel resolves the destination via routeNotificationForWebhook() on the notifiable model. Laravel then sends the payload as an HTTP POST using the standard notification flow.
Does laravel-notification-channels/webhook support Laravel 12?
Yes, version 2.7.0 adds Laravel 12.x compatibility, so the package is tracking current framework majors. Pin the package constraint in Composer and add Dependabot or Renovate so a future Laravel 13 major does not surprise you. Residual risk is future version drift, not current Laravel 12 support.
How do I configure the webhook URL for a notifiable model?
Implement routeNotificationForWebhook() on the notifiable model and return the target URL. You can repeat the method per model or use a trait for reusable routing logic. If endpoints are tenant-managed, validate and resolve those URLs yourself before passing them to the channel.
Does this package retry failed webhook deliveries?
No, it does not provide built-in retry-with-backoff, dead-letter handling, circuit breaking, or idempotency keys. You can compose Laravel queue options such as $tries, $backoff, and retryUntil with Http::retry(), but the reliability design and tests are yours. Treat the package as the transport primitive and budget a separate reliability layer for production webhook delivery.
How do I test Laravel webhook notifications with this channel?
Use Http::fake() to intercept the outgoing POST and assert the URL and JSON payload your notification produces. Notification::fake() is still useful for asserting the notification was dispatched without exercising the channel. Keep dedicated tests for payload shape, routing method, and failure behavior.
Is laravel-notification-channels/webhook safe for user-configurable webhook URLs?
Not by itself. The package will POST to any URL you give it, including private or link-local addresses such as 169.254.169.254, so user-configurable endpoints require your own URL validation and SSRF defenses. Block private and link-local ranges, resolve hosts safely, and restrict schemes before sending.
Does it support HMAC webhook signing and timestamp headers?
Do not assume HMAC signing and timestamp headers are provided; the package's core job is shaping and POSTing the notification payload. Confirm signing support against the current source and documentation before committing to it. If you need signing, plan a signing decorator or wrapping job, and define who owns key rotation.
What are alternatives to laravel-notification-channels/webhook for Laravel webhooks?
For simple static endpoints, a custom notification channel or a small queued job using Laravel's Http client can be enough. If you need retries, signing, delivery logs, replay, and tenant-managed endpoints, evaluate a dedicated webhook delivery package or build that reliability layer around the transport. This package fits best when Laravel notifications are already your event fan-out mechanism and webhooks are one more consumer.
Is laravel-notification-channels/webhook actively maintained and production-ready?
It is a small, MIT-licensed package in the laravel-notification-channels org, with a tiny code surface and effectively one active maintainer, so it is easy to review and fork. Version 2.7.0 adding Laravel 12.x compatibility shows current framework tracking rather than a stalled package. Production readiness depends on the reliability and security layer you add around it; use it as a transport primitive, not a complete customer-facing webhook product.
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.
dbravoan/dbcms-admin-theme-dbcms
dbravoan/dbcms-theme-db-cyber
dbravoan/dbcms-blocks-basic
dbravoan/dbcms-module-content-audit
dbravoan/dbcms-module-ai-assistant
paygate-to/paygate-php
padosoft/askmydocs-connector-base
defstudio/supercharged-carbon
bernskioldmedia/laravel-matomo
bernskioldmedia/laravel-harvest
bernskiold/laravel-data-scrubber
bernskiold/laravel-currency-converter
bernskiold/laravel-campaign-monitor
bernskioldmedia/laravel-autotranslate
siberfx/telegram-bot
roy-sandip/laravel-view-extended
gregsphotography/site-builder-core
roy-sandip/laravel-view
anodyne/blade-fluentui-icons
webx-ui/module-catalog-collections