Dbx
Query databases from AI agents using connections configured in DBX.
Safe SQL gateway for AI agents: SELECT-only validation, access policies, masking, audit trail, evals
Elige la app de IA que usas y copia la configuración.
Pasó 3/3 revisiones · Funciona en tu computadora · ✓ Comandos revisados el 14 nov 2026
Primero: ¿qué IA usas?
Elige tu app y los pasos aparecen abajo.
Funciona con Claude, pero hay que preparar algo antes
Necesitas una clave de QueryPilot (créala en el sitio del autor) · Instala Python (uv) en tu computadora primero (una sola vez) · Solo en la app de Claude para computadora (Windows o Mac), no en la web ni en el móvil
Una sola vez; sirve para todos los servidores que necesitan Python (uv)
Abre el sitio del autor, crea una cuenta y una clave de API para el siguiente paso. Consulta precios y planes gratis en su sitio.
SettingsDeveloperEdit Config
{
"mcpServers": {
"querypilot": {
"command": "uvx",
"args": [
"querypilot",
"mcp"
],
"env": {
"QUERYPILOT_DATABASE_URL": "your-value"
}
}
}
}Pega la clave solo en el campo de la app; nunca en un chat ni se la envíes a nadie
Usa QueryPilot y dime qué puedes hacer por mí; luego muéstrame una cosa✓ Si Claude dice que está usando QueryPilot o muestra una herramienta de QueryPilot en la respuesta, ya está conectado
El comando de arriba funciona sin estos valores. Añádelos solo si quieres cambiar algo, según la descripción del autor.
QUERYPILOT_DIALECT SQL dialect for the connector. Equivalent to --dialect. · valor por defecto sqliteQUERYPILOT_MAX_ROWS Maximum rows returned per query. Equivalent to --max-rows. · valor por defecto 100QUERYPILOT_TIMEOUT_SECONDS Query execution timeout in seconds. Equivalent to --timeout-seconds. · valor por defecto 10QUERYPILOT_ACCESS_POLICY_JSON JSON-encoded AccessPolicy (blocked_columns, allowed_columns, row_filters, masking_rules) enforced before execution. Equivalent to --access-policy-json.QUERYPILOT_MCP_TRANSPORT MCP transport used by `querypilot mcp`. Equivalent to --transport. Most MCP clients should leave this at stdio; streamable-http is for clients that speak Streamable HTTP directly. · valor por defecto stdioLas descripciones siguen en el inglés original.
Nombres de menú comprobados con la ayuda de Anthropic el 11 nov 2026 · tu pantalla puede variar un poco según la versión
ChatGPT todavía no puede conectar QueryPilot
QueryPilot se instala en tu computadora, pero ChatGPT solo conecta servidores que funcionan en la web
A · Usa una app que pueda conectar QueryPilot
B · Otros en Bases de datos y conjuntos de datos que funcionan con ChatGPT
Elegidos entre los más usados de la misma categoría, solo los que se conectan con una dirección y sin clave
Funciona con Claude Code, pero hay que preparar algo antes
Necesitas una clave de QueryPilot (créala en el sitio del autor) · Instala Python (uv) en tu computadora primero (una sola vez)
Una sola vez; sirve para todos los servidores que necesitan Python (uv)
Abre el sitio del autor, crea una cuenta y una clave de API para el siguiente paso. Consulta precios y planes gratis en su sitio.
Mac: pulsa Command+Espacio y escribe Terminal · Windows: abre PowerShell
claude mcp add --scope user querypilot --env QUERYPILOT_DATABASE_URL=your-value -- uvx querypilot mcpCambia “your-value” por tu clave antes de pulsar Enter
Pega la clave solo en el campo de la app; nunca en un chat ni se la envíes a nadie
Deberías ver QueryPilot en la lista como conectado
Usa QueryPilot y dime qué puedes hacer por mí; luego muéstrame una cosa✓ Si Claude Code dice que está usando QueryPilot o muestra una herramienta de QueryPilot en la respuesta, ya está conectado
El comando de arriba funciona sin estos valores. Añádelos solo si quieres cambiar algo, según la descripción del autor.
QUERYPILOT_DIALECT SQL dialect for the connector. Equivalent to --dialect. · valor por defecto sqliteQUERYPILOT_MAX_ROWS Maximum rows returned per query. Equivalent to --max-rows. · valor por defecto 100QUERYPILOT_TIMEOUT_SECONDS Query execution timeout in seconds. Equivalent to --timeout-seconds. · valor por defecto 10QUERYPILOT_ACCESS_POLICY_JSON JSON-encoded AccessPolicy (blocked_columns, allowed_columns, row_filters, masking_rules) enforced before execution. Equivalent to --access-policy-json.QUERYPILOT_MCP_TRANSPORT MCP transport used by `querypilot mcp`. Equivalent to --transport. Most MCP clients should leave this at stdio; streamable-http is for clients that speak Streamable HTTP directly. · valor por defecto stdioLas descripciones siguen en el inglés original.
Nombres de menú comprobados con la ayuda de Anthropic el 11 nov 2026 · tu pantalla puede variar un poco según la versión
Funciona con Cursor, pero hay que preparar algo antes
Necesitas una clave de QueryPilot (créala en el sitio del autor) · Instala Python (uv) en tu computadora primero (una sola vez)
Una sola vez; sirve para todos los servidores que necesitan Python (uv)
Abre el sitio del autor, crea una cuenta y una clave de API para el siguiente paso. Consulta precios y planes gratis en su sitio.
En la configuración de QueryPilot, QUERYPILOT_DATABASE_URL está vacío; añade tu clave y guarda
Pega la clave solo en el campo de la app; nunca en un chat ni se la envíes a nadie
Usa QueryPilot y dime qué puedes hacer por mí; luego muéstrame una cosa✓ Si Cursor dice que está usando QueryPilot o muestra una herramienta de QueryPilot en la respuesta, ya está conectado
El comando de arriba funciona sin estos valores. Añádelos solo si quieres cambiar algo, según la descripción del autor.
QUERYPILOT_DIALECT SQL dialect for the connector. Equivalent to --dialect. · valor por defecto sqliteQUERYPILOT_MAX_ROWS Maximum rows returned per query. Equivalent to --max-rows. · valor por defecto 100QUERYPILOT_TIMEOUT_SECONDS Query execution timeout in seconds. Equivalent to --timeout-seconds. · valor por defecto 10QUERYPILOT_ACCESS_POLICY_JSON JSON-encoded AccessPolicy (blocked_columns, allowed_columns, row_filters, masking_rules) enforced before execution. Equivalent to --access-policy-json.QUERYPILOT_MCP_TRANSPORT MCP transport used by `querypilot mcp`. Equivalent to --transport. Most MCP clients should leave this at stdio; streamable-http is for clients that speak Streamable HTTP directly. · valor por defecto stdioLas descripciones siguen en el inglés original.
Nombres de menú comprobados con la ayuda de Cursor el 11 nov 2026 · tu pantalla puede variar un poco según la versión
Funciona con VS Code, pero hay que preparar algo antes
Necesitas una clave de QueryPilot (créala en el sitio del autor) · Instala Python (uv) en tu computadora primero (una sola vez)
Una sola vez; sirve para todos los servidores que necesitan Python (uv)
Abre el sitio del autor, crea una cuenta y una clave de API para el siguiente paso. Consulta precios y planes gratis en su sitio.
En la configuración de QueryPilot, QUERYPILOT_DATABASE_URL está vacío; añade tu clave y guarda
Pega la clave solo en el campo de la app; nunca en un chat ni se la envíes a nadie
Usa QueryPilot y dime qué puedes hacer por mí; luego muéstrame una cosa✓ Si VS Code dice que está usando QueryPilot o muestra una herramienta de QueryPilot en la respuesta, ya está conectado
El comando de arriba funciona sin estos valores. Añádelos solo si quieres cambiar algo, según la descripción del autor.
QUERYPILOT_DIALECT SQL dialect for the connector. Equivalent to --dialect. · valor por defecto sqliteQUERYPILOT_MAX_ROWS Maximum rows returned per query. Equivalent to --max-rows. · valor por defecto 100QUERYPILOT_TIMEOUT_SECONDS Query execution timeout in seconds. Equivalent to --timeout-seconds. · valor por defecto 10QUERYPILOT_ACCESS_POLICY_JSON JSON-encoded AccessPolicy (blocked_columns, allowed_columns, row_filters, masking_rules) enforced before execution. Equivalent to --access-policy-json.QUERYPILOT_MCP_TRANSPORT MCP transport used by `querypilot mcp`. Equivalent to --transport. Most MCP clients should leave this at stdio; streamable-http is for clients that speak Streamable HTTP directly. · valor por defecto stdioLas descripciones siguen en el inglés original.
Nombres de menú comprobados con la ayuda de VS Code el 11 nov 2026 · tu pantalla puede variar un poco según la versión
Otras apps que usan MCP, como Windsurf, Zed o Gemini CLI, añaden servidores de forma distinta. Míralo en la lista de apps
Ver todas las apps que usan MCP →
La configuración JSON está en “Para desarrolladores”, abajo
Claude Code
claude mcp add --scope user querypilot --env QUERYPILOT_DATABASE_URL=your-value -- uvx querypilot mcpClaude Desktop (claude_desktop_config.json)
{
"mcpServers": {
"querypilot": {
"command": "uvx",
"args": [
"querypilot",
"mcp"
],
"env": {
"QUERYPILOT_DATABASE_URL": "your-value"
}
}
}
}Cursor (~/.cursor/mcp.json)
{
"mcpServers": {
"querypilot": {
"command": "uvx",
"args": [
"querypilot",
"mcp"
],
"env": {
"QUERYPILOT_DATABASE_URL": "your-value"
}
}
}
}VS Code (mcp.json)
{
"servers": {
"querypilot": {
"type": "stdio",
"command": "uvx",
"args": [
"querypilot",
"mcp"
],
"env": {
"QUERYPILOT_DATABASE_URL": "your-value"
}
}
}
}QUERYPILOT_DATABASE_URL secreto obligatorio envQUERYPILOT_DIALECT envQUERYPILOT_MAX_ROWS envQUERYPILOT_TIMEOUT_SECONDS envQUERYPILOT_ACCESS_POLICY_JSON envQUERYPILOT_MCP_TRANSPORT envLas descripciones siguen en el inglés original.
Esta configuración se genera a partir de la ficha del creador en el registro. Si el README dice otra cosa, sigue el README.
pypi: querypilotSegún cómo se conecta este servidor y la documentación de cada app, comprobado el 10 nov 2026.
Se ejecutan en tu computadora en
ClaudeGooseLM StudioMsty StudioCherry StudioCursorVS Code + GitHub CopilotVisual StudioWindsurf (Devin Desktop)ZedKiroClineContinueJetBrains AI AssistantClaude CodeCodex CLIGemini CLIOpenCodenodecodeWarpLibreChatRaycast
Se ejecuta en tu computadora; la lista de herramientas aparece en tu app de IA después de instalarlo.
Revisamos información que cualquiera puede ver; no hemos leído el código. Las revisiones que no aplican no se cuentan. · Revisado el 14 nov 2026
El nombre en el registro se verificó con la cuenta de GitHub nickklos10, dueña del repo
Último cambio de código: hace 21 días
Usa MIT
Este se ejecuta en tu computadora; no hay endpoint en internet
Se ejecuta en tu computadora y usa ajustes locales en su lugar
Se ejecuta en tu computadora; solo podemos leer listas de herramientas de endpoints en internet
Pregunta, comparte un consejo o avisa de que no funciona. Ordenado por lo que la gente marcó como útil.
Aún no hay publicaciones. Sé la primera persona en preguntar o compartir.
Lo publicado aquí lo escriben usuarios, no el equipo de PopNx.
Aún no hay reseñas
Comparado con todos los servidores activos de esta categoría en el registro. Las estrellas solo cuentan cuando quien lo publica es dueño del repo.
Superó 3 de 3 revisiones básicas aplicables. No hemos leído el código. Antes de agregar una clave o un token, revisa qué acceso pide el servidor y usa una clave que tenga solo los permisos que necesitas.
Debes completar: QUERYPILOT_DATABASE_URL
Se ejecuta en tu computadora. Tu app de IA lo inicia cuando hace falta, y los datos no pasan por los servidores del creador (a menos que el propio servidor llame a un servicio en línea).
El repo de GitHub cambió por última vez hace 21 días, y la última versión (0.1.1) llegó al registro hace 4 meses.
Las apps compatibles con MCP, como Claude Desktop, Claude Code, Cursor y VS Code. También necesitas Python (uv) en tu computadora.
En la misma categoría: Dbx, MCP Toolbox for Databases, MCP Toolbox for Databases
Servidores de la misma categoría hechos por otros creadores, ordenados por estrellas.
Cómo leer una tarjeta:↓ Descargas por semanai★ Estrellas de GitHubiTres pilares: reseñas · revisiones · usoiActualizado = fecha en que se publicó la última versión en el registroi
Query databases from AI agents using connections configured in DBX.
MCP Toolbox for Databases enables your agent to connect to your database.
MCP Toolbox for Databases enables your agent to connect to your database.
Copiado tal cual del repo del creador. PopNx MCP no lo ha revisado ni lo respalda. Se quitaron HTML, imágenes y scripts. Los enlaces llevan fuera de este sitio.
Safe, measurable SQL for AI agents.
QueryPilot sits between an LLM agent and your database. It gives the agent read-only, policy-checked SQL tools for any SQLAlchemy database. It grounds the model in your real schema, feeds errors back so the model can fix its SQL, and ships an eval harness that proves the SQL is correct and stays correct.
pip install querypilot
querypilot demo
querypilot demo writes a small SaaS database (querypilot-demo.db), runs a validated query against it and shows a blocked DELETE. Then try:
querypilot schema --db sqlite:///querypilot-demo.db # list tables
querypilot schema --db sqlite:///querypilot-demo.db invoices # columns, keys, sample values querypilot sql --db sqlite:///querypilot-demo.db "SELECT customer_nme FROM customers"
querypilot ask --db sqlite:///querypilot-demo.db "Which customers have the highest ARR?"
ask uses OpenAI or Anthropic when OPENAI_API_KEY or ANTHROPIC_API_KEY is set (--generator openai-compatible covers Ollama, vLLM and LM Studio). Without a key it falls back to an offline demo generator.
For your own database, querypilot init --db postgresql://analyst@db.internal/prod writes a querypilot.yaml that holds the connection, business hints, column descriptions and access policy. Every command, the MCP server and QueryPilot.from_config() read it, so you can drop --db from then on.
In Python:
from querypilot import QueryPilot
qp = QueryPilot.connect("postgresql://analyst@db.internal/prod") # dialect inferred from the URL
result = qp.execute_sql("SELECT plan, COUNT(*) FROM subscriptions GROUP BY plan") print(result.sql) # rewritten with a LIMIT, validated against the live schema print(result.rows)
QueryPilot.connect(url) infers the SQL dialect from the URL and introspects tables, views, primary and foreign keys, and comments. It also accepts a SQLAlchemy Engine.
| Database | URL | Install |
|---|---|---|
| SQLite | sqlite:///app.db | included |
| PostgreSQL | postgresql://user:pass@host/db | included |
| DuckDB | duckdb:///analytics.duckdb | pip install "querypilot[duckdb]" |
| MySQL / MariaDB | mysql+pymysql://user:pass@host/db | pip install "querypilot[mysql]" |
| SQL Server | mssql+pyodbc://… | pip install "querypilot[mssql]" |
| Snowflake | snowflake://user@account/db/schema | pip install "querypilot[snowflake]" |
| BigQuery | bigquery://project/dataset | pip install "querypilot[bigquery]" |
| Redshift | redshift+psycopg2://… | pip install "querypilot[redshift]" |
| Trino / Oracle / Databricks | trino://…, oracle+oracledb://…, databricks://… | querypilot[trino], [oracle], [databricks] |
Every query is validated with sqlglot for the target dialect. Validation means one statement, SELECT only, and known tables and columns. It also blocks dangerous functions for each engine, such as pg_read_file, DuckDB's read_csv, MySQL's LOAD_FILE and SQL Server's xp_cmdshell. Execution then adds the engine's own guard: a read-only transaction on Postgres, MySQL and Oracle, a read-only connection on DuckDB, and a statement timeout where the engine supports one. Every query runs in a transaction that is always rolled back. For warehouses that have no read-only session mode, connect with a read-only role.
Every integration exposes the same small toolset. Results are compact JSON, and errors come back as {"ok": false, "error": ..., "hints": [...]} rather than as exceptions, so the agent can correct itself.
| Tool | What it does |
|---|---|
list_tables | Tables and views the policy allows, with comments |
describe_table | Columns, types, keys, comments and sample values for the named tables |
search_schema | Finds tables and columns relevant to a question |
validate_sql | Checks SQL and returns the rewritten form, errors and "did you mean" hints |
run_sql | Validates and runs SQL, returning rows with a truncated flag at max_rows |
ask_database | Natural language → validated SQL → rows (only when an LLM generator is configured) |
MCP (Claude Code, Claude Desktop, Cursor, VS Code, Windsurf):
querypilot mcp-config claude-code --db postgresql://analyst@db/prod
querypilot mcp-config cursor --db sqlite:///app.db # prints the mcpServers JSON block
The generated config uses the absolute path to uvx, which avoids the common spawn uvx ENOENT failure. Pass --runner python to launch the current environment instead. Every tool carries the MCP readOnlyHint annotation. querypilot mcp --transport streamable-http --port 8000 serves the same tools over HTTP.
OpenAI / Anthropic tool calling:
tools = qp.as_openai_tools() # Chat Completions; qp.toolkit().openai_responses_tools() for Responses
tools = qp.as_anthropic_tools() result = qp.handle_tool_call(tool_call.name, tool_call.arguments) # dict or JSON string in, dict out
Agent frameworks:
from querypilot.integrations import (
as_langchain_tools, # LangChain / LangGraph StructuredTools as_llamaindex_tools, # LlamaIndex FunctionTools as_openai_agents_tools, # OpenAI Agents SDK FunctionTools as_claude_agent_mcp_server, # Claude Agent SDK in-process MCP server claude_agent_allowed_tools, as_functions, # plain typed functions: Pydantic AI, smolagents, CrewAI, ADK )
tools = as_langchain_tools(qp, naming="langchain") # sql_db_list_tables, sql_db_schema, sql_db_query, ...
naming="langchain" reuses the tool names from the community SQLDatabaseToolkit (no longer maintained), so existing prompts keep working. Install the matching extra: querypilot[langchain], [llamaindex], [openai-agents], [claude-agent] or [mcp]. See examples/07_frameworks.py.
querypilot proxy (prototype)The proxy needs no SDK. It is a Postgres wire-protocol server that applies the same validator and access policy to every statement, whatever the client. That covers psql, psycopg, SQLAlchemy and LangChain, an existing MCP database server, Cursor or Claude Code, and BI tools. Point the client's connection string at the proxy instead of the database:
pip install "querypilot[proxy]"
querypilot proxy --upstream postgresql://readonly@db/prod --listen 127.0.0.1:6543 --policy querypilot.yaml
psql "postgresql://agent@127.0.0.1:6543/prod" -c "SELECT email FROM customers" npx -y @modelcontextprotocol/server-postgres postgresql://agent@127.0.0.1:6543/prod # unchanged MCP server
Every statement then gets the following:
SET of anything outside a small allowlist are rejected. Allowed statements run in a READ ONLY transaction on a session that defaults to read-only, so COMMIT; DROP TABLE … is rejected.row_filters hold under joins, subqueries and CTEs, and LIMIT is capped at max_rows.masking_rules apply by output position, so upper(email) AS contact is masked too.HINT, for example Column 'nope' does not exist. Columns of orders: id, customer_id, ….--audit-log, with the client's SQL, the SQL that ran, the row count, and the client user and application.Driver handshakes, SET/SHOW of formatting settings, and catalog queries for psql \d and ORM reflection pass through an allowlist. Catalog queries that could read data, such as pg_stats or query_to_xml(...), are rejected. The policy file is a normal querypilot.yaml, and its database_url is used when you omit --upstream. Off loopback, set QUERYPILOT_PROXY_PASSWORD. Protocol coverage, known gaps (no TLS termination yet, no server-side cursors), and the reasons it fails closed are in docs/proxy.md.
querypilot trace and hooksSome query tools can't sit behind QueryPilot, for example Palantir Foundry's MCP SQL tool. For those, QueryPilot reads what the agent did instead. trace import pairs every query tool call in Claude Code transcripts with its result. hooks install logs new calls live. trace doctor reports the failure rate by class, retry chains, latency and stalls, and says for each problem whether it is best fixed in the tool, the prompt, or the data:
querypilot trace doctor # reads ~/.claude/projects
querypilot trace doctor --output report.md # redacted, shareable querypilot hooks install --guard --max-rows 200
With --guard, a PreToolUse hook validates each query against schemas cached from the agent's own schema calls. It denies unknown columns with a "did you mean" reply before the query reaches the warehouse, blocks date arithmetic on DATE columns stored as epoch milliseconds, and enforces a row cap. Foundry's tool is mapped by default; map any other with --tool NAME=SQL_FIELD[:DIALECT]. Recovered retry chains export to eval replay as a regression suite. See docs/trace.md and the first Foundry report.
When QueryPilot writes the SQL itself (ask, ask_database, evals), it uses the techniques with the largest measured gains in the text-to-SQL literature. The sources and numbers are in docs/research/developer-needs.md.
hints= and descriptions= to connect(), or set them in querypilot.yaml, for definitions such as "revenue means paid invoices only".schema_token_budget (default 6000 tokens) the full schema is sent. Above it, QueryPilot sends the relevant tables plus the foreign-key bridge tables that join them.from querypilot import AnthropicSQLGenerator, QueryPilot
qp = QueryPilot.connect( "duckdb:///analytics.duckdb", generator=AnthropicSQLGenerator(), hints=["Revenue means SUM(amount_cents) / 100 over invoices with status = 'paid'"], descriptions={"accounts.segment": "smb, midmarket or enterprise"}, ) answer = qp.ask("Revenue by se