I created an automation that streamlines the process of uploading attachments from your Gmail inbox directly to Google Drive. This guide walks you through the steps to set up this automation using Make.com, ensuring you only upload the files you need.
Overview of the Automation
I created an automation that watches for new emails in my Gmail inbox that contain attachments. When it detects such an email, it uploads those attachments to a designated Google Drive folder. This setup ensures I only keep the files I need while keeping my inbox organized.
The system can be tailored to only upload specific file types. For instance, I can set it to only process PDF files. Additionally, I can manually assign emails to be picked up by this automation by moving them into a specific folder, even if they don’t initially contain the keyword “invoice.” This flexibility makes it a powerful tool for managing important documents.
Getting Started with Make.com
To begin, I accessed Make.com and started with a blank scenario. The first step is to type in “Gmail” and select the option to watch emails. This sets up the foundation for the automation process. The interface is user-friendly, making it simple to get started.
Once I clicked the add button to set up a new connection, a pop-up appeared prompting me to allow access. If you’re using a personal Google account, the setup may be a bit more complicated, but there are guides available online to help.
Setting Up Gmail Connection
After establishing the connection, I selected my inbox as the starting point. I then entered specific Gmail filters to narrow down the emails to be processed. The search feature in Gmail allows for precise criteria, which I found very useful.
Creating Specific Gmail Filters
To filter the emails, I decided to focus on those containing the word “invoice” in either the subject or the body. Additionally, I specified that the email must have an attachment and that the file name of the attachment should be a PDF. This ensures that only relevant emails are picked up by the automation.
Moreover, I wanted the option to manually assign emails to be processed. This means that even if an email doesn’t have “invoice” in its subject, as long as it has an attachment named PDF, I can move it to a designated folder, and the automation will pick it up.
Once I set the filters, I decided to only process new emails moving forward. This choice prevents the automation from retrieving thousands of old emails, which is a common concern when setting up such systems.
Uploading Attachments to Google Drive
Next, I focused on transferring these attachments to Google Drive. I selected the option to upload a file, and I noticed a list of attachments in an array format. This is due to the possibility of having multiple attachments in a single email.
To handle multiple attachments, I used an iterator. This tool allows the automation to process each attachment individually, which simplifies the process significantly. I chose the attachments as the array to iterate through.
Then, I selected the specific Google Drive folder where I wanted the files to be uploaded. This step ensures that all relevant documents are stored in one easy-to-access location.
After saving the configuration, I specified that the automation should start from the present moment. This ensures that only new emails are processed going forward.
To test the automation, I sent myself an email with an attachment labeled “invoice” and a PDF file. Running the scenario successfully uploaded the file to Google Drive, confirming that everything was set up correctly.
Additionally, I added a filter to ensure that only PDF documents are uploaded. This extra step guarantees that irrelevant file types are excluded from the automation process.
This automation not only saves time but also keeps my documents organized. If I want to expand on this system, there are options for processing the files further after they are uploaded to Google Drive, such as extracting data and adding it to a Google Sheet.
Using an Iterator for Multiple Attachments
I created an automation that can handle multiple attachments in a single email. When I set up the process, I noticed that the attachments are presented in an array format. This structure is essential because it allows the automation to process each attachment individually.
To achieve this, I utilized an iterator. This tool simplifies the workflow by enabling the automation to loop through each attachment one at a time. Selecting the iterator and then specifying the attachments as the array to iterate through ensures that every file gets processed correctly.
Testing the Automation
After setting everything up, testing the automation is crucial. I sent myself a test email containing a PDF attachment labeled “invoice.” Running the scenario confirmed that the automation worked as intended, successfully uploading the file to Google Drive.
It’s important to verify that the automation picks up only the emails that meet the specified criteria. By observing the Google Drive folder, I confirmed that the right files were being uploaded. This testing phase ensures that the entire setup functions smoothly before relying on it for regular use.
Filtering for PDF File Types
To maintain organization and efficiency, I added a filter to ensure that only PDF documents are uploaded. This step is vital because it prevents irrelevant file types from cluttering the Google Drive folder.
The filter is set to check the file type and only allow those that equal “application/pdf.” This way, I can be confident that every attachment processed will be a PDF, which is often necessary for documentation purposes.
Advanced Workflows and Additional Resources
Once the basic automation is in place, there are numerous ways to expand its capabilities. For example, I can set up additional actions after the files are uploaded to Google Drive. One option is to extract data from the PDFs and add it to a Google Sheet, streamlining data management.