Skip to main content

n8n Integration

n8n is an open-source workflow automation tool that you can self-host or use in the cloud. Perfect for developers who want full control over their automation workflows.

Why n8n?

Self-Hosted

Deploy on your own infrastructure for complete control

Open Source

Inspect, modify, and extend the platform

Developer-Friendly

Code nodes, JavaScript expressions, and custom nodes

Fair Pricing

Free self-hosted or affordable cloud plans

Installation

n8n Cloud

Fastest way to get started:
  1. Sign up at n8n.cloud
  2. Create your first workflow
  3. No setup required

Self-Hosted (Docker)

Self-Hosted (npm)

For production deployments, see the n8n deployment guide.

Quick Start: FLTR Search Workflow

Step 1: Create New Workflow

  1. Open n8n interface
  2. Click New workflow
  3. Name it “FLTR Knowledge Search”

Step 2: Add HTTP Request Node

  1. Click + to add node
  2. Search for HTTP Request
  3. Configure:
Method: POST URL: https://api.fltr.com/v1/mcp/query Authentication: Generic Credential Type → Header Auth
  • Name: Authorization
  • Value: Bearer YOUR_API_KEY
Body Parameters (JSON):

Step 3: Test the Node

  1. Click Execute Node
  2. View results in the output panel
  3. Inspect the JSON response

Step 4: Process Results

Add a Code node to transform results:

Common Workflows

Nodes:
  1. Email Trigger (IMAP) - Watch inbox
  2. HTTP Request - FLTR Query
  3. Code - Format results
  4. Send Email - Reply with results
FLTR HTTP Request:
Code Node (Format Response):

2. Slack Q&A Bot

Nodes:
  1. Slack Trigger - New message in channel
  2. IF - Check if question
  3. HTTP Request - FLTR Query
  4. Slack - Post reply
IF Condition:
FLTR Query:
Slack Reply:

3. Document Indexer Pipeline

Nodes:
  1. Webhook - Receive document
  2. Code - Extract metadata
  3. HTTP Request - Upload to FLTR
  4. Slack - Send notification
Code Node (Extract Metadata):
HTTP Request (Upload):

4. Customer Support Automation

Nodes:
  1. Webhook Trigger - New support ticket
  2. HTTP Request - FLTR Query
  3. Switch - Route by confidence
  4. Multiple endpoints - Different actions per route
Switch Routes: Route 1: {{ $json.results[0].score >= 0.8 }} → Auto-respond with answer Route 2: {{ $json.results[0].score >= 0.5 && $json.results[0].score < 0.8 }} → Create ticket with suggestions Route 3: {{ $json.results[0].score < 0.5 }} → Escalate to human

Advanced Techniques

Using Code Nodes

n8n’s Code node supports full JavaScript: Example: Filter and rank results
Example: Combine multiple queries

Loop Over Results

Use Split in Batches to process each result:
  1. Add Split in Batches after FLTR query
  2. Set batch size to 1
  3. Connect to action node
  4. Each result processed individually
Example: Create Notion page for each result

Error Handling

Add error workflows:
  1. On any node, click Settings (gear icon)
  2. Enable Continue On Fail
  3. Add IF node to check for errors
  4. Route failures to error handler
Error Check:
Error Notification:

Scheduling Workflows

Add Schedule Trigger for recurring tasks: Example: Daily document sync
  • Trigger: Cron - 0 2 * * * (2 AM daily)
  • Action: Fetch new documents from source
  • Upload to FLTR
  • Send summary email

Using Credentials

Store API keys securely:
  1. Go to CredentialsNew
  2. Select Header Auth
  3. Name: FLTR API Key
  4. Header name: Authorization
  5. Header value: Bearer YOUR_API_KEY
Use in HTTP Request nodes:
  • Authentication: FLTR API Key

All FLTR Endpoints

Query Dataset

Node: HTTP Request

Batch Query

Upload Document

Create Dataset

List Datasets

Expressions and Functions

Accessing Data

String Operations

Array Operations

Math Functions

Rate Limiting

Handle FLTR’s rate limits in n8n:

Method 1: Wait Node

Add Wait node between iterations:

Method 2: Code Node Delay

Method 3: Error Handling

Webhook Workflows

Create Webhook Endpoint

  1. Add Webhook node
  2. Set HTTP Method: POST
  3. Copy webhook URL
  4. Configure response
Webhook Response:

Secure Webhooks

Validate incoming requests:
  1. Add IF node after webhook
  2. Check secret header:
  1. Route invalid requests to error response

Production Best Practices

1. Use Environments

Set environment variables:
Access in workflows:

2. Enable Execution Data

Keep execution history: Settings → Workflow Settings:
  • Save execution progress: Yes
  • Save manual executions: Yes
  • Save error executions: Yes

3. Add Monitoring

Create monitoring workflow:
  • Trigger: Schedule (every 5 minutes)
  • Check: Last execution status
  • Alert: Send notification if failed

4. Optimize Performance

  • Use Merge nodes to combine data
  • Enable Continue On Fail for non-critical nodes
  • Use Split in Batches for large datasets
  • Cache results with Set node

Complete Example: Support Ticket System

Here’s a production-ready workflow: Node 1: Webhook
Node 2: Validate Input
Node 3: FLTR Query
Node 4: Switch (Route by Confidence) Route 1: {{ $json.results[0].score >= 0.8 }} Route 2: {{ $json.results[0].score >= 0.5 }} Route 3: {{ $json.results[0].score < 0.5 }} Node 5a: Auto-Response Email
Node 5b: Create Zendesk Ticket
Node 5c: Slack Alert
Node 6: Webhook Response

Resources

n8n Documentation

Official n8n docs

FLTR API Reference

Complete API documentation

n8n Community

Get help from the community

Deployment Guide

Self-host n8n in production

Next Steps