Skip to main content

Extract spending history from gmail to google sheet

Workflow preview

Workflow preview
100%
Extract spending history from gmail to google sheet preview
Open on n8n.io

Important notice

This workflow is provided as-is. Please review and test before using in production.

1. Workflow Overview

How it works 1. Fetch transaction notification emails (including attachments) 2. Clean up data 3. Let AI (Basic LLM Chain node) generate bookkeeping item 4. Send to Google sheet Details 1. The exam...

Best for

  • Document Extraction automation workflows
  • AI Summarization automation workflows
  • advanced n8n builders looking for reusable templates

Tools used

n8n-nodes-base.gmailtrigger, n8n-nodes-base.extractfromfile, n8n-nodes-base.html, n8n-nodes-base.splitout, @n8n/n8n-nodes-langchain.outputparserstructured, @n8n/n8n-nodes-langchain.lmchatgooglegemini, n8n-nodes-base.googlesheets, n8n-nodes-base.set

Source and attribution

This workflow is cataloged by N8N Workflows and links back to its original n8n.io source page by hana.

Original n8n.io source

1.1 Workflow description

Title
Extract spending history from gmail to google sheet
Workflow name
Extract spending history from gmail to google sheet

How it works

  1. Fetch transaction notification emails (including attachments)
  2. Clean up data
  3. Let AI (Basic LLM Chain node) generate bookkeeping item
  4. Send to Google sheet

Details

  1. The example fetch email from Gmail lables, suggested using filters to automatically orgianize email into the labels
  2. Data will send to "raw data" sheet
  3. Example google sheet: https://docs.google.com/spreadsheets/d/1_IhdHj8bxtsfH2MRqKuU2LzJuzm4DaeKSw46eFcyYts/edit?gid=1617968863#gid=1617968863

1.2 Logical Blocks

This catalog entry is organized from the workflow JSON. The node-level section below shows the executable blocks available for review before importing the template.

2. Block-by-Block Analysis

Block 1 - Get invoice

Type / Role
n8n-nodes-base.gmailTrigger - gmailTrigger
Config choices
Version 1.1

Block 2 - Get payment

Type / Role
n8n-nodes-base.gmailTrigger - gmailTrigger
Config choices
Version 1.1

Block 3 - Extract invoice

Type / Role
n8n-nodes-base.extractFromFile - extractFromFile
Config choices
Version 1

Block 4 - Extract payment

Type / Role
n8n-nodes-base.extractFromFile - extractFromFile
Config choices
Version 1

Block 5 - HTML

Type / Role
n8n-nodes-base.html - html
Config choices
Version 1.2

Block 6 - Split Out

Type / Role
n8n-nodes-base.splitOut - splitOut
Config choices
Version 1

Block 7 - Structured Output Parser1

Type / Role
@n8n/n8n-nodes-langchain.outputParserStructured - outputParserStructured
Config choices
Version 1.2

Block 8 - Google Gemini Chat Model1

Type / Role
@n8n/n8n-nodes-langchain.lmChatGoogleGemini - lmChatGoogleGemini
Config choices
Version 1

Block 9 - Send

Type / Role
n8n-nodes-base.googleSheets - googleSheets
Config choices
Version 4.5

Block 10 - Set data 0

Type / Role
n8n-nodes-base.set - set
Config choices
Version 3.4

Block 11 - Set data 1

Type / Role
n8n-nodes-base.set - set
Config choices
Version 3.4

Block 12 - Set data 2

Type / Role
n8n-nodes-base.set - set
Config choices
Version 3.4

Block 13 - Invoice data

Type / Role
n8n-nodes-base.set - set
Config choices
Version 3.4

Block 14 - Payment data

Type / Role
n8n-nodes-base.set - set
Config choices
Version 3.4

Block 15 - Switch

Type / Role
n8n-nodes-base.switch - switch
Config choices
Version 3.1

Block 16 - Groq Chat Model

Type / Role
@n8n/n8n-nodes-langchain.lmChatGroq - lmChatGroq
Config choices
Version 1

Block 17 - Structured Output Parser

Type / Role
@n8n/n8n-nodes-langchain.outputParserStructured - outputParserStructured
Config choices
Version 1.2

Block 18 - Send1

Type / Role
n8n-nodes-base.googleSheets - googleSheets
Config choices
Version 4.5

Block 19 - Extract details1

Type / Role
@n8n/n8n-nodes-langchain.chainLlm - chainLlm
Config choices
Version 1.4

Block 20 - Merge

Type / Role
n8n-nodes-base.merge - merge
Config choices
Version 3

Block 21 - Extract details

Type / Role
@n8n/n8n-nodes-langchain.chainLlm - chainLlm
Config choices
Version 1.4

Block 22 - Sticky Note

Type / Role
n8n-nodes-base.stickyNote - stickyNote
Config choices
Version 1

Block 23 - Sticky Note1

Type / Role
n8n-nodes-base.stickyNote - stickyNote
Config choices
Version 1

Block 24 - Sticky Note2

Type / Role
n8n-nodes-base.stickyNote - stickyNote
Config choices
Version 1

3. Summary Table

Workflow Extract spending history from gmail to google sheet
Complexity advanced
Nodes 24
Categories Document Extraction, AI Summarization
Author hana
Published 15 Sept 2024

4. Reproducing the Workflow from Scratch

  1. 1. Download the workflow JSON

    Use the JSON export at /data/workflows/2414/2414.json as the source template for this automation.

  2. 2. Import the template into n8n

    Open n8n, import the downloaded JSON, and review each node before activating the workflow.

  3. 3. Configure credentials and variables

    Replace placeholder credentials, API keys, webhook URLs, account IDs, and environment-specific values with your own settings.

  4. 4. Test with sample data

    Run the workflow manually or in a staging workspace, inspect node output, and confirm downstream systems receive the expected data.

  5. 5. Activate and monitor

    Enable the workflow only after testing, then monitor executions, errors, and rate limits during the first production runs.

5. General Notes & Resources

Review imported nodes carefully before activation. This catalog entry is intended to help you inspect the workflow structure, understand required services, and find related templates faster.

Node names, credentials, schedules, webhook paths, and external service limits may need adjustment for your workspace.

Frequently asked questions

What does Extract spending history from gmail to google sheet do?

How it works 1. Fetch transaction notification emails (including attachments) 2. Clean up data 3. Let AI (Basic LLM Chain node) generate bookkeeping item 4. Send to Google sheet Details 1. The exam...

What do I need before importing this workflow?

Review the workflow JSON, configure any required credentials in n8n, and test the automation in a safe workspace before using it in production.

Can I customize this workflow?

Yes. Use the block-by-block analysis and the downloadable JSON to inspect each node, then adjust credentials, prompts, schedules, filters, or destinations for your Document Extraction, AI Summarization use case.