Skip to main content
AllMCPs
BrowseBestCategoriesStackCompareToolsGuidesBlog Log in Submit MCP

Stay in the loop

Get new MCP servers and top picks in your inbox.

AllMCPs

The open directory for discovering and installing Model Context Protocol servers.

Explore

  • Browse servers
  • Best MCP servers
  • Categories
  • MCP clients
  • Agent prompts
  • Stack Builder
  • Compare servers
  • Tags index
  • Submit a server
  • Pricing

Learn

  • Guides hub
  • What is MCP?
  • Install guide
  • Troubleshooting
  • Security
  • Blog
  • Blog RSS

Tools

  • All tools
  • Config generator
  • Config validator
  • MCP playground
  • OpenAPI β†’ MCP
  • Badge generator

For agents

  • API docs
  • Trust & traffic
  • llms.txt β†— (opens in a new tab)
  • Catalog JSON β†— (opens in a new tab)
  • Remote MCP β†— (opens in a new tab)

Company

  • About
  • Contact
  • X (@AllMCPs) β†— (opens in a new tab)
  • GitHub β†— (opens in a new tab)
  • Terms
  • Privacy
AllMCPs VerifiedAllMCPs VerifiedFeatured on Nick LaunchesFeatured on Nick LaunchesLaunch Llama NewsletterLaunch Llama NewsletterVerified DR - allmcps.comVerified DR - allmcps.comFeatured on SaaSGrowFeatured on SaaSGrowFeatured on Twelve ToolsFeatured on Twelve ToolsFeatured on Saaspa.geFeatured on Saaspa.geFeatured on Findly.toolsFeatured on Findly.toolsFeatured on Startup FameFeatured on Startup FameFeatured on LaunchKiwiFeatured on LaunchKiwiFeatured on ScrollLaunchFeatured on ScrollLaunchFeatured on DailyPingsFeatured on DailyPingsFazier badgeFazier badgeFeatured on NewTool.siteFeatured on NewTool.siteFeatured on saasfame.comFeatured on saasfame.comDR Checker - Domain RatingDR Checker - Domain RatingListed on Turbo0Listed on Turbo0Launched on LaunchBoard - Product Launch PlatformLaunched on LaunchBoard - Product Launch PlatformList on SimilarlabsList on Similarlabshttps://codetrendy.comhttps://codetrendy.comListed on DevTool.ioFeatured on BuildlistFeatured on BuildlistAllMCPs VerifiedAllMCPs VerifiedFeatured on Nick LaunchesFeatured on Nick LaunchesLaunch Llama NewsletterLaunch Llama NewsletterVerified DR - allmcps.comVerified DR - allmcps.comFeatured on SaaSGrowFeatured on SaaSGrowFeatured on Twelve ToolsFeatured on Twelve ToolsFeatured on Saaspa.geFeatured on Saaspa.geFeatured on Findly.toolsFeatured on Findly.toolsFeatured on Startup FameFeatured on Startup FameFeatured on LaunchKiwiFeatured on LaunchKiwiFeatured on ScrollLaunchFeatured on ScrollLaunchFeatured on DailyPingsFeatured on DailyPingsFazier badgeFazier badgeFeatured on NewTool.siteFeatured on NewTool.siteFeatured on saasfame.comFeatured on saasfame.comDR Checker - Domain RatingDR Checker - Domain RatingListed on Turbo0Listed on Turbo0Launched on LaunchBoard - Product Launch PlatformLaunched on LaunchBoard - Product Launch PlatformList on SimilarlabsList on Similarlabshttps://codetrendy.comhttps://codetrendy.comListed on DevTool.ioFeatured on BuildlistFeatured on Buildlist
Β© 2026 Jackalope Digital LLC. All rights reserved.
  1. Home
  2. πŸ—„οΈ Databases
  3. MCP DB Agent
M
Health: Not checked yetWe have not completed a health check for this listing yet.Last checked 8/11/2026, 12:03:33 AM

MCP DB Agent

Enrichment pendingWe haven’t run our AI enrichment pass on this listing yet, so the overview, use cases, and FAQ below may be sparse or missing. We work through the catalog over time β€” check back soon.
View Repository

Query PostgreSQL databases in plain English β€” LLM-generated, safety-validated SQL.

Quick Install

Automated & IDE Setup

Copy the AI prompt to install this server into Claude Code, Cursor, or another agent β€” or use 1-click editor setup below.

Add to CursorAdd to VS Code
Manual Client & Custom JSON ConfigExpand JSON β–Ύ

Install Config Generator

Choose your client
claude_desktop_config.json
{
  "mcpServers": {
    "mcp-db-agent": {
      "command": "npx",
      "args": [
        "-y",
        "mcp-db-agent"
      ]
    }
  }
}

πŸ’‘ Paste into ~/Library/Application Support/Claude/claude_desktop_config.json (macOS) or %APPDATA%\Claude\claude_desktop_config.json (Windows)

Install Directory Badge Claim listing AlternativesπŸ—„οΈ More in Databases

Documentation Overview

PlainQuery

Ask your database questions in plain English. PlainQuery connects PostgreSQL databases to Claude, Cursor, or VS Code β€” and answers with real, structured data instead of guesses.

MCP Registry CI Python

PlainQuery demo β€” querying a database in plain English from an MCP client


What it does

You connect a database once. Then, from any MCP client, you ask questions like:

"How many orders did we ship in March?" "Which 5 customers spent the most last year?" "What's the average order value by month?"

PlainQuery introspects your schema, generates SQL with an LLM, validates it for safety, runs it, and returns structured JSON. If a query fails, it reads the error and retries automatically.

Why PlainQuery

  • Natural language, real answers β€” no SQL required; results come from your actual data, not a hallucination.
  • Read-only and safe by design β€” every query is checked before it runs: writes (INSERT/UPDATE/DELETE/DDL) are blocked, dangerous functions and patterns are scanned out, and a LIMIT is injected automatically.
  • Self-correcting β€” when a generated query errors, the agent feeds the error back to the LLM and retries (up to a configurable limit).
  • Schema-aware β€” automatically introspects and caches your schema, so questions map to the right tables and columns.
  • Works with any MCP client β€” Claude Desktop, Cursor, VS Code Copilot, or anything that speaks MCP.
  • Secure multi-tenant hosting β€” database URLs and LLM keys are Fernet-encrypted at rest; user-supplied connection strings are SSRF-guarded; every request is tenant-scoped.
  • Hosted or self-hosted β€” use the managed service, or run the whole stack yourself with Docker.
  • Bring your own LLM β€” Anthropic Claude or Groq.

How it works

Code
Your question
   β†’ Schema introspection      (reads tables/columns, cached)
   β†’ SQL generation            (schema + question β†’ LLM β†’ SQL)
   β†’ Safety validation         (blocks writes, scans dangerous patterns, injects LIMIT)
   β†’ Execution                 (runs read-only, with a timeout)
   β†’ Self-correction retry     (on error: feed it back to the LLM, fix, re-run)
   β†’ Structured JSON result

Architecture

PlainQuery architecture diagram showing clients, Next.js frontend, Starlette/FastAPI backend, FastMCP endpoint, query pipeline, LLM provider, and customer database


Quick start

Option 1 β€” Use the hosted service (no install)

  1. Sign up at https://plainquery.in and verify your email.
  2. Connect your PostgreSQL database and create an API key.
  3. Add the server to your MCP client (see Connect your MCP client).

That's it β€” start asking questions.

Option 2 β€” Run it yourself

See Self-hosting & local development below.

Connect your MCP client

PlainQuery is published on the official MCP Registry as io.github.Jarvis-27/mcp-db-agent, so registry-aware clients can discover it directly.

To configure a client manually, point it at the MCP endpoint and pass your API key:

config.json
{
  "mcpServers": {
    "plainquery": {
      "url": "https://plainquery.in/mcp",
      "headers": { "X-API-Key": "mdbk_your_key_here" }
    }
  }
}

The backend can also generate ready-to-paste config for VS Code, Cursor, and generic HTTP clients β€” call POST /api/v1/account/setup-payloads (see Setup payloads). MCP clients can authenticate with an OAuth 2.1 bearer token or an API key, depending on MCP_AUTH_MODE.


Self-hosting & local development

Prerequisites

  • Python 3.12+
  • uv
  • Node.js 20+ and pnpm for the frontend
  • At least one LLM API key (ANTHROPIC_API_KEY or GROQ_API_KEY)

Backend

bash
uv sync
cp .env.example .env

Edit .env with at least:

  • CREDENTIAL_ENCRYPTION_KEYS
  • REGISTRATION_OPEN=true
  • one LLM provider key plus LLM_PROVIDER

Run the backend:

bash
uv run uvicorn src.app:app --reload --host 0.0.0.0 --port 8000

The backend mounts:

  • REST API at http://localhost:8000/api
  • MCP endpoint at http://localhost:8000/mcp

Frontend

bash
cd frontend
pnpm install
pnpm dev

Open http://localhost:3000, sign up, complete setup, link your OAuth identity via account settings, then connect an MCP client at http://localhost:8000/mcp. The client will complete the OAuth flow automatically, or you can use an API key in api_key_only / hybrid mode.

Runtime model

  • Backend API: FastAPI/Starlette at src.app:app
  • Frontend: Next.js app in frontend/
  • Auth: passwordless email verification and login links
  • MCP auth: OAuth 2.1 bearer tokens (oauth_only), API keys (api_key_only), or both (hybrid) β€” set via MCP_AUTH_MODE
  • Setup payloads: POST /api/v1/account/setup-payloads
  • Billing: Stripe Checkout, Customer Portal, and webhook-confirmed Free/Pro entitlements

The product model is single-account and user-scoped: signup β†’ verify email β†’ connect database β†’ link OAuth identity β†’ use /mcp β†’ upgrade with Stripe

Security

PlainQuery security diagram showing URL validation, SSRF protection, encrypted credential storage, MCP authentication, per-request isolation, SQL validation, rate limits, and controlled execution

  • User-supplied database URLs are validated against SSRF, path traversal, private IPs, and DNS rebinding before any connection attempt.
  • Database URLs and LLM keys are Fernet-encrypted at rest, with support for key rotation.
  • Generated SQL is validated before execution: single-statement guard, forbidden-function scan, dangerous-pattern scan, write/DDL block, table-existence check, and automatic LIMIT injection.
  • Per-request context scoping prevents cross-tenant data leaks.
  • Per-user rate limits and fallback-LLM quotas limit cost abuse.

Important environment variables

VariableDescription
AUTH_DATABASE_URLAuth/account database used by the hosted product
CREDENTIAL_ENCRYPTION_KEYSEncrypts stored database URLs and other secrets
REGISTRATION_OPENEnables or disables public signup
ANTHROPIC_API_KEY / GROQ_API_KEYLLM credentials for SQL generation
LLM_PROVIDERActive provider name
APP_BASE_URLBase URL used in setup payloads
FRONTEND_BASE_URLBase URL used in email links
STRIPE_SECRET_KEY / STRIPE_WEBHOOK_SECRETStripe API and webhook credentials
STRIPE_PRO_PRICE_IDStripe Price ID that maps to the Pro plan
STRIPE_CHECKOUT_SUCCESS_URL / STRIPE_CHECKOUT_CANCEL_URLOptional Checkout redirect overrides
STRIPE_CUSTOMER_PORTAL_RETURN_URLOptional Customer Portal return URL override

See .env.example for the current full set.

API surface

Auth

  • POST /api/v1/auth/signup
  • GET /api/v1/auth/verify-email
  • POST /api/v1/auth/request-login-link
  • GET /api/v1/auth/exchange-login-link
  • POST /api/v1/auth/logout

Account (session-authenticated)

All account routes use session token auth (x-session-token: <session-token> or Authorization: Bearer <session-token>):

  • GET /api/v1/account
  • GET /api/v1/account/status
  • PUT /api/v1/account/database
  • GET /api/v1/account/api-keys
  • POST /api/v1/account/api-keys
  • DELETE /api/v1/account/api-keys/{id}
  • POST /api/v1/account/api-keys/{id}/rotate
  • POST /api/v1/account/setup-payloads
  • GET /api/v1/account/dashboard
  • GET /api/v1/account/usage/recent

Billing

  • GET /api/v1/account/billing
  • POST /api/v1/account/billing/checkout-session
  • POST /api/v1/account/billing/portal-session
  • POST /api/v1/billing/webhook

Stripe webhooks are the source of truth for plan transitions. Checkout or subscription activation moves a user to plan_code=pro; canceled, unpaid, or past-due states restrict paid entitlements without deleting database setup.

OAuth MCP account linking (session-authenticated)

  • GET /api/v1/account/mcp-oauth/status
  • POST /api/v1/account/mcp-oauth/start
  • GET /api/v1/account/mcp-oauth/callback
  • DELETE /api/v1/account/mcp-oauth/link

MCP

  • POST /mcp
  • Auth: OAuth 2.1 bearer token, API key, or both β€” controlled by MCP_AUTH_MODE

Setup payloads

POST /api/v1/account/setup-payloads returns client configuration material for VS Code, Cursor, generic HTTP MCP clients, and the current ChatGPT placeholder.

Terminal
curl -X POST http://localhost:8000/api/v1/account/setup-payloads \
  -H "Authorization: Bearer <session-token>" \
  -H "Content-Type: application/json" \
  -d '{"raw_api_key":"mdbk_..."}'

The backend never stores raw API keys after creation. A raw key is only embedded in setup payloads when you explicitly send it in the request.

Tests

bash
uv run pytest tests/ -m "not integration"
uv run pytest tests/ -m integration
uv run ruff check .
uv run mypy src --ignore-missing-imports

Deployment smoke test

After each hosted deploy, verify the public MCP OAuth discovery surface:

bash
uv run python scripts/smoke_mcp_deployment.py \
  --mcp-url https://mcp.example.com/mcp \
  --issuer-url https://YOUR_DOMAIN.auth0.com/

The smoke test checks the unauthenticated /mcp challenge, protected resource metadata, ChatGPT/Claude well-known discovery routes, and issuer metadata. To also verify authenticated MCP initialize, tools/list, and resources/list, pass a linked user's access token with --access-token or MCP_SMOKE_ACCESS_TOKEN.

Docker

Run the hosted HTTP stack:

Terminal
docker compose up --build

The container image serves only the hosted HTTP runtime. The MCP endpoint remains http://localhost:8000/mcp.

License

MIT Β© 2026 PlainQuery

Related MCP Servers

View all in Databases View all alternatives
  • AllMCPs Server logoAllMCPs Server
    β˜… Featured

    The official MCP server for AllMCPs.com - submit and manage tools directly from your AI. The open directory for MCP servers. Connect Claude, Cursor, Windsurf, and AI agents to databases, tools, files, and APIs. Explore 3,181+ servers. AllMCPs is the premier, open directory for discovering, evaluating, and installing Model Context Protocol (MCP) servers to equip AI agents and LLMs with real-world superpowers.

    πŸ—„οΈ Databases7 views
    Compare vs AllMCPs Server β†’
  • Genai Toolbox logoGenai Toolbox

    Open source MCP server specializing in easy, fast, and secure tools for Databases.

    πŸ—„οΈ Databases3 views
    Compare vs Genai Toolbox β†’
  • Mysql Mcp Server logoMysql Mcp Server

    MySQL database integration with configurable access controls, schema inspection, and comprehensive security guidelines

    πŸ—„οΈ Databases1 views
    Compare vs Mysql Mcp Server β†’
  • Mcp Server Duckdb logoMcp Server Duckdb

    DuckDB database integration with schema inspection and query capabilities

    πŸ—„οΈ Databases2 views
    Compare vs Mcp Server Duckdb β†’

Frequently Asked Questions about MCP DB Agent

Add the following block to your claude_desktop_config.json under mcpServers: "mcpServers": { "mcp-db-agent": { "command": "npx", "args": ["-y", "MCP DB Agent"] } }

AllMCPs Directory Badge

Full Badge Customizer

Showcase your server listing on GitHub or your project documentation. Embed this dynamic SVG badge to highlight official listing status and live engagement.

Badge Style:
Live Dynamic SVG PreviewMCP DB Agent AllMCPs Directory Badge
Markdown (GitHub README)
[![AllMCPs](https://allmcps.com/api/badge/mcp-db-agent?style=directory)](https://allmcps.com/mcp/mcp-db-agent)
HTML Embed
<a href="https://allmcps.com/mcp/mcp-db-agent"><img src="https://allmcps.com/api/badge/mcp-db-agent?style=directory" alt="MCP DB Agent on AllMCPs" /></a>

Technical Specs & Signals

CategoryπŸ—„οΈDatabases
More technical detailsExpand β–Ύ
TransportSTDIO
RuntimeNode.js
Views0
Unique ViewsTotal visits recorded for this listing page on AllMCPs.
Installs0
Installs & Copy ActionsTotal times users copied install commands or configuration snippets for this server.
27Quality signal: Emerging Β· 27/100How this signal is calculated β–Ύ
Server availabilityNot measured

Not scored for repo-hosted servers β€” we can't reach the running server, only its GitHub page. Hosted MCP endpoints are health-checked live.

Verified ownership8/20
Documentation & tools11/30
Adoption & activity1/15
Community engagement0/10

A guidance signal from public completeness & health data β€” not a user rating. New listings start lower and rise as they add docs, get verified, and grow adoption. Signals we can't observe for a listing are skipped, not counted against it.

β˜… FeaturedMoxie Docs MCP logo

Moxie Docs MCP

MCP & Agent Skills for Automated Documentation, and codebase conventions + context

Explore Server β†’

Own this project?

This directory is pre-filled from public sources. Claim via GitHub README, site badge, or DNS TXT to get the verified badge and attach your website.

Free dofollow backlink: after claiming, verify your product site and place a dofollow AllMCPs badge β€” we recheck it stays live.

Claim & get free dofollow

Share & Embed

Add our SVG badge (dark/light directory styles) or embeddable widget to your site.

Explore more

More in πŸ—„οΈ Databases β†’Best MCP servers for Databases β†’Alternatives to MCP DB Agent β†’Install in Claude DesktopInstall in CursorInstall in VS Code