hafael / azure-mailer-driver
Supercharge your Laravel or Symfony app with Microsoft Azure Communication Services (ACS)! Effortlessly add email, chat, voice, video, and telephony-over-IP for next-level communication. 🚀
Requires
- php: >=8.2
- illuminate/mail: ^12.0|^13.0
- symfony/azure-mailer: ^7.2|^8.0
Requires (Dev)
- illuminate/config: ^12.0|^13.0
- illuminate/container: ^12.0|^13.0
- laravel/pint: ^1.29
- phpunit/phpunit: ^11.0
- symfony/http-client: ^7.2|^8.0
Suggests
- symfony/http-client: Required to enable support for the Symfony API mail transports (^7.2 || ^8.0).
This package is auto-updated.
Last update: 2026-04-28 14:08:13 UTC
README
✅ Simple implementation example of Symfony Azure Mailer Bridge for Laravel Framework.
✅ Bootable scripts for Laravel
A use case of the symfony/azure-mailer component using bootable scripts in the Laravel framework to send email messages.
💡 Requirements
- PHP 8.2 or higher
- Laravel (actively maintained versions)
🧩 Available resources
| Resource | Status |
|---|---|
| Plain Text | ✅ |
| HTML | ✅ |
| Attachments | ✅ |
| Multiple recipients | ✅ |
| Auth HMAC-SHA256 | ✅ |
| Notifications | ✅ |
| Mkt Campaigns | ✅ |
| Markdown | ✅ |
📦 Installation
First time using Azure Communication Services (ACS)? Create your Azure account if you don't have one already.
On your project directory run on the command line
composer require hafael/azure-mailer-driver symfony/http-client
🌟 Set mail config
Add credentials to config/services.php:
'acs' => [ 'endpoint' => env('AZURE_COMMUNICATION_ENDPOINT'), 'key' => env('AZURE_COMMUNICATION_KEY'), ],
Add entry to config/mail.php:
'mailers' => [ //...other drivers 'acs' => [ 'transport' => 'acs', // 'api_version' => '2023-03-31', // optional // 'disable_tracking' => false, // optional ], ]
Add entry to .env:
#...other entries
# Mail service entries...
MAIL_MAILER=acs
# Azure Communication Services entries
AZURE_COMMUNICATION_ENDPOINT=https://my-resource.communication.azure.com
AZURE_COMMUNICATION_KEY=Base64AzureAccessKey
and just send your notification mail messages!
🔄 Upgrading from previous versions
Previous versions used transport: azure with different config keys. Both the old transport name and config keys are still supported for backwards compatibility.
| Old key | New key | Notes |
|---|---|---|
access_key |
key |
renamed |
resource_name |
endpoint |
expanded to full URL: https://{resource_name}.communication.azure.com |
disable_user_tracking |
disable_tracking |
renamed |
📚 Documentation
Build powerful, cloud-based communication and customer engagement experiences by adding voice, video, chat, sms, email, teams interoperability, call automation, and telephony to your apps.
Visit our Dev Site for further information regarding:
- Azure Communication Service Docs: English
💡 Last change
- Modernized to use Laravel's native transport extension hook (
Mail::extend) - New transport name
acswith credentials viaconfig/services.php - Full backwards compatibility with legacy
azuretransport and old config keys
📜 License
MIT license. Copyright (c) 2023 - Rafael For more information, see the LICENSE file.