10
Step 1 Open the Google Spreadsheet titled Send to Google Drive. Save Gmail Attachments to Google Drive Digital Inspiration www.labnol.org Page 1

Save Gmail Attachments to Google Drive

Embed Size (px)

DESCRIPTION

Download your Gmail attachments to Google drive. Available for Gmail and Google Apps accounts. Link: http://labnol.org/?p=21236

Citation preview

Page 1: Save Gmail Attachments to Google Drive

Step 1Open the Google Spreadsheet titled Send to Google Drive.

Save Gmail Attachments to Google Drive

Digital Inspiration www.labnol.org Page 1

Page 2: Save Gmail Attachments to Google Drive

Step 2Enter the names of one or more Gmail Labels in cell D4. The script will monitor Gmail messagesunder these label and any attachments included in these message will get saved to your GoogleDrive.

If you wish to save attachments from all Gmail messages, irrespective of the label name, just put allin cell D4.

You can multiple labels separated by a comma. For instance, if you wish to extract mails from labelsInbox, Sent Items and the Starred items in Gmail, put inbox, starred, sent in the cell.

It supports nested labels too though the syntax is a bit different. If the label's name is SubLabelunder ParentLabel, you need to put it as ParentLabel-SubLabel (notice the hyphen)

Save Gmail Attachments to Google Drive

Digital Inspiration www.labnol.org Page 2

Page 3: Save Gmail Attachments to Google Drive

Step 3Enter the names of the Google Drive folder in cell D5. The script will automatically save Gmailattachments under a subfolder of this folder.

The subfolder's name will be the domain name from where that message was received. Theattachments saved in the Google Drive are also marked with the GMail Message ID making it easierfor you know where that message came from.

Save Gmail Attachments to Google Drive

Digital Inspiration www.labnol.org Page 3

Page 4: Save Gmail Attachments to Google Drive

Step 4Enter the names of a Gmail Label in cell D6 that will be used to mark processed messages.

When the script has saved attachments from a particular message, it will mark those messages withthis particular label to exclude that message from the queue forever.

Save Gmail Attachments to Google Drive

Digital Inspiration www.labnol.org Page 4

Page 5: Save Gmail Attachments to Google Drive

Step 5Now we need to authorize the program. Go the Gmail Attachments menu in the Google Sheet andchoose Authorize.

Save Gmail Attachments to Google Drive

Digital Inspiration www.labnol.org Page 5

Page 6: Save Gmail Attachments to Google Drive

Step 5b:Click OK at the Authorization Required dialog.

Save Gmail Attachments to Google Drive

Digital Inspiration www.labnol.org Page 6

Page 7: Save Gmail Attachments to Google Drive

Step 5cClick Accept at the Permissions screen. The script needs permissions to read your Gmail inbox andsave attachments in your Google Drive. Everything is running inside your own Google Drive and NOONE ELSE has access to any of your Gmail or Google Drive, including the developer of thisprogram.

Save Gmail Attachments to Google Drive

Digital Inspiration www.labnol.org Page 7

Page 8: Save Gmail Attachments to Google Drive

Step 6Now that the program is authorized, we need to run. Go to the Gmail Attachments menu again andchoose Run Program.

Save Gmail Attachments to Google Drive

Digital Inspiration www.labnol.org Page 8

Page 9: Save Gmail Attachments to Google Drive

Step 7The program is now running and will save attachments from Gmail to Google Drive at regularintervals (every 5 minutes). You can close the Google Sheet and open Google Drive to monitorincoming files.

Save Gmail Attachments to Google Drive

Digital Inspiration www.labnol.org Page 9

Page 10: Save Gmail Attachments to Google Drive

Support & ResourcesThe Save Attachments to Google Drive program was written by Amit Agarwal of Digital Inspiration. Itis available in both free and premium versions.

Free: The free version is however limited to a single Gmail label and does not save attachments insub-folders.

Premium: The premium version supports Nested Labels, you can monitor messages in multipleGmail Labels and it saves attachments in subfolder thus keeping your Google Drive betterorganized.

• Tutorial: Save Attachments to Google Drive• Email: [email protected]• Twitter: @labnol• See more Google Apps Script Projects

Save Gmail Attachments to Google Drive

Digital Inspiration www.labnol.org Page 10