Results 1 to 6 of 6

Thread: Extract and Save Attachment on Inbound Email Address

  1. #1
    Join Date
    Sep 2008
    Location
    Princeton, NJ
    Posts
    81
    Rep Power
    7

    Default Extract and Save Attachment on Inbound Email Address

    I have an eFax service that sends faxes via email to a specific account. The faxes come in as PDF.

    In using Zimbra ZCS 5.0.23 in RHEL5, how could I extract and save those attachments to a folder on the zimbra server AUTOMATICALLY?

    For example, inbound fax comes as a PDF attachment in an email. The email address it comes to is inbound_fax@mydomain.com. I would like to process this email as it comes in and save the PDF attachment to /home/inbound_fax/inbox.

    Please let me know how you would accomplish something like this.
    Thanks!

  2. #2
    Join Date
    Sep 2008
    Location
    Princeton, NJ
    Posts
    81
    Rep Power
    7

    Default

    I am surprised that this has not garnered any suggestions. Let me ask the question this way.... if I had regular emails that I wanted to auto-feed let's say to a website for consolidated viewing - how could I do that?

    Email comes in -> program runs that reads email -> function is run to process the email (i.e., post log to admin portion of a company portal).

    I am looking for any suggestions on how to auto-process an email as input for a program on a Linux box (when Zimbra is the mail server.)

    Please help!

  3. #3
    Join Date
    Sep 2008
    Location
    Latvia
    Posts
    165
    Rep Power
    7

    Default

    I am following your thread, but the silence in this basically can mean, that there are no ready solutions to be shared by this forum users. Some time ago I was experiencing the same situation, only mail system was Lotus Notes Domino. And we ended up with custom script development inside Domino database.

    For now, I see several posibilities to achieve this. But none of them are built into ZCS. And main functionality of this system all together would depend on Fax server software functionality too.

    1.variant - Zimbra Zimlets.
    I have not developed any of them, but upon reading some documentation, I guess it can be possible to write your own custom zimlet to do filtering and attachment deattaching from e-mails. But I can not advice any more on this issue.

    2.variant - use of external application.
    Write your own application on language you like more (php, ruby, shell script, java, etc. - not specific one). Use IMAP or POP available libraries and add functionality of local system mailbox and scripting to deattach file proportion of an e-mail message and save it to local/network disk.

    I might be wrong, but I guess, that most Fax server software are capable of sending fax attachments (PDF) in emails to specific e-mail address and/or using specific SMTP server. Which in turn can be configured to redirect specific messages (from/to) to local mailbox and not go to Zimbra. The other service of such servers are possibility to store received faxes locally/on network drive, thus eliminating Zimbra inclusion in this chain of processes. Afterwards is just a question on how you operate with such files later.

    In day to day job I use Drupal CMS (PHP based) and there are several modules implementing IMAP/POP connections to mail servers. In my case I would use this system to get e-mails of specific folder/account with fax attachments and populate records of this CMS. Additionally you can set up search, workflows and forwarding of such records. I mean it is something like local intranet application, which requires no licencing and can be modified as needed.

    Sorry for not giving direct answers. Hope this info can help.

  4. #4
    Join Date
    Mar 2010
    Location
    GREECE
    Posts
    16
    Rep Power
    5

    Default

    Hello,
    sorry for re-opening this thread after 2+ years, but I have the same problem too,

    I have an application that loads xml files and transforms them to our ERP database system.
    Those xml files are sent by our external clients or co-workers, and sometimes in after hours (late at evening, 24x7 etc)
    I'm searhcing for an option / script that does the following

    from a specific email account (let's say user1@mydomain.com) when an email arrives with a specific attachment type (eg. xml, or pdf as you asked), let zimbra to "detach" that attachment, and put it to a specific os folder eg. /opt/zimbra/attachments
    Then with a linux daemon I can "load it" to my custom application, or do whatever action I want ... (copy, ssh, ftp .. etc)

    I thing is somehow the same as "the_griz" asked for ....

    So anyone has found any solution or workaround ??

    Thanks
    pkar

  5. #5
    Join Date
    Jun 2006
    Location
    Italy
    Posts
    56
    Rep Power
    9

    Default

    You can mount the "attachment" folder through the webdav protocol and there you can find files organized by "sender", "date" and "type".
    Does it work for you?
    Stefano Pampaloni
    www.seacom.it

  6. #6
    Join Date
    Mar 2010
    Location
    GREECE
    Posts
    16
    Rep Power
    5

    Default

    Hi Stefano,
    I'm not a programmer, (I had to give it to outsource team), but I guess it will be ok ...
    Is there any how-to, about the procedure you proposed, in order to check / do a test ?

    Thanks
    Panagiotis

Similar Threads

  1. Extract Attachment to samba folder
    By jubacca in forum Administrators
    Replies: 2
    Last Post: 08-01-2009, 01:00 AM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •