DBeaver MCP Server
Integrates with DBeaver to provide AI assistants access to over 200 database types using existing connections.
OmniSQL MCP
Universal database MCP server — give AI assistants read/write access to your databases using connections already saved in your local DB client workspace (DBeaver-compatible).
Database Support
Natively supported (direct driver, fast):
- PostgreSQL (via
pg) - MySQL / MariaDB (via
mysql2) - SQL Server / MSSQL (via
mssql) - SQLite (via
sqlite3CLI)
Postgres-compatible (routed through pg driver automatically):
- CockroachDB, TimescaleDB, Amazon Redshift, YugabyteDB, AlloyDB, Supabase, Neon, Citus
Other databases: Fall back to an external CLI configured via OMNISQL_CLI_PATH. Results vary by CLI.
Features
- Reuses connections already configured in your local DB client workspace — no duplicate setup
- Native query execution for PostgreSQL, MySQL/MariaDB, SQLite, SQL Server
- Connection pooling with configurable pool size and timeouts
- Transaction support (BEGIN/COMMIT/ROLLBACK)
- Query execution plan analysis (EXPLAIN)
- Schema comparison between connections with migration script generation
- Read-only mode with enforced SELECT-only on
execute_query - Connection whitelist to restrict which databases are accessible
- Tool filtering to disable specific operations
- Query validation to block dangerous operations (DROP DATABASE, TRUNCATE, DELETE/UPDATE without WHERE)
- Data export to CSV/JSON
- Graceful shutdown with connection pool cleanup
Requirements
- Node.js 18+
- A local DB client (DBeaver-compatible) with at least one configured connection
Installation
npm install -g omnisql-mcp
Configuration
Claude Desktop
Add to ~/Library/Application Support/Claude/claude_desktop_config.json (macOS):
{
"mcpServers": {
"omnisql": {
"command": "omnisql-mcp"
}
}
}
Claude Code
Add to ~/.claude/settings.json:
{
"mcpServers": {
"omnisql": {
"command": "omnisql-mcp"
}
}
}
Cursor
Add to Cursor Settings > MCP Servers:
{
"mcpServers": {
"omnisql": {
"command": "omnisql-mcp"
}
}
}
Environment Variables
| Variable | Description | Default |
|---|---|---|
OMNISQL_CLI_PATH | Path to external DB client CLI (used for unsupported-driver fallback) | Unset |
OMNISQL_WORKSPACE | Path to local DB client workspace directory | OS default |
OMNISQL_TIMEOUT | Query timeout (ms) | 30000 |
OMNISQL_DEBUG | Enable debug logging | false |
OMNISQL_READ_ONLY | Disable all write operations | false |
OMNISQL_ALLOWED_CONNECTIONS | Comma-separated whitelist of connection IDs or names | All |
OMNISQL_DISABLED_TOOLS | Comma-separated tools to disable | None |
OMNISQL_POOL_MIN | Minimum connections per pool | 2 |
OMNISQL_POOL_MAX | Maximum connections per pool | 10 |
OMNISQL_POOL_IDLE_TIMEOUT | Idle connection timeout (ms) | 30000 |
OMNISQL_POOL_ACQUIRE_TIMEOUT | Connection acquire timeout (ms) | 10000 |
Read-Only Mode
Blocks all write operations. The execute_query tool only allows SELECT, EXPLAIN, SHOW, and DESCRIBE statements. Transaction tools are disabled entirely.
{
"mcpServers": {
"omnisql": {
"command": "omnisql-mcp",
"env": {
"OMNISQL_READ_ONLY": "true"
}
}
}
}
Connection Whitelist
Restrict which workspace connections are visible. Accepts connection IDs or display names, comma-separated:
{
"mcpServers": {
"omnisql": {
"command": "omnisql-mcp",
"env": {
"OMNISQL_ALLOWED_CONNECTIONS": "dev-postgres,staging-mysql"
}
}
}
}
Disable Specific Tools
{
"mcpServers": {
"omnisql": {
"command": "omnisql-mcp",
"env": {
"OMNISQL_DISABLED_TOOLS": "drop_table,alter_table,write_query"
}
}
}
}
Available Tools
Connection Management
list_connections- List all database connectionsget_connection_info- Get connection detailstest_connection- Test connectivity
Data Operations
execute_query- Run read-only queries (SELECT, EXPLAIN, SHOW, DESCRIBE only)write_query- Run INSERT/UPDATE/DELETEexport_data- Export to CSV/JSON
Schema Management
list_tables- List tables and viewsget_table_schema- Get table structurecreate_table- Create tablesalter_table- Modify tablesdrop_table- Drop tables (requires confirmation)
Transactions
begin_transaction- Start a new transactionexecute_in_transaction- Execute query within a transactioncommit_transaction- Commit a transactionrollback_transaction- Roll back a transaction
Query Analysis
explain_query- Analyze query execution plancompare_schemas- Compare schemas between two connectionsget_pool_stats- Get connection pool statistics
Other
get_database_stats- Database statisticsappend_insight- Store analysis noteslist_insights- Retrieve stored notes
Security
- Read-only enforcement:
execute_queryonly accepts read-only statements (SELECT, EXPLAIN, SHOW, DESCRIBE, PRAGMA). Write operations must usewrite_query. - Query validation: Blocks DROP DATABASE, DROP SCHEMA, TRUNCATE, DELETE/UPDATE without WHERE, GRANT, REVOKE, and user management statements.
- Connection whitelist: Restrict which connections are exposed via
OMNISQL_ALLOWED_CONNECTIONS. - Tool filtering: Disable any tool via
OMNISQL_DISABLED_TOOLS. - Input sanitization: Connection IDs and SQL identifiers are sanitized to prevent injection.
- Recommendation: For production use, also use a database-level read-only user for defense in depth.
Workspace Format Support
Supports both configuration formats written by DBeaver-compatible DB clients:
- Legacy: XML config in
.metadata/.plugins/org.jkiss.dbeaver.core/ - Modern: JSON config in
General/.dbeaver/
Credentials are automatically decrypted from the workspace credentials-config.json.
Development
git clone https://github.com/srthkdev/omnisql-mcp.git
cd omnisql-mcp
npm install
npm run build
npm test
npm run lint
License
MIT
Servidores relacionados
MCP Football Server
Provides football (soccer) data using the API-Football service.
MCP ArcKnowledge
Manage and query custom knowledge bases using webhook endpoints.
Apache Gravitino
Access Apache Gravitino, a high-performance, federated metadata lake for data and AI.
dbt
Official MCP server for dbt (data build tool) providing integration with dbt Core/Cloud CLI, project metadata discovery, model information, and semantic layer querying capabilities.
pharma-signal
Drug safety intelligence API with 19 MCP tools. Covers 358 drugs across 1M+ FDA adverse event reports with real-time risk scoring, pharmacovigilance signal detection (PRR/ROR), company portfolio analysis by ticker, and AI-powered analyst briefs. Free tier: 100 calls/day.
Firebolt
Connect your LLM to the Firebolt Data Warehouse for data querying and analysis.
OpenSearch MCP Server
An MCP server for interacting with OpenSearch clusters, configured via environment variables.
PostgreSQL
Provides read-only access to PostgreSQL databases, enabling schema inspection and query execution.
AIND Metadata
Access and interact with Allen Institute for Neural Dynamics (AIND) metadata directly within your IDE.
Supabase Next.js Server
A simple notes system for Next.js applications using Supabase as the backend.