symfony/brevo-mailer

Symfony Brevo Mailer Bridge

Maintainers

Package info

github.com/symfony/brevo-mailer

Homepage

Type:symfony-mailer-bridge

pkg:composer/symfony/brevo-mailer

Transparency log

Statistics

Installs: 3 044 684

Dependents: 3

Suggesters: 2

Stars: 25

v8.1.0 2026-05-29 05:06 UTC

README

Provides Brevo integration for Symfony Mailer. This was added upon Sendinblue's rebranding to Brevo.

Configuration example:

# SMTP
MAILER_DSN=brevo+smtp://USERNAME:PASSWORD@default

# SMTP on a specific port
MAILER_DSN=brevo+smtp://USERNAME:PASSWORD@default:587

# API
MAILER_DSN=brevo+api://KEY@default

where:

  • KEY is your Brevo API Key

The SMTP port defaults to 465, which uses implicit TLS. On any other port the connection starts in clear text and is upgraded with STARTTLS when the server offers it.

With API, you can use custom headers.

$params = ['param1' => 'foo', 'param2' => 'bar'];
$json = json_encode(['custom_header_1' => 'custom_value_1']);

$email = new Email();
$email
    ->getHeaders()
    ->add(new MetadataHeader('custom', $json))
    ->add(new TagHeader('TagInHeaders1'))
    ->add(new TagHeader('TagInHeaders2'))
    ->addTextHeader('sender.ip', '1.2.3.4')
    ->addTextHeader('templateId', 1)
    ->addParameterizedHeader('params', 'params', $params)
    ->addTextHeader('foo', 'bar')
;

This example allow you to set:

  • templateId
  • params
  • tags
  • headers
    • sender.ip
    • X-Mailin-Custom

For more information, you can refer to Brevo API documentation.

Sponsor

This package is looking for a backer.

Help Symfony by sponsoring its development!

Resources