Skip to main content

Extract timesheet data with Mistral OCR & Gmail human verification

Workflow preview

Workflow preview
100%
Extract timesheet data with Mistral OCR & Gmail human verification preview
Open on n8n.io

Important notice

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

1. Workflow Overview

Description How it works This workflow introduces an AI + Human in the Loop pipeline for employee timesheet management. It combines the power of Google Drive, AI (OCR + LLM), and Gmail with a...

Best for

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

Tools used

n8n-nodes-base.manualtrigger, n8n-nodes-base.splitinbatches, n8n-nodes-base.spreadsheetfile, @n8n/n8n-nodes-langchain.lmchatmistralcloud, n8n-nodes-base.googledrive, n8n-nodes-base.set, n8n-nodes-base.switch, n8n-nodes-base.gmail

Source and attribution

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

Original n8n.io source

1.1 Workflow description

Title
Extract timesheet data with Mistral OCR & Gmail human verification
Workflow name
Extract timesheet data with Mistral OCR & Gmail human verification

📖 Description

🔹 How it works

This workflow introduces an AI + Human-in-the-Loop pipeline for employee timesheet management. It combines the power of Google Drive, AI (OCR + LLM), and Gmail with a human review step to ensure accuracy and compliance.

  1. AI-Powered File Discovery

    • Scans a Google Drive folder for new or updated timesheet files (PDF, Word, Excel, Images).
  2. AI Data Extraction

    • Uses OCR and LLM (Mistral) to intelligently read and extract structured data.
    • Supports multiple formats: PDF, Word (DOC/DOCX), Excel (XLS/XLSX), and Image files (JPG, PNG, scanned documents).
    • Creates clean JSON with file details and timesheet logs (date, hours worked, tasks, notes).
  3. Smart Data Formatting

    • Converts AI output into a clear HTML summary table for easy review.
    • Flags potential anomalies (missing hours, duplicate dates, irregular entries).
  4. Human-in-the-Loop Verification

    • Sends an approval email via Gmail containing:
      • File metadata
      • AI-generated HTML summary
      • JSON attachment of raw extracted data
    • HR/Managers review the summary and approve/reject before final actions occur.
  5. Post-Approval Automation (optional)

    • Approved records can be saved in a separate Google Drive folder.
    • Employees or HR receive confirmation emails.

⚙️ Set up steps

  1. Connect Credentials

    • Add Google Drive and Gmail credentials in n8n.
    • Configure Mistral (or any LLM) API credentials.
  2. Configure Google Drive

    • In the “Search files and folders” node, replace the folderId with your company’s timesheet folder ID.
  3. Customize Extraction Schema

    • Sticky notes explain how JSON output is structured.
    • Adapt it for your organization’s needs (e.g., overtime, project codes).
  4. Set Up Human Verification Emails

    • Update Gmail node recipients to your HR or approval team.
    • Customize the email body (AI summary + JSON file attached).
  5. Activate & Test

    • Enable the workflow.
    • Upload a sample timesheet to trigger the AI + human verification loop.

⚡ Result: A robust AI + Human-in-the-Loop workflow that reduces repetitive data entry, prevents payroll errors, and gives HR full confidence before final approval.

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 - When clicking ‘Test workflow’

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

Block 2 - Loop Over Items2

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

Block 3 - Read Spreadsheet File

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

Block 4 - Mistral Cloud Chat Model2

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

Block 5 - Download File

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

Block 6 - Set File ID1

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

Block 7 - Search files and folders

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

Block 8 - Switch File Type

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

Block 9 - Send a message

Type / Role
n8n-nodes-base.gmail - gmail
Config choices
Version 2.1

Block 10 - HTTP Request1

Type / Role
n8n-nodes-base.httpRequest - httpRequest
Config choices
Version 4.2

Block 11 - Edit Fields3

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

Block 12 - Mistral Upload

Type / Role
n8n-nodes-base.httpRequest - httpRequest
Config choices
Version 4.2

Block 13 - Mistral Signed URL

Type / Role
n8n-nodes-base.httpRequest - httpRequest
Config choices
Version 4.2

Block 14 - Mistral DOC OCR

Type / Role
n8n-nodes-base.httpRequest - httpRequest
Config choices
Version 4.2

Block 15 - Aggregate

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

Block 16 - Upload file

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

Block 17 - Sticky Note

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

Block 18 - Sticky Note1

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

Block 19 - Sticky Note2

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

Block 20 - Sticky Note3

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

Block 21 - Sticky Note4

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

Block 22 - Sticky Note5

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

Block 23 - Sticky Note6

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

Block 24 - Sticky Note7

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

Showing the first 24 of 32 workflow blocks. Download the JSON for the full node graph.

3. Summary Table

Workflow Extract timesheet data with Mistral OCR & Gmail human verification
Complexity advanced
Nodes 32
Categories Document Extraction, AI Summarization
Author ResilNext
Published 20 Sept 2025

4. Reproducing the Workflow from Scratch

  1. 1. Download the workflow JSON

    Use the JSON export at /data/workflows/8767/8767.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 timesheet data with Mistral OCR & Gmail human verification do?

Description How it works This workflow introduces an AI + Human in the Loop pipeline for employee timesheet management. It combines the power of Google Drive, AI (OCR + LLM), and Gmail with a...

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.