Postmark Mail Driver
The symfony/postmark-mailer bridge is already a dependency of flarum/core but we have never exposed a PostmarkDriver to match.
What needs doing
- Add
src/Mail/PostmarkDriver.php implementing DriverInterface
- Settings:
mail_postmark_token (Server Token), optionally mail_postmark_message_stream
buildTransport() creates a PostmarkApiTransport via PostmarkTransportFactory
- Register the driver in
MailServiceProvider ('postmark' => PostmarkDriver::class)
- Add locale keys to
core.yml (mail_postmark_token_label, postmark_heading, postmark_description, etc.)
- Unit tests mirroring
MailgunDriverTest
- Update integration test in
MailTest.php
Why core and not a FoF extension?
The dep is already present — adding the driver is essentially free. Postmark is a widely-used transactional mail provider with first-party support in Laravel itself, and the pattern is identical to the existing Mailgun driver.
References
- Symfony bridge:
symfony/postmark-mailer
- Existing pattern:
src/Mail/MailgunDriver.php
Postmark Mail Driver
The
symfony/postmark-mailerbridge is already a dependency offlarum/corebut we have never exposed aPostmarkDriverto match.What needs doing
src/Mail/PostmarkDriver.phpimplementingDriverInterfacemail_postmark_token(Server Token), optionallymail_postmark_message_streambuildTransport()creates aPostmarkApiTransportviaPostmarkTransportFactoryMailServiceProvider('postmark' => PostmarkDriver::class)core.yml(mail_postmark_token_label,postmark_heading,postmark_description, etc.)MailgunDriverTestMailTest.phpWhy core and not a FoF extension?
The dep is already present — adding the driver is essentially free. Postmark is a widely-used transactional mail provider with first-party support in Laravel itself, and the pattern is identical to the existing Mailgun driver.
References
symfony/postmark-mailersrc/Mail/MailgunDriver.php