I have a customer form which they fill in their details they want in a printed object. That form sends an email to us. I would like to extract the data from that email so it can go through the datamapper and trigger a printjob.
I have been looking at the Email input plugin in Workflow, and trying to figure out how to capture that content and send it to the datamapper and Connect template. As far as I can see, the email is made into a dat file? There wasn’t much information in the help file.
The Email Input task loops through the content of the emails it captures: it first processes the body of the email (whose text content is saved as a .DAT file), then it processes each attachment (you can disable that option). In a sense, it works just like a Folder Capture task, which loops through the contents of a folder.
Note that when Workflow calls the Execute Data mapping task, it not only passes the current job file to the Connect DataMapper but also its JobInfos, which contain important information like the Sender’s email address, the subject, etc.
Excuse me for being a Noob, but how do I set up the datamapper to work with the dat file? The email arrives in html format so would the dat file be in principle just a html text file? I’ve only worked with csv files previously.
The .DAT contains the text content of the email message, without any of the formatting, so it’s just a plain text file. You can validate that by opening it in Notepad.
To create a data mapping config for it, select File | New Data Mapping Config | Files | Text File.