universal-db-mcp
v1.1.2Security-first MCP server for PostgreSQL, SQLite, MySQL, DuckDB with SQL injection prevention.
These tools were reported by the server itself during our smoke test (tools/list), not copied from the README.
query Query
Execute a SQL query against the database. Supports parameterized queries for injection safety. In read-only mode, destructive operations (INSERT, UPDATE, DELETE, DROP, etc.) are blocked.
| Parameter | Type | Description |
|---|---|---|
sql * | string | SQL query to execute |
database | Database key (format: "type:name"). Required when multiple databases are configured. | |
params | Optional list of parameters for parameterized queries (use instead of string formatting) |
schema Schema
Get database schema information: tables, columns, types, and constraints.
| Parameter | Type | Description |
|---|---|---|
database | Database key (format: "type:name") | |
tables | Optional list of specific table names to inspect |
explain Explain
Get query execution plan without running the query.
| Parameter | Type | Description |
|---|---|---|
sql * | string | SQL query to analyze |
database | Database key (format: "type:name") | |
params | Optional parameters for the query |
health Health
Check database connection health and get server version info.
| Parameter | Type | Description |
|---|---|---|
database | Database key (format: "type:name") |
query_history Query History
Get recent query execution history (most recent first).
| Parameter | Type | Description |
|---|---|---|
limit | integer | Maximum number of history entries to return (default 10) |
snapshot_schema Snapshot Schema
Take a snapshot of the current database schema for later drift detection.
| Parameter | Type | Description |
|---|---|---|
database | Database key (format: "type:name") |
schema_diff Schema Diff
Compare the current schema against the last snapshot taken with snapshot_schema.
| Parameter | Type | Description |
|---|---|---|
database | Database key (format: "type:name") |
list_databases List Databases
List all configured databases and their connection status.