Skip to main content
wazobiamail/wazobiamail-laravel plugs WazobiaMail into Laravel’s native mail system. Set MAIL_MAILER=wazobiamail and existing Mail, Mailables and notifications keep working while delivery moves to the WazobiaMail API.

Packagist

wazobiamail/wazobiamail-laravel — v0.1.2

Source

WazobiaMail/wazobiamail-laravel

At a glance

Install

The package uses Laravel package auto-discovery, so the provider and facade register without editing config/app.php.

Configure

Register the mailer in config/mail.php if your app does not merge it automatically:
The published config/wazobiamail.php reads WAZOBIA_API_KEY, WAZOBIA_BASE_URL and WAZOBIA_TIMEOUT.

Send with Laravel Mail

Mailables and notifications route through the custom transport, so attachments, CC/BCC, reply-to and HTML/text bodies keep their normal Laravel semantics.

Use the facade

Webhook controller

Exclude the webhook route from CSRF in bootstrap/app.php or VerifyCsrfToken, and always use the raw body for signature verification.

Errors

The transport surfaces the PHP SDK exceptions (ValidationException, RateLimitException, ForbiddenException, etc.). Let them bubble to Laravel’s handler for retries/queue failures, or catch them in the Mailable/job when you need custom behavior.

Queues

Sending through a queued Mailable/job is recommended for request-path latency. Configure a queue driver and use Mail::to(...)->queue(...). If you need strict duplicate protection across retries, send through the PHP SDK messages()->send($payload, $idempotencyKey) instead of the generic Laravel transport.