resend/resend-laravel
Resend integration for Laravel and Symfony Mailer. Send emails via the Resend API using a simple facade, or switch to the bundled Laravel mailer transport. Configure your RESEND_API_KEY and set MAIL_MAILER=resend to get started.
Resend facade provides a clean, Laravel-idiomatic API for direct Resend API calls, reducing boilerplate for advanced use cases (e.g., sending emails via Resend’s API directly).VerifyWebhookSignature) and event handling for Resend webhooks (e.g., email.failed, contact.created) enable real-time email event processing without custom infrastructure..env, update config/mail.php, and set MAIL_MAILER=resend). No database migrations or schema changes are needed.Resend facade for granular control (e.g., sending emails outside Laravel’s mail system).resend/resend-php library for breaking changes.composer require resend/resend-laravel)..env and config/mail.php for Resend.queue option → Resend’s queue parameter).VerifyWebhookSignature middleware to the relevant routes.HandleIncomingWebhook).MAIL_MAILER=resend in .env.Mailable classes with minimal changes (e.g., add Resend-specific metadata like tags).Mail::later()) may need adaptation (e.g., using Resend::emails()->send() in queue jobs).resend/resend-laravel and resend/resend-php for breaking changes. Use Laravel’s composer update with caution (test in staging first).from address) in Laravel’s config or environment files to avoid hardcoding.retry helper or a package like spatie/laravel-activitylog for tracking).us, eu). Configure the closest region to reduce latency.| Failure Scenario | Impact | Mitigation |
|---|---|---|
| Resend API Outage | Emails fail to send. | Implement a fallback mailer (e.g., SMTP) with feature flags. |
| Webhook Delivery Failures | Missed email events (e.g., bounces). | Use exponential backoff in webhook retries. Log failures for manual review. |
| API Rate Limits Exceeded | Throttled requests. | Queue emails and implement retry logic with delays. |
| Invalid API Key | All API calls fail. | Monitor .env for key changes; use Laravel’s env() helper for validation. |
| Template Rendering Errors | Emails fail to send. | Validate templates in staging; use Resend’s preview tools. |
| Data Residency Compliance Issues | Legal risks. | Choose Resend’s regional endpoints; audit data storage practices. |
tags, idempotency_keys) and Laravel integration points (e.g., Resend facade vs. mailer).How can I help you explore Laravel packages today?