Developers who are creating a (mobile) application will face an important decision: Do you build your own email delivery solution or do you use an email service provider?
Setting up and deploying an email delivery system for their applications is something Most developers are not experienced at.
Baseline requirements for an mobile application email delivery solution:
1. A method of constructing IETF standard email messages
2. Reliable delivery of the email into the inboxes of all your users
3. Reporting and Diagnostics on transmission errors and delivery status
4. Colecting engagement data and reporting them, such as email open and click rates
There are also other considerations to take into account:
• Does your team have the expertise to setup and maintain an email server?
• Is there any training needed related to your email platform?
• Do you have time to fix issues when building and maintaining your own email solution?
• Do you want the responsibility that comes with running an email server?
Let’s compare the required resources to build your own e-mail solution versus using an email service provider. In this example, we will be using Postfix as a representative email server, typical of what a developer would use.
Summary: Experienced developers can get Postfix up and running in 1 to 4 hours. But then it would still miss some features that are considered standard with an Email service Provider..
Let’s look at the number of steps required to get a barebones Postfix server up, compared with using an email service provider.
|Setting Up An Email Server||Using An Email Provider|
|Rent a server.
You’re going to need a hosting solution to host your mail server, you can skip this step if you already have a server ready to go.
|Sign up for an account
With the ESP
Sign up for the account that fits your email sending needs.
This can be as simple as doing sudo apt-get install postfix or as difficult as compiling it for your kernel. If those words mean anything to you, you might even be able to pull it off 😉
You will have to at least configure the domain name for outbound mail, what clients to relay from, and delivery method.
|Install DKIM signing.
Most mail providers like Yahoo! or Hotmail prefer that you have DKIM signatures for your senders. While it is not an absolutely vital step, it still is advised to improve deliverability.
|Install DKIM onto DNS records.
Similar to the build side, DKIM is important to your deliverability. The DKIM should be given by the email service provider to you to add to your DNS records.
|Set SPF records.
SPF records are not exactly part of the Postfix setup process, but setting them also improves deliverability.
|Set SPF records.
Vital for any email activities. Along with DKIM, increases chance of delivery.
|Tune for performance and debug.
Postfix has a great many number of fine tuning options at its disposal. Postfix also has many number of strategies for debugging issues that may occur.
Maintaining Postfix is apparently quite easy, all you have to do is monitor the logs for any fatal errors, and use the debugging strategies should anything occur.
|Find an email library that works with your language or framework.
This step has the chance of being easiest, or the most annoying ever. You’ll have to find an email construction library for your particular language or framework that can properly construct email and passes it onto your SMTP server.
|Find / write an API plugin / library / wrapper.
Choose from one the plugins available or write your own JSON-wrapper for the API.
|Integrate library into app.
With the library we found, we start simply writing all of the emails that would get triggered within the app during user-driven events.
|Integrate plugin / library / wrapper into your app.
Get the app to start making API calls, and your emails will be sent.
Experienced developers can get Postfix up and running in 1 to 4 hours. Postfix will then deliver any properly constructed email, however getting the challenge may lie into getting these emails out of your email framework. Extra time is needed to implement monitor the delivery status and engagement data (email reporting).
Some other features might also be missing:
• Easy to use email templates for non-technical people to edit and deploy
• Processing and queuing for bulk email
• Whitelisting of IP addresses
• Applying for preferred sender status at various ISPs
• Blacklist monitoring
The decision build versus buy for an email solution for your mobile application is not only the work that goes into building an email server. Email delivery monitoring and analytics/ reporting for emails requires a lot more research and development time that could have gone into your application!
This is a guestpost ofJon Lim of Postage App. Thanks for giving us some insight into the E-mail for mobile apps world Jon!