How to forward emails to an Epson printer
September 17, 2016 4:33 PM   Subscribe

I'm running an event. I'd like for guests to be able to email photos to, and for the attachments to be forwarded to an Epson PictureMate PM-400 for immediate printing. The Epson has an email address like If I email that address directly, it prints. So this should be easy, right? Wrong.

It seems the Epson objects to the forward/redirect action of all the email clients I've tested. They rewrite the envelope of the email (apparently by adding X-Forward-To or similar). The To: header still says, which means the Epson silently ignores it. The printer apparently only prints emails whose To: field is

I can think of three workarounds, each with problems. Can you help with any of these problems, or can you suggest an approach I'm missing entirely? Am I overthinking this?!

Difficulty level: I can't give guests the direct email address of the Epson printer (for branding reasons, and because the attachments need to be saved, which I plan to do by forwarding them to, e.g. Flickr). Guests have to be able to print over email: no SMS, no Bluetooth, no AirPrint, no other WiFi solution. I'd love not to get into a mess by installing Dovecot on an EC2 or similar, and I really, really don't want to have to leave a desktop machine running.
  1. find an email service that forwards emails by rewriting the To: field. This rules out at least Gmail, Fastmail, and the Apple Mail client. Can anyone suggest an email service that can be persuaded to work like this? I don't mind paying! I would love to avoid configuring my own server!
  2. find an email service that allows its users to configure a seive script, and supports the editheader extension. That rules out Fastmail, which supports seive, but not the editheader extension. Can anyone suggest an email service that allows like this? I don't mind paying! I would love to avoid configuring my own server!
  3. use a service like IFTTT to monitor a Gmail inbox for attachments, and send new emails. This offends me aesthetically but would work in a pinch. Unfortunately as far as I can tell, the IFTTT Any New Attachment In Inbox trigger simply doesn't work.
posted by caek to Technology (6 answers total)
It's been years since I used it, but maybe procmail can rewrite the headers to make them compatible with the printer?
posted by COD at 5:25 PM on September 17, 2016

If you're willing to write a little bit of code, Amazon SES has an inbound feature that you can have call a Lambda function. You could use that to either pull out the attachment and send it in a new email to Epson, or maybe just re-send the original email with the recipient address changed (I'm not sure off the top of my head if it gives you the original raw message). I'd try to keep the parsing to a minimum to avoid issues with non-standard mime, etc.
posted by primethyme at 5:29 PM on September 17, 2016

This would be super kludgy, and probably also rather slow, but I wonder if this plus this would work?
posted by kickingtheground at 6:42 PM on September 17, 2016

kickingtheground: I had the same idea (see 3), but it seems the new attachment trigger is broken. I've filed a ticket, but like you say, a bit cludgy.

primethyme: I wasn't willing to write code, but I was willing to steal from this. With this walkthrough I now have AWS+Lambda up and running. Unfortunately I'm in the SES sandbox, which means that I can't send email to addresses that I haven't verified. I have no way of reading the body of the verification emails that are being sent to the printer, but even if I could, the URL is ~400 characters long. I've put in a support request to get out of the sandbox. Fingers crossed!
posted by caek at 7:36 PM on September 17, 2016

You can 100% do this with Zapier (and looks like for free based on their current pricing). You'd basically set it up like this: [forwards to] [sends new email to]

The key here is that Zapier will let you configure the last email to the way you want: you'll be able to specify the "from" and "to" email addresses, and you'll be able to pull in the original attachment and send it off as an attachment in the final email.

It will be like a forwarding email chain, but you'll have much more control over the final output.
posted by reeddavid at 8:31 PM on September 17, 2016 [1 favorite]

Zapier works!

AWS lifted the sandbox restriction on my SES account, so I learned a little SES and Lambda, so that wasn't all wasted, but I'm very happy for this to be someone else's problem.
posted by caek at 8:46 AM on September 18, 2016

« Older Accepting flaws in long-term relationships   |   I want to work on the railroad. Newer »
This thread is closed to new comments.