Monitor Google Drive and Automatically Update Google Sheets with AI
Workflow Description
An intelligent automation that watches a Google Drive folder, processes new and modified files through Gemini AI to extract key data, and seamlessly populates Google Sheets while storing records in Postgres for audit trails and advanced analytics.
How it works
- 1.Set up Google Drive monitoring to detect new or updated files
- 2.Process content through Gemini AI agent to identify and extract relevant data
- 3.Insert extracted data into Google Sheets and persist records in Postgres database
Use cases
- Automatically organize incoming documents and index project data across teams
- Consolidate invoices, reports, and forms into a single structured spreadsheet
Requirements
- Active Google account with full access permissions to Drive and Sheets
- Configured Postgres database with active connection credentials
Service Value
Ideal as a smart automation service combining integrations and AI to produce ready-to-use results.
Apps Used
Details
How to Use
- 1.Click "Download Template"
- 2.Open your n8n dashboard
- 3.Go to Workflows > Import from File
- 4.Select downloaded file and configure credentials
Nodes Used (23)
create table query
Code
create insertion query
Code
Google Drive Trigger
Google Drive Trigger
execute_query_tool
Tool Workflow
Google Gemini Chat Model
Gemini Model
get_postgres_schema
Tool Workflow
change_this
Set
is not in database
If
table exists?
Postgres
fetch sheet data
Google Sheets
remove table
Postgres
create table
Postgres
perform insertion
Postgres
Execute Workflow Trigger
Execute Workflow Trigger
Sticky Note
Sticky Note
Sticky Note1
Sticky Note
When chat message received
Manual Chat Trigger
response output
Set
sql query executor
Postgres
schema finder
Postgres
schema to string
Code
AI Agent With SQL Query Prompt
Agent
Sticky Note2
Sticky Note