andrei-mireichyk/sendpulse-mailer
MailerInterface, making it a seamless fit for Laravel applications using Laravel Mail (which is built on Symfony Mailer). This ensures compatibility with Laravel’s existing email infrastructure (e.g., Mail::send(), Mailable classes).X-SendPulse-Event, SendPulseVariableHeader) allow for advanced SendPulse features like dynamic content, event tracking, and personalization without reinventing the wheel..env configuration via MAILER_DSN, mirroring Laravel’s native mail driver setup (e.g., MAIL_MAILER=sendpulse).^4.4|^5.0|^6.0 could conflict with Laravel’s bundled Symfony components (e.g., Laravel 10 uses Symfony 6.4). Risk: Minor version skew may require composer overrides or patching.Mail facade and Mailable classes due to Symfony Mailer underpinnings. Example:
// config/mail.php
'sendpulse' => [
'transport' => 'sendpulse+smtp-api://USER_ID:SECRET@default',
],
.env switching.MailFake or Pest/PHPUnit to mock SendPulse responses during development.Mailable class with the SendPulse driver to validate functionality.config/mail.php to use the SendPulse DSN..env with SendPulse keys.X-SendPulse-Event).SendPulseVariableHeader).MailerInterface is job-serializable (Symfony Mailer supports this by default)..env with MAIL_MAILER=sendpulse and the appropriate DSN.MAIL_MAILER=sendpulse
MAILER_DSN=sendpulse+smtp-api://USER_ID:SECRET@default
Mail::to()->send() with SendPulse-specific headers where needed.$mailable->withSendPulseEvent('user_signup')
->withSendPulseVariable('user_name', $user->name);
Mail::fake() to verify emails are structured correctly.MAILER_DEBUG=true in .env).SendPulseVariableHeader.| Failure Scenario | Impact | Mitigation |
|---|---|---|
| SendPulse API downtime | Emails fail silently | Fallback to a secondary SMTP provider |
| Authentication errors | All emails blocked | Validate .env credentials; use SendPulse logs |
| Rate limit exceeded | Emails queued or dropped | Implement exponential backoff in queue worker |
| Malformed SendPulse headers | Emails sent but misconfigured | Validate headers before sending |
| PHP/Symfony version conflict | Integration breaks | Use composer platform-check or overrides |
How can I help you explore Laravel packages today?