January 5, 201511 yr 1. Does anyone know if there is a way to download all incoming mail? Regardless of Folder/Label. 2. Does the email download include the name of the folder for the message? I couldn't find anything obvious in the documentation, unless I just overlooked it.
January 5, 201511 yr that kind of depends i think - ( not sure about google ) but the INBOX is where all mail comes in but if the user has any other filters on the client machine or manually moves mail to other folders before the script runs you miss them. In one case we had the server setup to forward/copy every ones mailbox to a utility email account that we setup the plugin to ingest, and clear out - that way you don't have to touch end user accounts and deal with their credentials.
January 6, 201511 yr I responded to Joshua through our support system. I'm including my response here for reference: There's no way to directly download all messages. However, you can pull every message from a given mailbox using EmailReadMessages("mailbox=" & $name ; "deleted=any"), and it would be pretty simple to loop through all mailboxes and pull every message from each one. You can get a list of every mailbox using the function EmailListMailboxes( "" ; true ). If you're using Gmail and have messages with multiples labels, this looping process could cause duplicate messages, so watch out for that! For your second question, no, the email data doesn't include any information about the mailbox it's in, but since you need to specify a mailbox to read any messages, you could store this separately for each message.
Create an account or sign in to comment