TrustTheVote-Project / horatio-server

Turns JSON absentee ballot requests into PDFs and delivers them to registrars.
MIT License
1 stars 3 forks source link

How do we deal with bounced emails? #18

Closed waldoj closed 9 years ago

waldoj commented 9 years ago

The prescribed method of delivering applications to registrars is via their email addresses, but looking at them, it's clear that they're not stable. jon.doe@springfield.gov is only valid as long as Jon Doe remains the registrar of Springfield.

waldoj commented 9 years ago

Seems like it's best to use a transactional email service for this, because bounced emails will be a big deal. (Because somebody believes that they're going to get a ballot in the mail, but they will not.) SendGrid, Mailgun, Mandrill, and Postmark are reputedly all good options, although I've never worked with any. (A strike against Mailgun for not using HTTPS by default.) SendGrid, Mailgun, and Postmark will all POST notifications back to APIs when a bounce occurs, and that seems like the proper approach. (Better than polling periodically to find out if there have been any bounces—we want to know immediately.) All three provide the email address that's bouncing, which is really all that we need.