Skip to main content

Parse Google Drive documents to RAG-ready Markdown with Landing.ai and Supabase cache

Workflow preview

Workflow preview
100%
Parse Google Drive documents to RAG-ready Markdown with Landing.ai and Supabase cache preview
Open on n8n.io

1. Workflow Overview

Make your unstructured large documents LLM ready markdown using LandingAI Document Parsing. Automatically watches a Google Drive folder, submits new documents to Landing.ai for parsing, caches proc...

Best for

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

Tools used

n8n-nodes-base.googledrivetrigger, n8n-nodes-base.googledrive, n8n-nodes-base.code, n8n-nodes-base.supabase, n8n-nodes-base.if, n8n-nodes-base.httprequest, n8n-nodes-base.merge, n8n-nodes-base.stickynote

Source and attribution

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

Original n8n.io source

1.1 Workflow description

Title
Parse Google Drive documents to RAG-ready Markdown with Landing.ai and Supabase cache
Workflow name
Parse Google Drive documents to RAG-ready Markdown with Landing.ai and Supabase cache

Make your unstructured large documents LLM ready markdown using LandingAI Document Parsing.

  • Automatically watches a Google Drive folder, submits new documents to Landing.ai for parsing, caches processed files in - Supabase to avoid reprocessing, and reliably polls results with retry and timeout handling.

Use Cases

  • Automated document ingestion for RAG pipelines
  • Invoice, contract, or report parsing
  • AI-powered document analysis workflows
  • Knowledge base ingestion from Google Drive
  • Preventing duplicate document processing in ETL pipelines

External services:

  • Google Drive
  • Landing.ai
  • Supabase

Credentials Required

Required

  • Google Drive OAuth2
  • Landing.ai API (HTTP Bearer Token)
  • Supabase API

How it works

Once the pdf land in google drive location it trigger and it convert pdf (even more then 200 pages to LLM ready markdown). It also check in database if the parsing is already done or not, this help to avoid any unnecessary landingAI api call.

Setup Instructions

Step 1: Google Drive

  1. Create or select a folder in Google Drive
  2. Copy the folder ID
  3. Update the Google Drive Trigger node with this folder ID

Step 2: Landing.ai

  1. Create a Landing.ai account
  2. Generate an API key
  3. Add it in n8n as an HTTP Bearer Auth credential
  4. Update the organization-id header if required

Step 3: Supabase

  1. Create a Supabase project
  2. Create a table named landing_parse_cache
  3. Add fields such as:
  • file_id
  • document_name
  • mime_type
  • file_size_bytes
  • job_id
  • job_status
  • markdown
  • uploaded_at
  • workflow_run_id
  1. Connect Supabase credentials in n8n

Expected Input

  • A document uploaded into the configured Google Drive folder (PDF, DOCX, or other supported formats)

Expected Output

  • Parsed markdown content stored in Supabase
  • Metadata including:
  • File ID
  • File name
  • MIME type
  • File size
  • Job ID
  • Processing status
  • Early exit if the document already exists in cache

Error Handling & Edge Cases

  • Cache check to prevent duplicate processing
  • Retry-based polling for async job completion
  • Timeout detection for stuck jobs
  • Large file output URL handling
  • Detailed logging for debugging and audits

Customization Ideas

  • Push parsed output to a vector database
  • Trigger Slack or email notifications
  • Store results in cloud storage (S3, GCS)
  • Extend into a RAG or AI agent pipeline

Categories

  • Document Processing
  • AI & LLM
  • Knowledge Management
  • Automation

Difficulty Level

Advanced


Happy Automating - from Alok

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 - Google Drive Trigger

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

Block 2 - Download File

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

Block 3 - Build Metadata

Type / Role
n8n-nodes-base.code - code
Config choices
Version 2

Block 4 - Check Cache

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

Block 5 - Debug Cache Results

Type / Role
n8n-nodes-base.code - code
Config choices
Version 2

Block 6 - If Cache Exists

Type / Role
n8n-nodes-base.if - if
Config choices
Version 2

Block 7 - STOP — Cached

Type / Role
n8n-nodes-base.code - code
Config choices
Version 2

Block 8 - Submit to Landing.ai

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

Block 9 - Merge Metadata + Job

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

Block 10 - Init Loop State

Type / Role
n8n-nodes-base.code - code
Config choices
Version 2

Block 11 - Poll Job Status

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

Block 12 - If Completed

Type / Role
n8n-nodes-base.if - if
Config choices
Version 2

Block 13 - If Timeout

Type / Role
n8n-nodes-base.if - if
Config choices
Version 2

Block 14 - Save Parse Result

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

Block 15 - Log Timeout

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

Block 16 - STOP — Success

Type / Role
n8n-nodes-base.code - code
Config choices
Version 2

Block 17 - STOP — Timeout

Type / Role
n8n-nodes-base.code - code
Config choices
Version 2

Block 18 - check-large-file

Type / Role
n8n-nodes-base.if - if
Config choices
Version 2.3

Block 19 - HTTP Request1

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

Block 20 - Sticky Note

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

Block 21 - wait till interval set time

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

Block 22 - Sticky Note1

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

Block 23 - Sticky Note2

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

Block 24 - Sticky Note3

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

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

3. Summary Table

Workflow Parse Google Drive documents to RAG-ready Markdown with Landing.ai and Supabase cache
Complexity advanced
Nodes 26
Categories Document Extraction, AI RAG
Author Alok Kumar
Published 06 Feb 2026

4. Reproducing the Workflow from Scratch

  1. 1. Download the workflow JSON

    Use the JSON export at /data/workflows/13244/13244.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 Parse Google Drive documents to RAG-ready Markdown with Landing.ai and Supabase cache do?

Make your unstructured large documents LLM ready markdown using LandingAI Document Parsing. Automatically watches a Google Drive folder, submits new documents to Landing.ai for parsing, caches proc...

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 RAG use case.