Looks like no one’s replied in a while. To start the conversation again, simply ask a new question.

Upload received emails to FTP with AppleScript and Mail app

Hi,


I need to upload every incoming email (from one specified mailbox) to FTP. I need attachments to be uploaded too. And the uploaded email should be openable to everyone who open the link.


Any ideas?

Mac Pro, OS X Yosemite (10.10.1)

Posted on Jan 29, 2015 8:30 AM

Reply
4 replies

Jan 29, 2015 3:49 PM in response to Adrian Iwaniuk

Need way more details before anyone can provide a solution here - at least anything more than just hints.


For one, uploads require a file name. How are you planning to determine file names for the uploaded messages?

What about format? Do you need to save the email as PDF? or some other format?

Do you need to associate uploaded files with their corresponding email? How do you plan to do that? (hint: if you don't you'll end up with a bucket full of files with little (or no) obvious way to know which message they relate to)

How do you plan to deal with namespace conflicts (e.g. two attachments of the same name)


The security element is irrelevant - that's up to your FTP server and nothing to do with the upload process.


Before you go too much further, though, I recommend you consider your reason for this. Why are you doing this? Is it just to make the messages (and attachments) available to a group of people? if that's the case why not just create a shared IMAP account on the mail server? that way everyone can see incoming messages, and they're searchable via everyone's (familiar) email client of choice. It also requires almost zero setup and maintenance.

Jan 29, 2015 4:26 PM in response to Camelot

File name could be the [(sender) - (email subject)]


Could be saved as a PDF or a html.


Files (email attachments) need to be associated with corresponding email.


I think that each email could be added to new folder (created for this specified email), the folder name could be same as file name - sender and subject.


I'm doing this to share emails with a group of people. I could make a password requirement but I'm not sure if this is necesarry, because the emails don't include any confidential data.

Feb 9, 2016 7:29 AM in response to Adrian Iwaniuk

I think that most people would find the outline of your requirements sketchy, to say the least ! I know I do 😕

You seem to want someone to write some upload code for you, when you haven't really thought it through yourself.

Are you a programmer ? Have you tried anything ? What have you tried ?

Camelot asked some very pertinent questions to which yo supply vague answers, such as :

Question : "Do you need to associate uploaded files with their corresponding email? How do you plan to do that?"

Answer : "Files (email attachments) need to be associated with corresponding email."

The important thing here was the "How do you plan to do that?"

You need to think this through properly, before anyone will be able to help.

Upload received emails to FTP with AppleScript and Mail app

Welcome to Apple Support Community
A forum where Apple customers help each other with their products. Get started with your Apple ID.