You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Currently, you have to specify multiple recipients and pass an X-Mailgun-Recipient-Variables header containing JSON-encoded recipient variables that can be used in your e-mail.
Unfortunately neither this bundle nor Swiftmailer itself can assist you here as we can only implement the lowest common denominator of all features supported by both Swiftmailer and Mailgun. The Swiftmailer developers themselves recommend sending each email individually (see http://swiftmailer.org/docs/sending.html#sending-emails-in-batch). But of course they do not use any of Mailgun's specialized capabilities in their code.
Activity
tehplague commentedon Jun 3, 2016
Currently, you have to specify multiple recipients and pass an
X-Mailgun-Recipient-Variablesheader containing JSON-encoded recipient variables that can be used in your e-mail.Unfortunately neither this bundle nor Swiftmailer itself can assist you here as we can only implement the lowest common denominator of all features supported by both Swiftmailer and Mailgun. The Swiftmailer developers themselves recommend sending each email individually (see http://swiftmailer.org/docs/sending.html#sending-emails-in-batch). But of course they do not use any of Mailgun's specialized capabilities in their code.
Nyholm commentedon Jun 3, 2016
That is a good question. We should document that answer in the readme.
picks44 commentedon Jun 3, 2016
Thank you, that helps a lot! In the meantime I've develop my own "kind-of-batch" sending method in my mailer service
with
$tobeing an array[email] => namegondo commentedon Jun 7, 2018
X-Mailgun-Recipient-Variablesheader with recipients doesn't worki'm unsuccessfully trying to get an official answer from mailgun support