Documentation Index
Fetch the complete documentation index at: https://mintlify.com/KevinhosUTP/Automatizacion-Lurwis/llms.txt
Use this file to discover all available pages before exploring further.
n8n Installation & Setup
This guide covers installing n8n (self-hosted or cloud) and configuring it for the Automatización Lurwis platform.Prerequisites
Before installing n8n, ensure you have:- Node.js 18+ (for self-hosted)
- PostgreSQL 12+ database
- MongoDB 4.4+ for conversation memory
- Redis 6+ for message buffering
- WhatsApp Business API credentials
- Google Gemini API key
Installation Options
- Self-Hosted (Recommended)
- n8n Cloud
Docker Installation
The recommended approach for production deployments:NPM Installation
For local development:Workspace Configuration
Import Workflows
After installation, import the two main workflows:Import Receptor workflow
Upload:
workflows/Picantería Lurwis _ Receptor.jsonThis workflow handles:- WhatsApp webhook verification
- Message reception and validation
- Redis buffering (6-8 second window)
- Error handling
Import Procesador workflow
Upload:
workflows/Picantería Lurwis _ Procesador.jsonThis workflow handles:- Message classification
- AI agent routing
- Order processing
- Database operations
Credential Management
Configure credentials for all integrations:WhatsApp Business API
Add WhatsApp credential
- Go to Credentials → New
- Select WhatsApp
- Enter:
- Access Token: Your Meta access token
- Phone Number ID:
947279508470714(from workflow)
PostgreSQL Database
The workflows note mentions “CONNECTION STRING (SESSION POOLER)” with RLS (Row Level Security) enabled.
MongoDB Memory
Collections used
The system uses separate collections for conversation memory:
historial_clasificador- Message classificationhistorial_detector- Order detectionhistorial_pedidos- Order conversations (25 message window)historial_eventos- Event bookings (15 message window)historial_reservas- Table reservations (15 message window)historial_general- General inquiries (10 message window)
Redis Buffer
Google Gemini AI
Get API key
- Go to Google AI Studio
- Create new API key
- Copy and save securely
Workflow Settings
Execution Settings
Both workflows use
executionOrder: v1 for sequential processing.Error Workflow
To create an error workflow:- Create new workflow named “Error Notifications”
- Add Error Trigger node
- Add WhatsApp node to send error details
- In main workflows, go to Settings → Error Workflow → Select “Error Notifications”
Webhook Configuration
Meta WhatsApp Verification
The Receptor workflow handles Meta’s webhook verification:- Path:
/webhook/meta-verify - Method: GET and POST
- Verify Token:
meta-verify - Response Mode: Response Node (for proper Meta acknowledgment)
Configure in Meta Developer Console
- Go to WhatsApp Business API settings
- Add webhook URL:
https://your-domain.com/webhook/meta-verify - Verify token:
meta-verify - Subscribe to:
messagesfield
Performance Tuning
Execution Limits
Memory Settings
For high-traffic production:Next Steps
Environment Variables
Configure all required environment variables
Production Checklist
Review production deployment requirements
Database Schema
Understand the database structure
Troubleshooting
Common issues and solutions