Product
Introducing the Mailgun module for Drupal
Looking for a Mailgun module to fit Drupal? Jeffrey Chen goes into the details of his Mailgun module and documentation. Read more...
PUBLISHED ON
This post was contributed by Jeffrey Chen at Peano Inc.
One thing Mailgun and Drupal have in common is that they’re both developer-centric services, making it extremely easy to extend and build on top of their structure and APIs.
I discovered Mailgun when I was working with a client that needed an email service with a flexible pricing structure to support their fluctuant email sending volume that varied greatly from month to month. Mailgun was the perfect fit for their requirements. We use Drupal for all of our sites and since there wasn’t an existing integration built for Drupal, we went ahead and built the module.
We built a basic integration with the following key features:
Queue support: Queuing enables messages to be sent on cron runs, which comes in handy for sending a large amount of messages.
Support for all Mailgun message parameters: You can easily specify BCCs, add tags, disable tracking for just one message, or add your own header by simply passing over the parameters and the module will handle them nicely.
Smart domain recognition mechanism: Mailgun APIs require you to specify the “working domain” on which the operation takes place and this module automatically recognizes the domain you’re working on. For example, when you’re sending a message, the module decomposes the domain in the From address and intelligently matches it to a domain you have in your profile, even if it’s a subdomain.
Built-in HTML support: The Mailgun module utilizes Mailgun’s server-level support for handling HTML messages. This means MIME is no longer your hassle.
Fully extensible: Simply call the mailgungetclient() function and use the client object to perform any operation you want.
The module is available here and you can access the documentation here. Feel free to contribute to the module by helping out in the issue queue. You can also give small donations to help support the development and maintenance of the module.
We hope you find this integration useful and welcome your comments and suggestions.