How to Load data from Mandrill to Google BigQuery

How to load data from Mandrill to BigQuery

There’s a continually growing usage of services like Mandrill. Mandrill  is a transactional email API for Mailchimp Users and it is ideal for sending data-driven emails, including targeted and personalized one-to-one messages to your customers. But that traffic creates more data. How can you analyse the data you generate with Mandrill as part of your transactional email campaigns, on BigQuery? This guide is going to provide you with a clear picture about how to load data from Mandrill to Google BigQuery.  Alternatively, you can use products like Blendo that can handle this kind of problems automatically for you.

ETL your Mandrill data into your Data warehouse

We will use Mandrill’s API to access and extract e-mail related data and load it into Google BigQuery for further analysis. You will need to write the code to get the data and make sure that this process will run every time new data are generated.

What is Mandrill?

Mandrill is a transactional email API for Mailchimp Users. Although in the past, Mandrill was perceived as a different product than Mailchimp, right now it is offered as a Mailchimp plugin. Mandrill is reliable, powerful and ideal for sending data-driven emails, including targeted and personalised one-to-one messages to your customers. You might wonder what are the differences between Mandrill and Mailchimp, as both of them handle the delivery of emails to your customers. Some key differences between the two are the following:

  • Mandrill is designed for developers. If you are not comfortable with writing code then it would be better if you find someone before you start using it. On the other hand, Mailchimp is designed mainly for marketeers so no technical skills are required to use it.
  • Mandrill focuses more on transactional e-mails, which are different than the promotional/campaign based emails that marketeers send using Mailchimp. Transactional e-mails are more tailor made for cases like one to one messages to your customers, like resetting passwords, welcoming them etc.
  • Mailchimp offers richer reporting, but with Mandrill it is easier to have access to all the raw events related to your e-mails as they happen, so you can run your own analytics if you wish. In general, raw data from Mandrill are much more accessible than in Mailchimp.
  • If you wish to run complicated campaigns with Mandrill you will have to implement the logic behind running them, with Mailchimp you can do that using the drag-n-drop environment that it offers.
How to load data from Mandrill to Google BigQuery

How to load data from Mandrill to Redshift

In general, you can perceive the two services as complementary, Mailchimp allows your marketing department to easily and fast execute their marketing strategies, while with Mandrill you have access to a very flexible and rich environment where you can build complex products on top of e-mail services, but it requires the involvement of your R&D team.

Mandrill, as an email API, exposes all its functionality through it. So apart from being possible to execute a number of operations like sending emails based on specific events, we can also use this API to pull out data or setup our infrastructure in such a way that Mandrill will send to us data over time they are generated. In this article, we will see in detail the different ways of pulling data from Mandrill that can be useful for running our analytics.

Continue reading