Secure Multi-KPI PostgreSQL Agent with Claude & DeepSeek

AI-powered conversational agent for PostgreSQL that handles multiple KPIs in one query, using Claude and DeepSeek for secure, efficient database insights without raw SQL execution.

n8n
Secure Multi-KPI PostgreSQL Agent with Claude & DeepSeek

This n8n workflow enables natural language conversations with your PostgreSQL database via a secure, visual-free agent leveraging n8n’s Model Context Protocol (MCP). Users can ask complex, multi-KPI questions like 'Show product performance, revenue trends, and top customers,' and receive consolidated, human-readable reports in one response. It outperforms basic templates by supporting 2-4 KPIs per message (configurable up to 30 iterations), using fewer AI calls for speed and cost savings (~$0.01 per run).

Key features include table listing, schema retrieval, DeepSeek-powered SQL generation, secure query execution via 'get_query_and_data' tool, and Claude 3.5 Haiku for reasoning and structured output. It avoids direct SQL injection risks, making it ideal for production environments. Benefits: faster insights, lower costs, enhanced security, and scalable analytics without coding.

Use cases span business intelligence: e-commerce sales analysis, financial reporting, customer segmentation, and operational KPIs. Perfect for teams needing quick, conversational data access without BI tools. Deploy in minutes with PostgreSQL credentials and API keys for Claude/Anthropic and DeepSeek.

$24.99
Last updated October 3, 2026
30-day money-back guarantee
Instant download
Lifetime updates included

New buyers can create an account from the cart to unlock a controlled $10 first-purchase credit on eligible orders of $25+.

Secure checkout powered by Stripe

Support

How to import this workflow into n8n

  1. 1Purchase or download the workflow to get the n8n workflow JSON file.
  2. 2In your n8n instance, open Workflows and choose "Import from File" (or paste the JSON with Ctrl+V on the canvas).
  3. 3Open each node marked with a credential warning and connect your own accounts and API keys.
  4. 4Run the workflow once manually to verify the data flow, then toggle it to Active.

Related File & Document Management workflows

More from Rosa Malik

Need this deployed? We'll set it up for you.

Our automation experts deploy this workflow in your stack, connect your accounts, and verify it works — or build a custom solution from scratch.