Custom notification channels and delivery testing for packages
Learn how to ship Laravel 13 notification channels from a package, covering resolution by class name, destination routing, queueing, and testing real delivery.
Listen to this pageabout 6 min
When you want a package to add a new way to deliver notifications, design channel selection and destination resolution as separate concerns. This page uses a small channel that records operational events to the log as an example, and explains how classes shipped in a package are resolved and what you need to verify when you update them. If you replace the log with delivery to an external service, the division of responsibilities between the channel and the notification stays the same.This page is based on the Laravel Framework v13.38.0 implementation. For basic notification usage, see Notifications. For setting up a package test environment, see Package testing.
The class name is the delivery method, the route is the destination
The channel class name returned from via() determines which object’s send() method is called. The value retrieved through routeNotificationFor(), on the other hand, is the destination that the channel uses. The two don’t need to share the same name.
Where it’s specified
Example on this page
Role
The notification’s via()
OperationsLogChannel::class
Resolves the channel and delivers
The notifiable’s route
operationsLog → operations
Destination used inside the channel
The notification’s viaQueues()
OperationsLogChannel::class → operations-log
Where the job goes when queued
NotificationSender passes the channel name chosen by via() to ChannelManager::driver(). If ChannelManager can’t find the name among built-in or registered names and the name refers to an existing class, it resolves that class from the container. If you only use the class name, you don’t need Notification::extend() or a package service provider. Just make sure Composer’s autoloader can find the class and the container can resolve its constructor dependencies.
The example Acme\OperationsLog package records event names that contain no sensitive information, together with the name of the operations team being notified. In a Laravel application, Psr\Log\LoggerInterface is bound to the logging service, so you can receive it through the constructor.
<?phpnamespace Acme\OperationsLog;use Illuminate\Notifications\Notification;use InvalidArgumentException;use Psr\Log\LoggerInterface;final class OperationsLogChannel{ public function __construct(private readonly LoggerInterface $logger) { } public function send(object $notifiable, Notification $notification): void { $destination = $notifiable->routeNotificationFor('operationsLog', $notification); if (! is_string($destination) || $destination === '') { throw new InvalidArgumentException('Operations log destination is required.'); } $this->logger->info('Operations notification', [ 'destination' => $destination, 'event' => $notification->toOperationsLog($notifiable), ]); }}
The channel expects to receive either a model that uses the Notifiable trait or an on-demand notifiable created by Notification::route(). For the former, the value comes from routeNotificationForOperationsLog(); for the latter, it’s the value registered with route('operationsLog', ...). This example throws an exception so that a notification without a destination is never treated as delivered. When you replace this with real external delivery, check the destination and the send result as well, and design the channel so that failures are never swallowed and reported as success.
Don’t include access tokens or personal information in the event names or destinations you write to the log. This example sends to the log only to demonstrate channel resolution and testing. It isn’t a delivery implementation for an external service.
Define the notification and destination in the consuming application
The application’s notification returns the channel class and defines only the message passed to the channel. When you use ShouldQueue and Queueable, a regular notify() call goes through the queue.
<?phpnamespace App\Notifications;use Acme\OperationsLog\OperationsLogChannel;use Illuminate\Bus\Queueable;use Illuminate\Contracts\Queue\ShouldQueue;use Illuminate\Notifications\Notification;class HealthCheckPassed extends Notification implements ShouldQueue{ use Queueable; public function via(object $notifiable): array { return [OperationsLogChannel::class]; } public function toOperationsLog(object $notifiable): string { return 'health-check-passed'; } public function viaQueues(): array { return [OperationsLogChannel::class => 'operations-log']; }}
When you specify the destination on the fly, the key passed to Notification::route() is not the channel class name. It’s the key the channel uses when it calls routeNotificationFor('operationsLog', ...).
use App\Notifications\HealthCheckPassed;use Illuminate\Support\Facades\Notification;Notification::route('operationsLog', 'operations') ->notify(new HealthCheckPassed());
To send from an application model, add the following method to a model that uses Notifiable.
use Illuminate\Notifications\Notification;public function routeNotificationForOperationsLog(Notification $notification): string{ return 'operations';}
Calling $user->notify(new HealthCheckPassed()) on this model selects the same channel. Configure a queue connection and start a worker that processes the operations-log queue.
php artisan queue:work --queue=operations-log
The Manager retains one OperationsLogChannel instance per channel, so don’t store the destination or notification content in channel properties. Read them from the arguments of each send() call instead. This keeps long-running queue workers from carrying information over from a previous notification.
Only if you want users to specify a short name in via() instead of the class name, use Notification::extend() in your package’s regular service provider.
<?phpnamespace Acme\OperationsLog;use Illuminate\Support\Facades\Notification;use Illuminate\Support\ServiceProvider;class OperationsLogServiceProvider extends ServiceProvider{ public function boot(): void { Notification::extend( 'acme-operations-log', fn ($app) => $app->make(OperationsLogChannel::class), ); }}
Make sure the provider is loaded before any delivery starts, for example through package discovery. In notifications that use the alias, change via() to ['acme-operations-log'] and change the viaQueues() key to the same name. The operationsLog key used to retrieve the destination is a separate key, so you don’t need to change it. Choose a name that doesn’t collide with built-in channel names.The Manager retains resolved channels by name. Re-registering the alias’s creator within the same process doesn’t replace an instance that has already been created. When you change how the channel is registered, also verify the change in a freshly booted application and worker.
Notification::fake() verifies the intent to send a notification. It can’t confirm that the channel’s send() runs or that the route is retrieved. To test delivery, use the real notification Manager and replace LoggerInterface with a test double.The following example runs from Testbench’s TestCase. With notifyNow(), the channel logic runs without starting a worker, even for a ShouldQueue notification.
<?phpnamespace Acme\OperationsLog\Tests;use Acme\OperationsLog\OperationsLogChannel;use Illuminate\Bus\Queueable;use Illuminate\Contracts\Queue\ShouldQueue;use Illuminate\Notifications\Notification as BaseNotification;use Illuminate\Support\Facades\Notification;use Orchestra\Testbench\TestCase;use Psr\Log\LoggerInterface;class OperationsLogChannelTest extends TestCase{ public function test_channel_writes_the_routed_event(): void { $notification = new class extends BaseNotification implements ShouldQueue { use Queueable; public function via(object $notifiable): array { return [OperationsLogChannel::class]; } public function toOperationsLog(object $notifiable): string { return 'health-check-passed'; } }; $logger = $this->createMock(LoggerInterface::class); $logger->expects($this->once())->method('info')->with( 'Operations notification', ['destination' => 'operations', 'event' => 'health-check-passed'], ); $this->app->instance(LoggerInterface::class, $logger); Notification::route('operationsLog', 'operations')->notifyNow($notification); }}
Also verify that a missing destination throws an exception and, if you provide an alias, that it resolves from a fresh boot. If the channel is used through the queue, also test in a verification application that runs a separate queue worker that jobs arrive on the operations-log queue and are processed.NotificationSender splits a ShouldQueue notification into one job per channel and selects the queue using the viaQueues() key. If the channel’s send() throws an exception, it dispatches NotificationFailed and rethrows the exception; if send() returns normally, it dispatches NotificationSent. Queue retry behavior follows the application’s configuration. Note that if you swallow exceptions inside the channel, failed deliveries are treated as successful.
{"docsConfig":{"theme":"aspen","$schema":"https://mintlify.com/docs.json","name":"Knowledge of Laravel","colors":{"primary":"#16A34A","light":"#07C983","dark":"#15803D"},"logo":{"light":"https://mintcdn.com/invokable/AuZ0xql2mAbUyZ99/logo/light.svg?fit=max\u0026auto=format\u0026n=AuZ0xql2mAbUyZ99\u0026q=85\u0026s=df0b7397202a6aa1c1f321620c5aa146","dark":"https://mintcdn.com/invokable/AuZ0xql2mAbUyZ99/logo/dark.svg?fit=max\u0026auto=format\u0026n=AuZ0xql2mAbUyZ99\u0026q=85\u0026s=a8a0340d86ff8aa90e9adfc98a0362d7","href":"/"},"favicon":"https://mintcdn.com/invokable/AuZ0xql2mAbUyZ99/favicon.svg?fit=max\u0026auto=format\u0026n=AuZ0xql2mAbUyZ99\u0026q=85\u0026s=8f5a03a681c95d31803fc237b5811065","api":{"playground":{"display":"simple"}},"navbar":{},"footer":{"socials":{"github":"https://github.com/invokable"}},"seo":{"metatags":{"canonical":"https://kawax.biz"},"indexing":"all"},"styling":{"eyebrows":"breadcrumbs","latex":true},"contextual":{"options":["copy","view","chatgpt","claude","perplexity","mcp","cursor","vscode"],"display":"header"},"interaction":{"drilldown":false},"metadata":{"timestamp":true},"navigation":{"languages":[{"language":"jp","default":true,"href":"jp/packages/laravel-boost-copilot-cli"},{"language":"en","href":"en/packages/laravel-boost-copilot-cli"},{"language":"de","href":"de/packages/laravel-boost-copilot-cli"},{"language":"es","href":"es/packages/laravel-boost-copilot-cli"},{"language":"fr","href":"fr/packages/laravel-boost-copilot-cli"},{"language":"it","href":"it/packages/laravel-boost-copilot-cli"},{"language":"ko","href":"ko/packages/laravel-boost-copilot-cli"},{"language":"nl","href":"nl/packages/laravel-boost-copilot-cli"},{"language":"zh-Hans","href":"zh-CN/packages/laravel-boost-copilot-cli"},{"language":"zh-Hant","href":"zh-TW/packages/laravel-boost-copilot-cli"}]}},"deployment":{"deploymentMetadataValue":{"subdomain":"invokable","hasAudioNarration":true,"actualSubdomain":"invokable","customDomains":["kawax.biz"],"gitSource":{"type":"github","owner":"kawax","repo":"mintlify-docs","deployBranch":"main","contentDirectory":"","isPrivate":true,"mountPath":"","label":""},"feedback":{"thumbs":true,"agentFeedback":true},"entitlements":{"AI_CHAT":{"status":"ENABLED"},"WEB_MCP":{"status":"ENABLED"},"NARRATION":{"status":"ENABLED"}},"buildId":"6af4f8bb899645a1d83de491","clientVersion":"0.0.4111","searchFilterCounts":[{"language":"en","tag":"My Packages","count":145},{"language":"jp","tag":"マイパッケージ","count":145},{"language":"de","tag":"Meine Pakete","count":100},{"language":"es","tag":"Mis paquetes","count":100},{"language":"fr","tag":"Mes packages","count":100},{"language":"it","tag":"I miei pacchetti","count":100},{"language":"ko","tag":"My 패키지","count":100},{"language":"nl","tag":"Mijn packages","count":100},{"language":"zh-Hans","tag":"我的包","count":100},{"language":"zh-Hant","tag":"我的套件","count":100},{"language":"de","tag":"Fortgeschrittene Themen","count":82},{"language":"en","tag":"Advanced Topics","count":82},{"language":"es","tag":"Temas avanzados","count":82},{"language":"fr","tag":"Sujets avancés","count":82},{"language":"it","tag":"Argomenti avanzati","count":82},{"language":"jp","tag":"応用トピック","count":82},{"language":"ko","tag":"심화 주제","count":82},{"language":"nl","tag":"Geavanceerde onderwerpen","count":82},{"language":"zh-Hans","tag":"进阶主题","count":82},{"language":"zh-Hant","tag":"進階主題","count":82},{"language":"en","tag":"VOICEVOX","count":67},{"language":"jp","tag":"VOICEVOX","count":67},{"language":"de","tag":"Leitfaden","count":61},{"language":"en","tag":"Guide","count":61},{"language":"es","tag":"Guía","count":61},{"language":"fr","tag":"Guide","count":61},{"language":"it","tag":"Guida","count":61},{"language":"jp","tag":"ガイド","count":61},{"language":"ko","tag":"가이드","count":61},{"language":"nl","tag":"Gids","count":61},{"language":"zh-Hans","tag":"指南","count":61},{"language":"zh-Hant","tag":"指南","count":61},{"language":"de","tag":"Blog","count":47},{"language":"en","tag":"Blog","count":47},{"language":"es","tag":"Blog","count":47},{"language":"fr","tag":"Blog","count":47},{"language":"it","tag":"Blog","count":47},{"language":"jp","tag":"ブログ","count":47},{"language":"ko","tag":"블로그","count":47},{"language":"nl","tag":"Blog","count":47},{"language":"zh-Hans","tag":"博客","count":47},{"language":"zh-Hant","tag":"部落格","count":47},{"language":"en","tag":"VOICEVOX Engine API Reference","count":45},{"language":"jp","tag":"VOICEVOXエンジンAPIリファレンス","count":45},{"language":"de","tag":"Paketentwicklung","count":43},{"language":"de","tag":"GitHub Copilot","count":43},{"language":"en","tag":"Package Development","count":43},{"language":"en","tag":"GitHub Copilot","count":43},{"language":"es","tag":"Desarrollo de paquetes","count":43},{"language":"es","tag":"GitHub Copilot","count":43},{"language":"fr","tag":"Développement de packages","count":43},{"language":"fr","tag":"GitHub Copilot","count":43},{"language":"it","tag":"Sviluppo di pacchetti","count":43},{"language":"it","tag":"GitHub Copilot","count":43},{"language":"jp","tag":"パッケージ開発","count":43},{"language":"jp","tag":"GitHub Copilot","count":43},{"language":"ko","tag":"패키지 개발","count":43},{"language":"ko","tag":"GitHub Copilot","count":43},{"language":"nl","tag":"Package-ontwikkeling","count":43},{"language":"nl","tag":"GitHub Copilot","count":43},{"language":"zh-Hans","tag":"包开发","count":43},{"language":"zh-Hans","tag":"GitHub Copilot","count":43},{"language":"zh-Hant","tag":"套件開發","count":43},{"language":"zh-Hant","tag":"GitHub Copilot","count":43},{"language":"de","tag":"GitHub Copilot SDK for Laravel","count":41},{"language":"en","tag":"GitHub Copilot SDK for Laravel","count":41},{"language":"es","tag":"GitHub Copilot SDK for Laravel","count":41},{"language":"fr","tag":"GitHub Copilot SDK for Laravel","count":41},{"language":"it","tag":"GitHub Copilot SDK for Laravel","count":41},{"language":"jp","tag":"GitHub Copilot SDK for Laravel","count":41},{"language":"ko","tag":"GitHub Copilot SDK for Laravel","count":41},{"language":"nl","tag":"GitHub Copilot SDK for Laravel","count":41},{"language":"zh-Hans","tag":"GitHub Copilot SDK for Laravel","count":41},{"language":"zh-Hant","tag":"GitHub Copilot SDK for Laravel","count":41},{"language":"de","tag":"Tutorial","count":35},{"language":"en","tag":"Tutorial","count":35},{"language":"es","tag":"Tutorial","count":35},{"language":"fr","tag":"Tutoriel","count":35},{"language":"it","tag":"Tutorial","count":35},{"language":"jp","tag":"チュートリアル","count":35},{"language":"ko","tag":"튜토리얼","count":35},{"language":"nl","tag":"Tutorial","count":35},{"language":"zh-Hans","tag":"教程","count":35},{"language":"zh-Hant","tag":"教學","count":35},{"language":"de","tag":"SDK","count":27},{"language":"es","tag":"SDK","count":27},{"language":"fr","tag":"SDK","count":27},{"language":"it","tag":"SDK","count":27},{"language":"ko","tag":"SDK","count":27},{"language":"nl","tag":"SDK","count":27},{"language":"zh-Hans","tag":"SDK","count":27},{"language":"zh-Hant","tag":"SDK","count":27},{"language":"de","tag":"VOICEVOX","count":22},{"language":"es","tag":"VOICEVOX","count":22},{"language":"fr","tag":"VOICEVOX","count":22},{"language":"it","tag":"VOICEVOX","count":22},{"language":"ko","tag":"VOICEVOX","count":22},{"language":"nl","tag":"VOICEVOX","count":22},{"language":"zh-Hans","tag":"VOICEVOX","count":22},{"language":"zh-Hant","tag":"VOICEVOX","count":22}],"searchSettings":{"isFiltersEnabled":false,"showContentSnippets":true,"fullPageSearch":true}},"assistantConfig":{"enableAskAiButton":false,"enableStarterQuestions":false,"enableContextualStarterQuestions":false,"enableAskAiSearchBar":true},"basePath":"","hasChatPermissions":true,"hasWebMcpPermissions":true,"toggles":[{"name":"kill-isr","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"custom-rbac-roles","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"agent-mintlify-slack","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"agent-integrations-settings","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"rbac-expansion","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"automations-pr-grouping","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"custom-prefix","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"analytics-v7","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"user-flows-analytics","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"no-publish-flow","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workos-onboarding","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"llms-txt-v2","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"snapshot-serving-live","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"stripTemperatureMiddleware","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"support-platform-pylon-zendesk","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"snapshot-serving","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"instant-rollback","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"granular-notifications-server","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"granular-notifications","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"automations-fable","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"fixed-ai-action-pricing","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"automation-resolve-merge-conflict","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"scoped-publishing","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"mintql","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"page-level-analytics","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"editor-version-history-v2","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"billing-page-v2","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"full-page-search","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workspace-projects","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"assistant-v5","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"fork-pr-previews","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"revalidation-jwt","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workos-sso-scim","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"hobby-abuse-scan","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"dashboard-inbox","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workos-signup","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"turbopuffer-dual-write","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workos-enabled","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"approve-review-flow","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"editor-metadata","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"sso-setup-deadline-banner","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"turbopuffer-serve","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"live-agents","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false}],"privacy":{"consentBanner":{"enabled":true}},"googleFontsInlined":false},"customCss":[],"page":{"pagePath":"en/advanced/package-notification-channels","slug":"/en/advanced/package-notification-channels","pageMetadata":{"title":"Custom notification channels and delivery testing for packages","description":"Learn how to ship Laravel 13 notification channels from a package, covering resolution by class name, destination routing, queueing, and testing real delivery.","href":"/en/advanced/package-notification-channels"},"description":{"compiledSource":"\"use strict\";\nconst {jsx: _jsx} = arguments[0];\nconst {useMDXComponents: _provideComponents} = arguments[0];\nfunction _createMdxContent(props) {\n const _components = {\n p: \"p\",\n ..._provideComponents(),\n ...props.components\n };\n return _jsx(_components.p, {\n children: \"Learn how to ship Laravel 13 notification channels from a package, covering resolution by class name, destination routing, queueing, and testing real delivery.\"\n });\n}\nfunction MDXContent(props = {}) {\n const {wrapper: MDXLayout} = {\n ..._provideComponents(),\n ...props.components\n };\n return MDXLayout ? _jsx(MDXLayout, {\n ...props,\n children: _jsx(_createMdxContent, {\n ...props\n })\n }) : _createMdxContent(props);\n}\nreturn {\n default: MDXContent\n};\n","frontmatter":{},"scope":{}},"pageType":"default","mdx":{"mdxSource":{"compiledSource":"\"use strict\";const{Fragment:_Fragment,jsx:_jsx,jsxs:_jsxs}=arguments[0];const{useMDXComponents:_provideComponents}=arguments[0];function _createMdxContent(props){const _components={a:`a`,code:`code`,li:`li`,p:`p`,pre:`pre`,span:`span`,strong:`strong`,tbody:`tbody`,td:`td`,th:`th`,thead:`thead`,tr:`tr`,ul:`ul`,..._provideComponents(),...props.components},{CodeBlock,Heading,Mermaid,Table,Warning}=_components;if(!CodeBlock)_missingMdxReference(`CodeBlock`,true);if(!Heading)_missingMdxReference(`Heading`,true);if(!Mermaid)_missingMdxReference(`Mermaid`,true);if(!Table)_missingMdxReference(`Table`,true);if(!Warning)_missingMdxReference(`Warning`,true);return _jsxs(_Fragment,{children:[_jsxs(_components.p,{children:[`When you want a package to add a new way to deliver notifications, design `,_jsx(_components.strong,{children:`channel selection`}),` and `,_jsx(_components.strong,{children:`destination resolution`}),` as separate concerns. This page uses a small channel that records operational events to the log as an example, and explains how classes shipped in a package are resolved and what you need to verify when you update them. If you replace the log with delivery to an external service, the division of responsibilities between the channel and the notification stays the same.`]}),`\n`,_jsxs(_components.p,{children:[`This page is based on the Laravel Framework `,_jsx(_components.code,{children:`v13.38.0`}),` implementation. For basic notification usage, see `,_jsx(_components.a,{href:`/en/notifications`,children:`Notifications`}),`. For setting up a package test environment, see `,_jsx(_components.a,{href:`/en/advanced/package-testing`,children:`Package testing`}),`.`]}),`\n`,_jsx(Heading,{level:`2`,id:`the-class-name-is-the-delivery-method-the-route-is-the-destination`,children:`The class name is the delivery method, the route is the destination`}),`\n`,_jsxs(_components.p,{children:[`The channel class name returned from `,_jsx(_components.code,{children:`via()`}),` determines which object’s `,_jsx(_components.code,{children:`send()`}),` method is called. The value retrieved through `,_jsx(_components.code,{children:`routeNotificationFor()`}),`, on the other hand, is the destination that the channel uses. The two don’t need to share the same name.`]}),`\n`,_jsxs(Table,{children:[_jsx(_components.thead,{children:_jsxs(_components.tr,{children:[_jsx(_components.th,{children:`Where it’s specified`}),_jsx(_components.th,{children:`Example on this page`}),_jsx(_components.th,{children:`Role`})]})}),_jsxs(_components.tbody,{children:[_jsxs(_components.tr,{children:[_jsxs(_components.td,{children:[`The notification’s `,_jsx(_components.code,{children:`via()`})]}),_jsx(_components.td,{children:_jsx(_components.code,{children:`OperationsLogChannel::class`})}),_jsx(_components.td,{children:`Resolves the channel and delivers`})]}),_jsxs(_components.tr,{children:[_jsx(_components.td,{children:`The notifiable’s route`}),_jsxs(_components.td,{children:[_jsx(_components.code,{children:`operationsLog`}),` → `,_jsx(_components.code,{children:`operations`})]}),_jsx(_components.td,{children:`Destination used inside the channel`})]}),_jsxs(_components.tr,{children:[_jsxs(_components.td,{children:[`The notification’s `,_jsx(_components.code,{children:`viaQueues()`})]}),_jsxs(_components.td,{children:[_jsx(_components.code,{children:`OperationsLogChannel::class`}),` → `,_jsx(_components.code,{children:`operations-log`})]}),_jsx(_components.td,{children:`Where the job goes when queued`})]})]})]}),`\n`,_jsxs(_components.p,{children:[_jsx(_components.code,{children:`NotificationSender`}),` passes the channel name chosen by `,_jsx(_components.code,{children:`via()`}),` to `,_jsx(_components.code,{children:`ChannelManager::driver()`}),`. If `,_jsx(_components.code,{children:`ChannelManager`}),` can’t find the name among built-in or registered names and the name refers to an existing class, it resolves that class from the container. `,_jsxs(_components.strong,{children:[`If you only use the class name, you don’t need `,_jsx(_components.code,{children:`Notification::extend()`}),` or a package service provider.`]}),` Just make sure Composer’s autoloader can find the class and the container can resolve its constructor dependencies.`]}),`\n`,_jsx(Mermaid,{chart:`flowchart LR\n A[\"Select class name in via()\"] --> B[\"ChannelManager::driver()\"]\n B --> C{\"Already resolved?\"}\n C -->|Yes| D[\"Retained channel\"]\n C -->|No| E[\"Create via container\"]\n E --> D\n D --> F[\"send() gets destination and delivers\"]`}),`\n`,_jsx(Heading,{level:`2`,id:`ship-the-channel-itself-in-your-package`,children:`Ship the channel itself in your package`}),`\n`,_jsxs(_components.p,{children:[`The example `,_jsx(_components.code,{children:`Acme\\\\OperationsLog`}),` package records event names that contain no sensitive information, together with the name of the operations team being notified. In a Laravel application, `,_jsx(_components.code,{children:`Psr\\\\Log\\\\LoggerInterface`}),` is bound to the logging service, so you can receive it through the constructor.`]}),`\n`,_jsx(CodeBlock,{filename:``,numberOfLines:`28`,language:`php`,children:_jsx(_components.pre,{className:`shiki shiki-themes github-light-default dark-plus`,style:{backgroundColor:`#ffffff`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#1f2328`,\"--shiki-dark\":`#D4D4D4`},language:`php`,children:_jsxs(_components.code,{language:`php`,numberOfLines:`28`,children:[_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:`\u003c?`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#D4D4D4`},children:`php`})]}),`\n`,_jsx(_components.span,{className:`line`}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:`namespace`}),_jsx(_components.span,{style:{color:`#953800`,\"--shiki-dark\":`#4EC9B0`},children:` Acme\\\\OperationsLog`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`;`})]}),`\n`,_jsx(_components.span,{className:`line`}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:`use`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#D4D4D4`},children:` Illuminate\\\\Notifications\\\\`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#4EC9B0`},children:`Notification`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`;`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:`use`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#4EC9B0`},children:` InvalidArgumentException`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`;`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:`use`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#D4D4D4`},children:` Psr\\\\Log\\\\`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#4EC9B0`},children:`LoggerInterface`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`;`})]}),`\n`,_jsx(_components.span,{className:`line`}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:`final`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:` class`}),_jsx(_components.span,{style:{color:`#953800`,\"--shiki-dark\":`#4EC9B0`},children:` OperationsLogChannel`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`{`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:` public`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:` function`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#DCDCAA`},children:` __construct`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`(`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:`private`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:` readonly`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#4EC9B0`},children:` LoggerInterface`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:` $logger`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`)`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` {`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` }`})}),`\n`,_jsx(_components.span,{className:`line`}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:` public`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:` function`}),_jsx(_components.span,{style:{color:`#8250DF`,\"--shiki-dark\":`#DCDCAA`},children:` send`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`(`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:`object`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:` $notifiable`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`, `}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#4EC9B0`},children:`Notification`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:` $notification`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`)`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:`:`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:` void`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` {`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:` $destination`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:` =`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:` $notifiable`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:`->`}),_jsx(_components.span,{style:{color:`#8250DF`,\"--shiki-dark\":`#DCDCAA`},children:`routeNotificationFor`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`(`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`'operationsLog'`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`, `}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`$notification`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`);`})]}),`\n`,_jsx(_components.span,{className:`line`}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#C586C0`},children:` if`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` (`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:`!`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#DCDCAA`},children:` is_string`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`(`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`$destination`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`) `}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:`||`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:` $destination`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:` ===`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` ''`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`) {`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#C586C0`},children:` throw`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:` new`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#4EC9B0`},children:` InvalidArgumentException`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`(`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`'Operations log destination is required.'`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`);`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` }`})}),`\n`,_jsx(_components.span,{className:`line`}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#569CD6`},children:` $this`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:`->`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`logger`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:`->`}),_jsx(_components.span,{style:{color:`#8250DF`,\"--shiki-dark\":`#DCDCAA`},children:`info`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`(`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`'Operations notification'`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`, [`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` 'destination'`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:` =>`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:` $destination`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` 'event'`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:` =>`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:` $notification`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:`->`}),_jsx(_components.span,{style:{color:`#8250DF`,\"--shiki-dark\":`#DCDCAA`},children:`toOperationsLog`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`(`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`$notifiable`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`),`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` ]);`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` }`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`}`})}),`\n`]})})}),`\n`,_jsxs(_components.p,{children:[`The channel expects to receive either a model that uses the `,_jsx(_components.code,{children:`Notifiable`}),` trait or an on-demand notifiable created by `,_jsx(_components.code,{children:`Notification::route()`}),`. For the former, the value comes from `,_jsx(_components.code,{children:`routeNotificationForOperationsLog()`}),`; for the latter, it’s the value registered with `,_jsx(_components.code,{children:`route('operationsLog', ...)`}),`. This example throws an exception so that a notification without a destination is never treated as delivered. When you replace this with real external delivery, check the destination and the send result as well, and design the channel so that failures are never swallowed and reported as success.`]}),`\n`,_jsx(Warning,{children:_jsx(_components.p,{children:`Don’t include access tokens or personal information in the event names or destinations you write to the log. This example sends to the log only to demonstrate channel resolution and testing. It isn’t a delivery implementation for an external service.`})}),`\n`,_jsx(Heading,{level:`2`,id:`define-the-notification-and-destination-in-the-consuming-application`,children:`Define the notification and destination in the consuming application`}),`\n`,_jsxs(_components.p,{children:[`The application’s notification returns the channel class and defines only the message passed to the channel. When you use `,_jsx(_components.code,{children:`ShouldQueue`}),` and `,_jsx(_components.code,{children:`Queueable`}),`, a regular `,_jsx(_components.code,{children:`notify()`}),` call goes through the queue.`]}),`\n`,_jsx(CodeBlock,{filename:``,numberOfLines:`28`,language:`php`,children:_jsx(_components.pre,{className:`shiki shiki-themes github-light-default dark-plus`,style:{backgroundColor:`#ffffff`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#1f2328`,\"--shiki-dark\":`#D4D4D4`},language:`php`,children:_jsxs(_components.code,{language:`php`,numberOfLines:`28`,children:[_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:`\u003c?`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#D4D4D4`},children:`php`})]}),`\n`,_jsx(_components.span,{className:`line`}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:`namespace`}),_jsx(_components.span,{style:{color:`#953800`,\"--shiki-dark\":`#4EC9B0`},children:` App\\\\Notifications`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`;`})]}),`\n`,_jsx(_components.span,{className:`line`}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:`use`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#D4D4D4`},children:` Acme\\\\OperationsLog\\\\`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#4EC9B0`},children:`OperationsLogChannel`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`;`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:`use`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#D4D4D4`},children:` Illuminate\\\\Bus\\\\`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#4EC9B0`},children:`Queueable`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`;`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:`use`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#D4D4D4`},children:` Illuminate\\\\Contracts\\\\Queue\\\\`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#4EC9B0`},children:`ShouldQueue`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`;`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:`use`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#D4D4D4`},children:` Illuminate\\\\Notifications\\\\`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#4EC9B0`},children:`Notification`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`;`})]}),`\n`,_jsx(_components.span,{className:`line`}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:`class`}),_jsx(_components.span,{style:{color:`#953800`,\"--shiki-dark\":`#4EC9B0`},children:` HealthCheckPassed`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:` extends`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#4EC9B0`},children:` Notification`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:` implements`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#4EC9B0`},children:` ShouldQueue`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`{`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:` use`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#4EC9B0`},children:` Queueable`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`;`})]}),`\n`,_jsx(_components.span,{className:`line`}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:` public`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:` function`}),_jsx(_components.span,{style:{color:`#8250DF`,\"--shiki-dark\":`#DCDCAA`},children:` via`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`(`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:`object`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:` $notifiable`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`)`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:`:`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:` array`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` {`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#C586C0`},children:` return`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` [`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#4EC9B0`},children:`OperationsLogChannel`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:`::`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:`class`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`];`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` }`})}),`\n`,_jsx(_components.span,{className:`line`}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:` public`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:` function`}),_jsx(_components.span,{style:{color:`#8250DF`,\"--shiki-dark\":`#DCDCAA`},children:` toOperationsLog`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`(`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:`object`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:` $notifiable`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`)`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:`:`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:` string`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` {`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#C586C0`},children:` return`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` 'health-check-passed'`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`;`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` }`})}),`\n`,_jsx(_components.span,{className:`line`}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:` public`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:` function`}),_jsx(_components.span,{style:{color:`#8250DF`,\"--shiki-dark\":`#DCDCAA`},children:` viaQueues`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`()`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:`:`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:` array`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` {`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#C586C0`},children:` return`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` [`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#4EC9B0`},children:`OperationsLogChannel`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:`::`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:`class`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:` =>`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` 'operations-log'`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`];`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` }`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`}`})}),`\n`]})})}),`\n`,_jsxs(_components.p,{children:[`When you specify the destination on the fly, the key passed to `,_jsx(_components.code,{children:`Notification::route()`}),` is `,_jsx(_components.strong,{children:`not the channel class name`}),`. It’s the key the channel uses when it calls `,_jsx(_components.code,{children:`routeNotificationFor('operationsLog', ...)`}),`.`]}),`\n`,_jsx(CodeBlock,{filename:``,numberOfLines:`5`,language:`php`,children:_jsx(_components.pre,{className:`shiki shiki-themes github-light-default dark-plus`,style:{backgroundColor:`#ffffff`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#1f2328`,\"--shiki-dark\":`#D4D4D4`},language:`php`,children:_jsxs(_components.code,{language:`php`,numberOfLines:`5`,children:[_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:`use`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#D4D4D4`},children:` App\\\\Notifications\\\\`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#4EC9B0`},children:`HealthCheckPassed`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`;`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:`use`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#D4D4D4`},children:` Illuminate\\\\Support\\\\Facades\\\\`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#4EC9B0`},children:`Notification`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`;`})]}),`\n`,_jsx(_components.span,{className:`line`}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#4EC9B0`},children:`Notification`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:`::`}),_jsx(_components.span,{style:{color:`#8250DF`,\"--shiki-dark\":`#DCDCAA`},children:`route`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`(`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`'operationsLog'`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`, `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`'operations'`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`)`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:` ->`}),_jsx(_components.span,{style:{color:`#8250DF`,\"--shiki-dark\":`#DCDCAA`},children:`notify`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`(`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:`new`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#4EC9B0`},children:` HealthCheckPassed`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`());`})]}),`\n`]})})}),`\n`,_jsxs(_components.p,{children:[`To send from an application model, add the following method to a model that uses `,_jsx(_components.code,{children:`Notifiable`}),`.`]}),`\n`,_jsx(CodeBlock,{filename:``,numberOfLines:`6`,language:`php`,children:_jsx(_components.pre,{className:`shiki shiki-themes github-light-default dark-plus`,style:{backgroundColor:`#ffffff`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#1f2328`,\"--shiki-dark\":`#D4D4D4`},language:`php`,children:_jsxs(_components.code,{language:`php`,numberOfLines:`6`,children:[_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:`use`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#D4D4D4`},children:` Illuminate\\\\Notifications\\\\`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#4EC9B0`},children:`Notification`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`;`})]}),`\n`,_jsx(_components.span,{className:`line`}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:`public`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:` function`}),_jsx(_components.span,{style:{color:`#8250DF`,\"--shiki-dark\":`#DCDCAA`},children:` routeNotificationForOperationsLog`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`(`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#4EC9B0`},children:`Notification`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:` $notification`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`)`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:`:`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:` string`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`{`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#C586C0`},children:` return`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` 'operations'`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`;`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`}`})}),`\n`]})})}),`\n`,_jsxs(_components.p,{children:[`Calling `,_jsx(_components.code,{children:`$user->notify(new HealthCheckPassed())`}),` on this model selects the same channel. Configure a queue connection and start a worker that processes the `,_jsx(_components.code,{children:`operations-log`}),` queue.`]}),`\n`,_jsx(CodeBlock,{filename:``,numberOfLines:`1`,language:`shellscript`,children:_jsx(_components.pre,{className:`shiki shiki-themes github-light-default dark-plus`,style:{backgroundColor:`#ffffff`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#1f2328`,\"--shiki-dark\":`#D4D4D4`},language:`shellscript`,children:_jsxs(_components.code,{language:`shellscript`,numberOfLines:`1`,children:[_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#953800`,\"--shiki-dark\":`#DCDCAA`},children:`php`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` artisan`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` queue:work`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#569CD6`},children:` --queue=operations-log`})]}),`\n`]})})}),`\n`,_jsxs(_components.p,{children:[`The Manager retains one `,_jsx(_components.code,{children:`OperationsLogChannel`}),` instance per channel, so `,_jsx(_components.strong,{children:`don’t store the destination or notification content in channel properties`}),`. Read them from the arguments of each `,_jsx(_components.code,{children:`send()`}),` call instead. This keeps long-running queue workers from carrying information over from a previous notification.`]}),`\n`,_jsx(Heading,{level:`2`,id:`when-you-need-a-short-alias`,children:`When you need a short alias`}),`\n`,_jsxs(_components.p,{children:[`Only if you want users to specify a short name in `,_jsx(_components.code,{children:`via()`}),` instead of the class name, use `,_jsx(_components.code,{children:`Notification::extend()`}),` in your package’s regular service provider.`]}),`\n`,_jsx(CodeBlock,{filename:``,numberOfLines:`17`,language:`php`,children:_jsx(_components.pre,{className:`shiki shiki-themes github-light-default dark-plus`,style:{backgroundColor:`#ffffff`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#1f2328`,\"--shiki-dark\":`#D4D4D4`},language:`php`,children:_jsxs(_components.code,{language:`php`,numberOfLines:`17`,children:[_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:`\u003c?`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#D4D4D4`},children:`php`})]}),`\n`,_jsx(_components.span,{className:`line`}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:`namespace`}),_jsx(_components.span,{style:{color:`#953800`,\"--shiki-dark\":`#4EC9B0`},children:` Acme\\\\OperationsLog`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`;`})]}),`\n`,_jsx(_components.span,{className:`line`}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:`use`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#D4D4D4`},children:` Illuminate\\\\Support\\\\Facades\\\\`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#4EC9B0`},children:`Notification`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`;`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:`use`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#D4D4D4`},children:` Illuminate\\\\Support\\\\`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#4EC9B0`},children:`ServiceProvider`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`;`})]}),`\n`,_jsx(_components.span,{className:`line`}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:`class`}),_jsx(_components.span,{style:{color:`#953800`,\"--shiki-dark\":`#4EC9B0`},children:` OperationsLogServiceProvider`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:` extends`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#4EC9B0`},children:` ServiceProvider`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`{`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:` public`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:` function`}),_jsx(_components.span,{style:{color:`#8250DF`,\"--shiki-dark\":`#DCDCAA`},children:` boot`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`()`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:`:`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:` void`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` {`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#4EC9B0`},children:` Notification`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:`::`}),_jsx(_components.span,{style:{color:`#8250DF`,\"--shiki-dark\":`#DCDCAA`},children:`extend`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`(`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` 'acme-operations-log'`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:` fn`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` (`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`$app`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`) => `}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`$app`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:`->`}),_jsx(_components.span,{style:{color:`#8250DF`,\"--shiki-dark\":`#DCDCAA`},children:`make`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`(`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#4EC9B0`},children:`OperationsLogChannel`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:`::`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:`class`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`),`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` );`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` }`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`}`})}),`\n`]})})}),`\n`,_jsxs(_components.p,{children:[`Make sure the provider is loaded before any delivery starts, for example through `,_jsx(_components.a,{href:`/en/advanced/package-discovery`,children:`package discovery`}),`. In notifications that use the alias, change `,_jsx(_components.code,{children:`via()`}),` to `,_jsx(_components.code,{children:`['acme-operations-log']`}),` and change the `,_jsx(_components.code,{children:`viaQueues()`}),` key to the same name. `,_jsxs(_components.strong,{children:[`The `,_jsx(_components.code,{children:`operationsLog`}),` key used to retrieve the destination is a separate key`]}),`, so you don’t need to change it. Choose a name that doesn’t collide with built-in channel names.`]}),`\n`,_jsx(_components.p,{children:`The Manager retains resolved channels by name. Re-registering the alias’s creator within the same process doesn’t replace an instance that has already been created. When you change how the channel is registered, also verify the change in a freshly booted application and worker.`}),`\n`,_jsx(Heading,{level:`2`,id:`test-delivery-separately-from-fake`,children:`Test delivery separately from fake`}),`\n`,_jsxs(_components.p,{children:[_jsx(_components.code,{children:`Notification::fake()`}),` verifies the `,_jsx(_components.strong,{children:`intent`}),` to send a notification. It can’t confirm that the channel’s `,_jsx(_components.code,{children:`send()`}),` runs or that the route is retrieved. To test delivery, use the real notification Manager and replace `,_jsx(_components.code,{children:`LoggerInterface`}),` with a test double.`]}),`\n`,_jsxs(_components.p,{children:[`The following example runs from `,_jsxs(_components.a,{href:`/en/advanced/package-testing`,children:[`Testbench’s `,_jsx(_components.code,{children:`TestCase`})]}),`. With `,_jsx(_components.code,{children:`notifyNow()`}),`, the channel logic runs without starting a worker, even for a `,_jsx(_components.code,{children:`ShouldQueue`}),` notification.`]}),`\n`,_jsx(CodeBlock,{filename:``,numberOfLines:`41`,language:`php`,children:_jsx(_components.pre,{className:`shiki shiki-themes github-light-default dark-plus`,style:{backgroundColor:`#ffffff`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#1f2328`,\"--shiki-dark\":`#D4D4D4`},language:`php`,children:_jsxs(_components.code,{language:`php`,numberOfLines:`41`,children:[_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:`\u003c?`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#D4D4D4`},children:`php`})]}),`\n`,_jsx(_components.span,{className:`line`}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:`namespace`}),_jsx(_components.span,{style:{color:`#953800`,\"--shiki-dark\":`#4EC9B0`},children:` Acme\\\\OperationsLog\\\\Tests`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`;`})]}),`\n`,_jsx(_components.span,{className:`line`}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:`use`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#D4D4D4`},children:` Acme\\\\OperationsLog\\\\`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#4EC9B0`},children:`OperationsLogChannel`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`;`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:`use`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#D4D4D4`},children:` Illuminate\\\\Bus\\\\`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#4EC9B0`},children:`Queueable`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`;`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:`use`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#D4D4D4`},children:` Illuminate\\\\Contracts\\\\Queue\\\\`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#4EC9B0`},children:`ShouldQueue`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`;`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:`use`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#D4D4D4`},children:` Illuminate\\\\Notifications\\\\`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#4EC9B0`},children:`Notification`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:` as`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#D4D4D4`},children:` BaseNotification`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`;`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:`use`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#D4D4D4`},children:` Illuminate\\\\Support\\\\Facades\\\\`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#4EC9B0`},children:`Notification`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`;`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:`use`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#D4D4D4`},children:` Orchestra\\\\Testbench\\\\`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#4EC9B0`},children:`TestCase`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`;`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:`use`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#D4D4D4`},children:` Psr\\\\Log\\\\`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#4EC9B0`},children:`LoggerInterface`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`;`})]}),`\n`,_jsx(_components.span,{className:`line`}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:`class`}),_jsx(_components.span,{style:{color:`#953800`,\"--shiki-dark\":`#4EC9B0`},children:` OperationsLogChannelTest`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:` extends`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#4EC9B0`},children:` TestCase`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`{`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:` public`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:` function`}),_jsx(_components.span,{style:{color:`#8250DF`,\"--shiki-dark\":`#DCDCAA`},children:` test_channel_writes_the_routed_event`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`()`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:`:`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:` void`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` {`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:` $notification`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:` =`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:` new`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:` class`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:` extends`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#4EC9B0`},children:` BaseNotification`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:` implements`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#4EC9B0`},children:` ShouldQueue`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` {`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:` use`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#4EC9B0`},children:` Queueable`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`;`})]}),`\n`,_jsx(_components.span,{className:`line`}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:` public`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:` function`}),_jsx(_components.span,{style:{color:`#8250DF`,\"--shiki-dark\":`#DCDCAA`},children:` via`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`(`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:`object`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:` $notifiable`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`)`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:`:`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:` array`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` {`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#C586C0`},children:` return`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` [`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#4EC9B0`},children:`OperationsLogChannel`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:`::`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:`class`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`];`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` }`})}),`\n`,_jsx(_components.span,{className:`line`}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:` public`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:` function`}),_jsx(_components.span,{style:{color:`#8250DF`,\"--shiki-dark\":`#DCDCAA`},children:` toOperationsLog`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`(`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:`object`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:` $notifiable`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`)`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:`:`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:` string`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` {`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#C586C0`},children:` return`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` 'health-check-passed'`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`;`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` }`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` };`})}),`\n`,_jsx(_components.span,{className:`line`}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:` $logger`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:` =`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#569CD6`},children:` $this`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:`->`}),_jsx(_components.span,{style:{color:`#8250DF`,\"--shiki-dark\":`#DCDCAA`},children:`createMock`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`(`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#4EC9B0`},children:`LoggerInterface`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:`::`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:`class`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`);`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:` $logger`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:`->`}),_jsx(_components.span,{style:{color:`#8250DF`,\"--shiki-dark\":`#DCDCAA`},children:`expects`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`(`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#569CD6`},children:`$this`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:`->`}),_jsx(_components.span,{style:{color:`#8250DF`,\"--shiki-dark\":`#DCDCAA`},children:`once`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`())`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:`->`}),_jsx(_components.span,{style:{color:`#8250DF`,\"--shiki-dark\":`#DCDCAA`},children:`method`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`(`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`'info'`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`)`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:`->`}),_jsx(_components.span,{style:{color:`#8250DF`,\"--shiki-dark\":`#DCDCAA`},children:`with`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`(`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` 'Operations notification'`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` [`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`'destination'`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:` =>`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` 'operations'`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`, `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`'event'`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:` =>`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` 'health-check-passed'`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`],`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` );`})}),`\n`,_jsx(_components.span,{className:`line`}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#569CD6`},children:` $this`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:`->`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`app`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:`->`}),_jsx(_components.span,{style:{color:`#8250DF`,\"--shiki-dark\":`#DCDCAA`},children:`instance`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`(`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#4EC9B0`},children:`LoggerInterface`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:`::`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:`class`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`, `}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`$logger`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`);`})]}),`\n`,_jsx(_components.span,{className:`line`}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#4EC9B0`},children:` Notification`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:`::`}),_jsx(_components.span,{style:{color:`#8250DF`,\"--shiki-dark\":`#DCDCAA`},children:`route`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`(`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`'operationsLog'`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`, `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`'operations'`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`)`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:`->`}),_jsx(_components.span,{style:{color:`#8250DF`,\"--shiki-dark\":`#DCDCAA`},children:`notifyNow`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`(`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`$notification`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`);`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` }`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`}`})}),`\n`]})})}),`\n`,_jsxs(_components.p,{children:[`Also verify that a missing destination throws an exception and, if you provide an alias, that it resolves from a fresh boot. If the channel is used through the queue, also test in a verification application that runs a separate queue worker that jobs arrive on the `,_jsx(_components.code,{children:`operations-log`}),` queue and are processed.`]}),`\n`,_jsxs(_components.p,{children:[_jsx(_components.code,{children:`NotificationSender`}),` splits a `,_jsx(_components.code,{children:`ShouldQueue`}),` notification into one job per channel and selects the queue using the `,_jsx(_components.code,{children:`viaQueues()`}),` key. If the channel’s `,_jsx(_components.code,{children:`send()`}),` throws an exception, it dispatches `,_jsx(_components.code,{children:`NotificationFailed`}),` and rethrows the exception; if `,_jsx(_components.code,{children:`send()`}),` returns normally, it dispatches `,_jsx(_components.code,{children:`NotificationSent`}),`. Queue retry behavior follows the application’s configuration. Note that if you swallow exceptions inside the channel, failed deliveries are treated as successful.`]}),`\n`,_jsx(Heading,{level:`2`,id:`primary-sources`,children:`Primary sources`}),`\n`,_jsxs(_components.ul,{children:[`\n`,_jsx(_components.li,{children:_jsx(_components.a,{href:`https://github.com/laravel/docs/blob/13.x/notifications.md#custom-channels`,children:`Laravel 13 official documentation: Custom notification channels and queueing`})}),`\n`,_jsx(_components.li,{children:_jsx(_components.a,{href:`https://github.com/laravel/docs/blob/13.x/packages.md#package-discovery`,children:`Laravel 13 official documentation: Package discovery`})}),`\n`,_jsx(_components.li,{children:_jsx(_components.a,{href:`https://github.com/laravel/framework/blob/v13.38.0/src/Illuminate/Notifications/ChannelManager.php`,children:`ChannelManager: Resolution from class names`})}),`\n`,_jsx(_components.li,{children:_jsx(_components.a,{href:`https://github.com/laravel/framework/blob/v13.38.0/src/Illuminate/Notifications/NotificationSender.php`,children:`NotificationSender: Per-channel delivery, queueing, and events`})}),`\n`,_jsx(_components.li,{children:_jsx(_components.a,{href:`https://github.com/laravel/framework/blob/v13.38.0/src/Illuminate/Notifications/RoutesNotifications.php`,children:`RoutesNotifications and AnonymousNotifiable: Notification routes`})}),`\n`,_jsx(_components.li,{children:_jsx(_components.a,{href:`https://github.com/laravel/framework/blob/v13.38.0/src/Illuminate/Support/Manager.php`,children:`Manager: Driver retention and extension`})}),`\n`,_jsx(_components.li,{children:_jsx(_components.a,{href:`https://github.com/laravel/framework/blob/v13.38.0/src/Illuminate/Foundation/Application.php`,children:`Application: LoggerInterface binding`})}),`\n`]})]})}function MDXContent(props={}){const{wrapper:MDXLayout}={..._provideComponents(),...props.components};return MDXLayout?_jsx(MDXLayout,{...props,children:_jsx(_createMdxContent,{...props})}):_createMdxContent(props)}return{default:MDXContent};function _missingMdxReference(id,component){throw new Error(`Expected `+(component?`component`:`object`)+\" `\"+id+\"` to be defined: you likely forgot to import, pass, or provide it.\")}","frontmatter":{},"scope":{"config":{},"pageMetadata":{"title":"Custom notification channels and delivery testing for packages","description":"Learn how to ship Laravel 13 notification channels from a package, covering resolution by class name, destination routing, queueing, and testing real delivery.","href":"/en/advanced/package-notification-channels"}}},"mdxSourceWithNoJs":null},"mdxExtracts":{"tableOfContents":[{"title":"The class name is the delivery method, the route is the destination","slug":"the-class-name-is-the-delivery-method-the-route-is-the-destination","depth":2,"children":[]},{"title":"Ship the channel itself in your package","slug":"ship-the-channel-itself-in-your-package","depth":2,"children":[]},{"title":"Define the notification and destination in the consuming application","slug":"define-the-notification-and-destination-in-the-consuming-application","depth":2,"children":[]},{"title":"When you need a short alias","slug":"when-you-need-a-short-alias","depth":2,"children":[]},{"title":"Test delivery separately from fake","slug":"test-delivery-separately-from-fake","depth":2,"children":[]},{"title":"Primary sources","slug":"primary-sources","depth":2,"children":[]}],"codeExamples":{}},"jsLinks":[],"narration":{"path":"en/advanced/package-notification-channels","locale":"en","estimatedDurationSec":372},"subdomain":"invokable","siteName":"Knowledge of Laravel","title":"Custom notification channels and delivery testing for packages - Knowledge of Laravel","relatedPagesConfig":{"enabled":true,"limit":5,"mode":"automatic"},"navMaps":{"firstHrefInVersion":{},"firstHrefInLanguage":{"jp":{"href":"/jp/advanced/package-notification-channels","matchLevel":1},"en":{"href":"/en/advanced/package-notification-channels","matchLevel":0},"de":{"href":"/de/advanced/package-notification-channels","matchLevel":1},"es":{"href":"/es/advanced/package-notification-channels","matchLevel":1},"fr":{"href":"/fr/advanced/package-notification-channels","matchLevel":1},"it":{"href":"/it/advanced/package-notification-channels","matchLevel":1},"ko":{"href":"/ko/advanced/package-notification-channels","matchLevel":1},"nl":{"href":"/nl/advanced/package-notification-channels","matchLevel":1},"zh-Hans":{"href":"/zh-CN/advanced/package-notification-channels","matchLevel":1},"zh-Hant":{"href":"/zh-TW/advanced/package-notification-channels","matchLevel":1}}},"lastModified":"2026-10-22T22:21:35.010Z","gitLastModified":"2026-10-22T22:21:00.000Z","originalFileLocation":"en/advanced/package-notification-channels.mdx","locale":"en"},"headHtml":"\u003cscript data-mint-head>(function(){var d=document.documentElement,p=null;if(!p){try{p=localStorage.getItem(\"isDarkMode\")}catch(e){}if(p==='true')p='dark';else if(p==='false')p='light';if(p!=='light'\u0026\u0026p!=='dark'\u0026\u0026p!=='system')p=\"system\"}var r=p==='system'?(matchMedia(\"(prefers-color-scheme: dark)\").matches?'dark':'light'):p;d.classList.remove(r==='dark'?'light':'dark');d.classList.add(r);d.setAttribute(\"data-theme-preference\",p)})();\u003c/script>\u003cmeta data-mint-head name=\"description\" content=\"Learn how to ship Laravel 13 notification channels from a package, covering resolution by class name, destination routing, queueing, and testing real delivery.\">\u003cmeta data-mint-head name=\"application-name\" content=\"Knowledge of Laravel\">\u003cmeta data-mint-head name=\"generator\" content=\"Mintlify\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"192x192\" href=\"/mintlify-assets/_mintlify/favicons/invokable/pboFjibLpJPX3oCo/_generated/favicon/android-chrome-192x192.png\" media=\"(prefers-color-scheme: light)\">\u003clink data-mint-head rel=\"apple-touch-icon\" type=\"image/png\" sizes=\"180x180\" href=\"/mintlify-assets/_mintlify/favicons/invokable/pboFjibLpJPX3oCo/_generated/favicon/apple-touch-icon.png\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"16x16\" href=\"/mintlify-assets/_mintlify/favicons/invokable/pboFjibLpJPX3oCo/_generated/favicon/favicon-16x16.png\" media=\"(prefers-color-scheme: light)\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"32x32\" href=\"/mintlify-assets/_mintlify/favicons/invokable/pboFjibLpJPX3oCo/_generated/favicon/favicon-32x32.png\" media=\"(prefers-color-scheme: light)\">\u003clink data-mint-head rel=\"shortcut icon\" type=\"image/x-icon\" href=\"/mintlify-assets/_mintlify/favicons/invokable/pboFjibLpJPX3oCo/_generated/favicon/favicon.ico\" media=\"(prefers-color-scheme: light)\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"192x192\" href=\"/mintlify-assets/_mintlify/favicons/invokable/pboFjibLpJPX3oCo/_generated/favicon-dark/android-chrome-192x192.png\" media=\"(prefers-color-scheme: dark)\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"16x16\" href=\"/mintlify-assets/_mintlify/favicons/invokable/pboFjibLpJPX3oCo/_generated/favicon-dark/favicon-16x16.png\" media=\"(prefers-color-scheme: dark)\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"32x32\" href=\"/mintlify-assets/_mintlify/favicons/invokable/pboFjibLpJPX3oCo/_generated/favicon-dark/favicon-32x32.png\" media=\"(prefers-color-scheme: dark)\">\u003clink data-mint-head rel=\"shortcut icon\" type=\"image/x-icon\" href=\"/mintlify-assets/_mintlify/favicons/invokable/pboFjibLpJPX3oCo/_generated/favicon-dark/favicon.ico\" media=\"(prefers-color-scheme: dark)\">\u003cmeta data-mint-head property=\"og:title\" content=\"Custom notification channels and delivery testing for packages - Knowledge of Laravel\">\u003cmeta data-mint-head property=\"og:description\" content=\"Learn how to ship Laravel 13 notification channels from a package, covering resolution by class name, destination routing, queueing, and testing real delivery.\">\u003cmeta data-mint-head property=\"og:site_name\" content=\"Knowledge of Laravel\">\u003cmeta data-mint-head property=\"og:url\" content=\"https://kawax.biz/en/advanced/package-notification-channels\">\u003cmeta data-mint-head property=\"og:type\" content=\"website\">\u003cmeta data-mint-head property=\"og:image\" content=\"https://invokable.mintlify.site/_mintlify/api/og/v2?division=Package+Development\u0026amp;title=Custom+notification+channels+and+delivery+testing+for+packages\u0026amp;description=Learn+how+to+ship+Laravel+13+notification+channels+from+a+package%2C+covering+resolution+by+class+name%2C+destination+routing%2C+queueing%2C+and+testing+real+delivery.\u0026amp;theme=cef70bdc0dd1884481ab7c5d\u0026amp;signature=85d26b4e3a2f01617dc687b169eb5486aab072d0fb059feac285b9f856e91dbd\">\u003cmeta data-mint-head property=\"og:image:width\" content=\"1200\">\u003cmeta data-mint-head property=\"og:image:height\" content=\"630\">\u003cmeta data-mint-head name=\"twitter:card\" content=\"summary_large_image\">\u003cmeta data-mint-head name=\"twitter:title\" content=\"Custom notification channels and delivery testing for packages - Knowledge of Laravel\">\u003cmeta data-mint-head name=\"twitter:description\" content=\"Learn how to ship Laravel 13 notification channels from a package, covering resolution by class name, destination routing, queueing, and testing real delivery.\">\u003cmeta data-mint-head name=\"twitter:image\" content=\"https://invokable.mintlify.site/_mintlify/api/og/v2?division=Package+Development\u0026amp;title=Custom+notification+channels+and+delivery+testing+for+packages\u0026amp;description=Learn+how+to+ship+Laravel+13+notification+channels+from+a+package%2C+covering+resolution+by+class+name%2C+destination+routing%2C+queueing%2C+and+testing+real+delivery.\u0026amp;theme=cef70bdc0dd1884481ab7c5d\u0026amp;signature=85d26b4e3a2f01617dc687b169eb5486aab072d0fb059feac285b9f856e91dbd\">\u003cmeta data-mint-head name=\"twitter:image:width\" content=\"1200\">\u003cmeta data-mint-head name=\"twitter:image:height\" content=\"630\">\u003cmeta data-mint-head name=\"msapplication-config\" content=\"/mintlify-assets/_mintlify/favicons/invokable/pboFjibLpJPX3oCo/_generated/favicon/browserconfig.xml\">\u003cmeta data-mint-head name=\"apple-mobile-web-app-title\" content=\"Knowledge of Laravel\">\u003cmeta data-mint-head name=\"msapplication-TileColor\" content=\"#16A34A\">\u003clink data-mint-head rel=\"canonical\" href=\"https://kawax.biz/en/advanced/package-notification-channels\">\u003clink data-mint-head rel=\"alternate\" type=\"application/xml\" href=\"/sitemap.xml\">\u003clink data-mint-head rel=\"alternate\" type=\"text/markdown\" href=\"/en/advanced/package-notification-channels.md\">\u003clink data-mint-head rel=\"alternate\" hreflang=\"en\" href=\"https://kawax.biz/en/advanced/package-notification-channels\">\u003clink data-mint-head rel=\"alternate\" hreflang=\"ja\" href=\"https://kawax.biz/jp/advanced/package-notification-channels\">\u003clink data-mint-head rel=\"alternate\" hreflang=\"de\" href=\"https://kawax.biz/de/advanced/package-notification-channels\">\u003clink data-mint-head rel=\"alternate\" hreflang=\"es\" href=\"https://kawax.biz/es/advanced/package-notification-channels\">\u003clink data-mint-head rel=\"alternate\" hreflang=\"fr\" href=\"https://kawax.biz/fr/advanced/package-notification-channels\">\u003clink data-mint-head rel=\"alternate\" hreflang=\"it\" href=\"https://kawax.biz/it/advanced/package-notification-channels\">\u003clink data-mint-head rel=\"alternate\" hreflang=\"ko\" href=\"https://kawax.biz/ko/advanced/package-notification-channels\">\u003clink data-mint-head rel=\"alternate\" hreflang=\"nl\" href=\"https://kawax.biz/nl/advanced/package-notification-channels\">\u003clink data-mint-head rel=\"alternate\" hreflang=\"zh-Hans\" href=\"https://kawax.biz/zh-CN/advanced/package-notification-channels\">\u003clink data-mint-head rel=\"alternate\" hreflang=\"zh-Hant\" href=\"https://kawax.biz/zh-TW/advanced/package-notification-channels\">\u003clink data-mint-head rel=\"alternate\" hreflang=\"x-default\" href=\"https://kawax.biz/jp/advanced/package-notification-channels\">\u003cscript data-mint-head type=\"application/ld+json\">{\"@context\":\"https://schema.org\",\"@graph\":[{\"@type\":\"Organization\",\"@id\":\"https://kawax.biz/#organization\",\"name\":\"Knowledge of Laravel\",\"url\":\"https://kawax.biz\",\"logo\":{\"@type\":\"ImageObject\",\"url\":\"https://mintcdn.com/invokable/AuZ0xql2mAbUyZ99/logo/light.svg?fit=max\u0026auto=format\u0026n=AuZ0xql2mAbUyZ99\u0026q=85\u0026s=df0b7397202a6aa1c1f321620c5aa146\"}},{\"@type\":\"WebSite\",\"@id\":\"https://kawax.biz#website\",\"name\":\"Knowledge of Laravel\",\"url\":\"https://kawax.biz\",\"publisher\":{\"@id\":\"https://kawax.biz/#organization\"}},{\"@type\":\"WebPage\",\"@id\":\"https://kawax.biz/en/advanced/package-notification-channels#webpage\",\"url\":\"https://kawax.biz/en/advanced/package-notification-channels\",\"name\":\"Custom notification channels and delivery testing for packages\",\"description\":\"Learn how to ship Laravel 13 notification channels from a package, covering resolution by class name, destination routing, queueing, and testing real delivery.\",\"dateModified\":\"2026-10-22T22:21:00.000Z\",\"isPartOf\":{\"@id\":\"https://kawax.biz#website\"},\"breadcrumb\":{\"@id\":\"https://kawax.biz/en/advanced/package-notification-channels#breadcrumb\"}},{\"@type\":\"BreadcrumbList\",\"@id\":\"https://kawax.biz/en/advanced/package-notification-channels#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Package Development\",\"item\":\"https://kawax.biz/en/advanced/package-development\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"Custom notification channels and delivery testing for packages\",\"item\":\"https://kawax.biz/en/advanced/package-notification-channels\"}]},{\"@type\":[\"Article\",\"TechArticle\"],\"@id\":\"https://kawax.biz/en/advanced/package-notification-channels#article\",\"headline\":\"Custom notification channels and delivery testing for packages\",\"name\":\"Custom notification channels and delivery testing for packages\",\"description\":\"Learn how to ship Laravel 13 notification channels from a package, covering resolution by class name, destination routing, queueing, and testing real delivery.\",\"url\":\"https://kawax.biz/en/advanced/package-notification-channels\",\"mainEntityOfPage\":{\"@id\":\"https://kawax.biz/en/advanced/package-notification-channels#webpage\"},\"dateModified\":\"2026-10-22T22:21:00.000Z\",\"publisher\":{\"@id\":\"https://kawax.biz/#organization\"},\"isPartOf\":{\"@id\":\"https://kawax.biz#website\"}}]}\u003c/script>\u003cscript data-mint-head type=\"application/ld+json\">{\"@context\":\"https://schema.org\",\"@type\":\"WebSite\",\"name\":\"Knowledge of Laravel\",\"publisher\":{\"@type\":\"Organization\",\"name\":\"Knowledge of Laravel\"},\"provider\":{\"@type\":\"Organization\",\"name\":\"Mintlify\",\"url\":\"https://mintlify.com\"}}\u003c/script>","agentPointerHref":"/en/advanced/package-notification-channels.md","siteName":"Knowledge of Laravel","nav":{"global":null,"languages":[{"language":"jp","default":true,"pages":[{"title":"jp","href":"/jp/advanced/package-notification-channels"}]},{"language":"en","tabs":[{"tab":"My Packages","pages":[{"title":"My Packages","href":"/en/packages/laravel-boost-copilot-cli"}]},{"tab":"Tutorial","pages":[{"title":"Tutorial","href":"/en/introduction"}]},{"tab":"Guide","pages":[{"title":"Guide","href":"/en/lifecycle"}]},{"tab":"Advanced Topics","groups":[{"group":"AI Development","pages":[{"title":"Building an MCP Server with Laravel","href":"/en/advanced/mcp-server"},{"title":"Creating a Custom Agent for Boost","href":"/en/advanced/boost-custom-agent"},{"title":"Creating a Custom Provider for AI SDK","href":"/en/advanced/ai-sdk-custom-provider"},{"title":"Agent Middleware in Laravel AI SDK","href":"/en/advanced/ai-sdk-agent-middleware"}]},{"group":"Design Patterns","pages":[{"title":"The Pipeline Pattern","href":"/en/advanced/pipeline"},{"title":"Fluent Class","href":"/en/advanced/fluent"},{"title":"The Macroable Trait","href":"/en/advanced/macroable"},{"title":"The Conditionable Trait","href":"/en/advanced/conditionable"},{"title":"The InteractsWithTime Trait","href":"/en/advanced/interacts-with-time"},{"title":"The ForwardsCalls trait","href":"/en/advanced/forwards-calls"},{"title":"tap() Helper and the Tappable Trait","href":"/en/advanced/tap"},{"title":"The once() helper internals — Once, Onceable, and PreventsCircularRecursion","href":"/en/advanced/once-helper"},{"title":"The Dumpable Trait","href":"/en/advanced/dumpable"},{"title":"Support Contracts (Arrayable / Jsonable / Htmlable / Responsable)","href":"/en/advanced/support-contracts"},{"title":"The Lottery class","href":"/en/advanced/lottery"},{"title":"Higher Order Messages","href":"/en/advanced/higher-order-messages"},{"title":"Collection Deep Dive","href":"/en/advanced/collection-deep-dive"},{"title":"Illuminate\\Support\\Manager — anatomy of the driver system","href":"/en/advanced/manager"},{"title":"PHP Reflection API","href":"/en/advanced/php-reflection"},{"title":"PHP FFI","href":"/en/advanced/ffi"},{"title":"PHP AST","href":"/en/advanced/php-ast"}]},{"group":"Package Development","pages":[{"title":"Laravel Package Development","href":"/en/advanced/package-development"},{"title":"Package auto-discovery internals","href":"/en/advanced/package-discovery"},{"title":"The InteractsWithData trait","href":"/en/advanced/interacts-with-data"},{"title":"Deferred Service Providers","href":"/en/advanced/deferred-provider"},{"title":"Package Version Compatibility Management","href":"/en/advanced/package-versioning"},{"title":"GitHub Actions Pinning and Security","href":"/en/advanced/github-actions-pinning"},{"title":"Package CHANGELOG and Release Management","href":"/en/advanced/package-changelog"},{"title":"Testing Laravel packages with Orchestra Testbench","href":"/en/advanced/package-testing"},{"title":"Develop Laravel packages with Testbench Workbench","href":"/en/advanced/package-workbench"},{"title":"GeneratorCommand — Implementing custom make: commands","href":"/en/advanced/generator-command"},{"title":"Creating a Laravel Starter Kit","sidebarTitle":"Creating a Starter Kit","href":"/en/advanced/starter-kit-creation"},{"title":"Package Static Analysis (PHPStan / Larastan)","href":"/en/advanced/package-static-analysis"},{"title":"Package config merging and caching","href":"/en/advanced/package-config-merging"},{"title":"Publishing and updating package migrations","href":"/en/advanced/package-migrations"},{"title":"Overriding and updating package views","href":"/en/advanced/package-views"},{"title":"Package route registration and caching","href":"/en/advanced/package-routes"},{"title":"Integrating package caches with optimize","href":"/en/advanced/package-optimization"},{"title":"Package public assets and updates","href":"/en/advanced/package-assets"},{"title":"Package translation overrides and updates","href":"/en/advanced/package-translations"},{"title":"Package service resolution hooks","href":"/en/advanced/package-service-resolution"},{"title":"Adding package diagnostics to about","href":"/en/advanced/package-about"},{"title":"Registering package Artisan commands and resolving dependencies","href":"/en/advanced/package-commands"},{"title":"Registering and caching package event listeners","href":"/en/advanced/package-events"},{"title":"Package service lifetime design","href":"/en/advanced/package-service-lifetimes"},{"title":"Package middleware registration and scope","href":"/en/advanced/package-middleware"},{"title":"Package Blade extensions and the compilation cache","href":"/en/advanced/package-blade-extensions"},{"title":"Registering and re-resolving package Storage drivers","description":"Examine the Laravel 13 FilesystemManager to learn how Storage::extend() registration works, how disk instances are retained, how to re-resolve disks after configuration changes, and how to verify drivers without relying on fake.","href":"/en/advanced/package-filesystem-drivers"},{"title":"Custom notification channels and delivery testing for packages","href":"/en/advanced/package-notification-channels"},{"title":"Package container tags and plugin aggregation","description":"Use container tags in Laravel 13 to aggregate implementations from multiple packages, and examine the lazy resolution of tagged(), how it differs from giveTagged(), duplicate registration, and lifecycles.","href":"/en/advanced/package-container-tags"},{"title":"HTTP clients and testing in packages","href":"/en/advanced/package-http-client"},{"title":"Extending and re-resolving log channels in packages","href":"/en/advanced/package-logging"},{"title":"Custom cache stores and contracts in packages","href":"/en/advanced/package-cache-drivers"},{"title":"Registering and testing mail transports in packages","href":"/en/advanced/package-mail-transports"},{"title":"Package contextual attributes and dependency resolution","href":"/en/advanced/package-contextual-attributes"},{"title":"Registering and maintaining scheduled tasks in packages","href":"/en/advanced/package-scheduling"},{"title":"Custom session drivers in packages","href":"/en/advanced/package-session-drivers"},{"title":"Extending database connections in packages","href":"/en/advanced/package-database-connections"},{"title":"Registering dynamic relationships in packages","href":"/en/advanced/package-dynamic-relations"},{"title":"Registering string validation rules in packages","sidebarTitle":"String validation rules","href":"/en/advanced/package-validation-extensions"},{"title":"Package response macros and HTTP contracts","href":"/en/advanced/package-response-macros"},{"title":"Package service decoration and extend","href":"/en/advanced/package-service-decoration"},{"title":"Package policy registration and overrides","href":"/en/advanced/package-authorization"},{"title":"Package morph maps and stored data compatibility","href":"/en/advanced/package-morph-maps"}]},{"group":"Application Structure","pages":[{"title":"Application Structure in Laravel 11 and Later","href":"/en/advanced/app-structure"},{"title":"Migration Guide: Old Structure to Slim Application Skeleton","sidebarTitle":"Migration Guide","href":"/en/advanced/app-structure-migration"},{"title":"Laravel 11+ New Application Structure FAQ","sidebarTitle":"New App Structure FAQ","href":"/en/advanced/app-structure-faq"}]},{"group":"Laravel 13 New Features","pages":[{"title":"PHP Attributes","href":"/en/advanced/php-attributes"},{"title":"Controller PHP Attributes","sidebarTitle":"Controller Attributes","href":"/en/advanced/controller-attributes"}]},{"group":"Eloquent Deep Dive","pages":[{"title":"Eloquent Observers and Model Events","href":"/en/advanced/eloquent-observers"},{"title":"Eloquent Scopes","href":"/en/advanced/eloquent-scopes"},{"title":"Eloquent Custom Casts","href":"/en/advanced/eloquent-casts"},{"title":"Eloquent Bootable Traits","href":"/en/advanced/eloquent-bootable-traits"},{"title":"Custom pivot models and chaperone","href":"/en/advanced/eloquent-custom-pivot"},{"title":"Eloquent afterQuery and the result contract","sidebarTitle":"afterQuery and result processing","href":"/en/advanced/eloquent-after-query"}]},{"group":"Validation Extensions","pages":[{"title":"Custom Validation Rules","href":"/en/advanced/custom-validation-rules"}]},{"group":"Authentication Extensions","pages":[{"title":"Custom Authentication Guards","href":"/en/advanced/custom-auth-guard"},{"title":"Laravel Fortify and Starter Kits","href":"/en/advanced/fortify"}]},{"group":"Security","pages":[{"title":"Rate Limiting","href":"/en/advanced/rate-limiting"}]},{"group":"Queues","pages":[{"title":"Queue Job Execution Control","href":"/en/advanced/queue-job-control"}]},{"group":"Testing","pages":[{"title":"Advanced Testing with Pest","href":"/en/advanced/testing-pest"}]},{"group":"Realtime","pages":[{"title":"Inside the Mercure broadcast driver","href":"/en/advanced/mercure-broadcasting"}]}]},{"tab":"Blog","pages":[{"title":"Blog","href":"/en/blog/changelog/202610"}]}]},{"language":"de","pages":[{"title":"de","href":"/de/advanced/package-notification-channels"}]},{"language":"es","pages":[{"title":"es","href":"/es/advanced/package-notification-channels"}]},{"language":"fr","pages":[{"title":"fr","href":"/fr/advanced/package-notification-channels"}]},{"language":"it","pages":[{"title":"it","href":"/it/advanced/package-notification-channels"}]},{"language":"ko","pages":[{"title":"ko","href":"/ko/advanced/package-notification-channels"}]},{"language":"nl","pages":[{"title":"nl","href":"/nl/advanced/package-notification-channels"}]},{"language":"zh-Hans","pages":[{"title":"zh-Hans","href":"/zh-CN/advanced/package-notification-channels"}]},{"language":"zh-Hant","pages":[{"title":"zh-Hant","href":"/zh-TW/advanced/package-notification-channels"}]}]},"basePath":"","title":"Custom notification channels and delivery testing for packages - Knowledge of Laravel","buildId":"dpl_DqYu5MPb49gWBBbUGgpHQUmCHY3P","deploymentId":"dpl_DqYu5MPb49gWBBbUGgpHQUmCHY3P","dynamics":["2bfc744e19"],"chunks":["NarrationPlayer-CfOFO133.js","types-CiTgMxws.js","shallow-dY3TMRCk.js"]}