The Idea: A technology association needed a system to provide an email forwarding service. Email sent to members at the association's domain would be forwarded to their personal email address. The catch was that the association did not want to configure a forwarding service every time a member joined or left. Members also needed a dead-simple way to manage their own forwarding preferences.
The first step in the process was to normalize the inbound messages. Rather than trying to account for all possible encodings, I turned to my trusty friend, Integromat.com. Their MailHook tool allowed me to accept all messages sent to the client domain and reliably extract the pieces I needed: sender, recipient, subject, and HTML and text parts of the message. This stripped-down data is then posted to an endpoint on the client's website, which is run by WordPress.
All messages sent to the association's domain are processed by MailGun, an Email Service Provider who offers a free tier that perfectly meets our needs. I set up custom routing at MailGun so that any messages sent to [email protected] are forwarded to the association's free Gmail address and all other messages are forwarded to Integromat for parsing and re-posting to the client website.
As a bonus, I configured the free Gmail address to send as [email protected]—the public never sees the association's Gmail address.
The original message parts are repackaged and forwarded to an endpoint on association's WordPress site. I custom-built a plugin that listens for the processed data coming from Integromat, looks up the real-world email address associated with the original recipient address, and forwards the message body to the member's email address. The outbound messages are sent from the address [email protected] using MailGun's SMTP server to maximize deliverability and member trust of the message.
The awesome part here is that we're using native WordPress functionality to mange user creation and profile management. We don't require members to use a third-party tool to manage their forwarding preferences; it just works.
Total monthly recurring cost for up to 300 inbound member emails: $0. For 3000 member emails: $9.