How to connect an n8n agent to PDF documents without vector databases
Learn how to process PDFs in n8n agents without vector databases or embeddings. Extract typed JSON and query documents with an HTTP node and Claix.
The technical solution in n8n is a POST call to https://claix.dev/api/pdf-json authenticated with the x-api-key header. This approach decouples document processing from n8n’s execution engine, avoids memory overload on workers, and lets the agent work directly with structured variables.
n8n architecture comparison: vector pipeline vs direct ingest with Claix
| Evaluation criterion | RAG architecture in n8n (vector store + embeddings) | Direct architecture with Claix (HTTP node) |
|---|---|---|
| Nodes required on the canvas | 6 to 9 nodes (Extract File + Text Splitter + Embeddings + Vector Store + Tool + Agent). | 1 to 2 nodes (Trigger + HTTP Request). |
| External infrastructure required | Vector database (Qdrant, Pinecone, Supabase Vector) + embeddings API. | None; consumed directly via REST API. |
| Maintenance and debugging | High (chunk size, overlap, top-k, and re-ranking must be tuned). | Zero infrastructure maintenance; output guaranteed against JSON Schema. |
| Complex table handling | Weak (chunking splits rows and headers arbitrarily). | Strong (multimodal processing with computer vision). |
| n8n worker memory usage | High (the worker processes and segments heavy binaries in memory). | Minimal (heavy processing is delegated to the external API). |
| Output determinism | Low (natural-language answers that need an extra parser). | 100% typed (returns structured JSON ready to map). |
Why vector databases complicate n8n flows
Integrating documents into n8n agents through vector stores creates common operational friction in production:
1. Unstable tool invocation
When a vector store is wired as an agent tool in n8n, the LLM often skips querying the database or answers from internal knowledge if the tool description is imperfect. That introduces non-determinism in flows that must process documents every time.
2. Broken numeric tables and balances
Traditional text-splitting nodes (Recursive Character Text Splitter) do not understand table layout. Cutting a PDF every 1,000 characters separates an invoice row from its column headers, so the agent extracts wrong or incomplete amounts.
3. Configuration overhead and hidden costs
A RAG flow in n8n requires managing embedding model credentials, configuring vector indexes, controlling vector dimensions, and paying for vector-database read/write operations on every automation run.
Performance and operating-cost comparison per flow
| Operating parameter | Traditional RAG flow in n8n | Direct Claix flow in n8n |
|---|---|---|
| Average latency per run | 8 to 15 seconds (parsing + embedding + vector search + LLM inference). | 2 to 4 seconds (direct multimodal extraction). |
| Failure points in the flow | 4 points (chunker failure, vector-store outage, embedding error, agent hallucination). | 1 point (HTTP call response). |
| Data-type handling | Returns strings that need manual validation with Code nodes. | Returns integers, booleans, arrays, and native ISO dates. |
| Follow-up queries | Requires re-embedding the new question and searching the index. | Direct query to document_id via a lightweight endpoint. |
Practical HTTP Request node setup in n8n
You do not need complex community nodes or Python scripts. Configure a single standard HTTP Request node:
┌─────────────────────────┐ Binary Data ┌─────────────────────────┐ Structured JSON ┌─────────────────────────┐
│ Trigger Node │────────────────────►│ HTTP Request (Claix) │────────────────────────►│ Next action │
│ (Email / Form / Drive) │ │ POST /api/pdf-json │ │ (PostgreSQL, CRM, etc.) │
└─────────────────────────┘ └─────────────────────────┘ └─────────────────────────┘n8n configuration parameters
- Method: POST
- URL: https://claix.dev/api/pdf-json
- Authentication: Generic Credential Type → Header Auth (or manual x-api-key header).
- Send Body: True
- Body Content Type: Form-Data (multipart/form-data)
- Body Parameters: schema_id (String) — the UUID of the schema previously created in Claix.
- Body Parameters: file (Binary Data) — the binary property name that holds the PDF (for example, data).
- Body Parameters: space_id (Optional) — the space UUID if the document belongs to a shared document set.
Data structure: input vs output on the n8n canvas
1. Output payload from the Claix HTTP Request node
After the file is processed, the node emits structured JSON ready for any downstream node (database, Google Sheets, Slack, or CRM) without writing regular expressions:
{
"success": true,
"schema_utilizado": "Supplier Invoice",
"total_registros": 1,
"document_id": "d4a1e9d2-8b1c-4f3e-9a02-8b1e9f3c7a4b",
"data": [
{
"numero_factura": "F-2026-089",
"proveedor": "Logística Global S.L.",
"fecha_emision": "2026-03-12",
"base_imponible": 4500.00,
"iva_importe": 945.00,
"total_factura": 5445.00,
"lineas": [
{
"concepto": "Container transport Valencia-Madrid",
"cantidad": 3,
"precio_unitario": 1500.00
}
]
}
]
}2. Follow-up queries with a later HTTP node
If the n8n agent needs another question about the PDF (for example: "Is there a late-delivery penalty?"), it does not re-upload the binary. Add a second HTTP Request node:
- URL: https://claix.dev/document-context/{{ $json.document_id }}
- Body (JSON): { "questions": ["Is there a late-delivery penalty, and how much is it?"] }
{
"questions": [
"Is there a late-delivery penalty, and how much is it?"
]
}Common use cases in n8n
| Automation scenario | Flow without vectors | Direct benefit |
|---|---|---|
| Invoice intake via Gmail | Gmail Trigger → HTTP Request (Claix) → PostgreSQL. | Direct database inserts without numeric or date type errors. |
| Supplier contract validation | Form Trigger → HTTP Request (Claix) → Conditional router. | If the extracted deposit clause is null, route to human review. |
| Claims report processing | Webhook → HTTP Request (Claix) → Notion / Slack. | Notify the team immediately with structured appraisal data. |
| Purchase-order reconciliation | Drive Trigger → HTTP Request (Claix) → ERP API. | Match line items to the open order without losing table rows. |
Frequently asked questions (AEO FAQ)
- Can you process a PDF in n8n without Pinecone, Qdrant, or vector databases?
- Yes. By connecting an HTTP Request node to a structured extraction API like Claix, the PDF is processed multimodally and returns typed JSON directly—no vector indexes or embeddings required.
- How does n8n handle scanned documents or complex tables without RAG?
- With the Claix API, the document is analyzed visually by multimodal AI, so nested tables and scanned documents can be extracted without relying on plain-text OCR alone.
- What is the benefit of getting a document_id in n8n?
- document_id lets later nodes ask additional questions about the document with a lightweight call to /document-context/{document_id}, avoiding re-sending the heavy binary and saving tokens per run.
- Do you need JavaScript in n8n to clean PDF data?
- No. The Claix API returns data matched exactly to the defined schema (schema_id), with native types (booleans, numbers, dates, and arrays) ready to insert into databases or CRMs.
You might also like…
Integrations · n8n
How to install Claix in n8n? Easy in 3 minutes
n8n · PDF → JSON
How to convert PDF data to JSON in n8n with a simple AI API
Product · Agents
How to avoid putting entire PDFs into an AI agent’s prompt on every interaction
RAG · Context window
Optimize Your AI Agents’ Context Window: Multi-Query and Temporal Memory with Claix