Database intelligence, AST SQL injection auditing, query optimization & schema guards.
Maintain this server? Claim it
Call this server's tools from your browser. Nothing to install.
Requests go through mcptry because browsers can't call most MCP servers directly. Header values are sent to the server for that request only and are never stored or logged.
Tool list from our last check. Connect live to refresh it.
Analyzes SQL EXPLAIN execution plans to detect sequential table scans, high-cost cartesian joins, and buffer memory bottlenecks. Use when diagnosing slow queries, optimizing database performance, or evaluating query cost; for getting index recommendations, use recommend_database_indexes instead. Stateless read-only edge call (max 32 KB, 60 RPM): accepts 'explain_plan_or_query' ('optimization_target' defaults to 'eliminate_seq_scans'), supports '?demo=true' or L402 (15 sats), and returns HTTP 400 if invalid.
Raw text or JSON output of EXPLAIN / EXPLAIN ANALYZE or the candidate SQL query.
Database engine name (e.g., 'postgres', 'mysql', 'sqlite').
Optimization goal: eliminate sequential scans, reduce memory buffers, or minimize join costs.
Pick your client. Values in capitals, like YOUR_TOKEN, are yours to fill in.
Run in a terminal
claude mcp add --transport http diogenes-database-intelligence-mcp https://diogenesgateway.com/mcp/database-intelligence
Analyzes SQL EXPLAIN execution plans to detect sequential table scans, high-cost cartesian joins, and buffer memory bottlenecks. Use when diagnosing slow queries, optimizing database performance, or evaluating query cost; for getting index recommendations, use recommend_database_indexes instead. Stateless read-only edge call (max 32 KB, 60 RPM): accepts 'explain_plan_or_query' ('optimization_target' defaults to 'eliminate_seq_scans'), supports '?demo=true' or L402 (15 sats), and returns HTTP 400 if invalid.
| Argument | Type | Description |
|---|---|---|
| database_engine | string | Database engine name (e.g., 'postgres', 'mysql', 'sqlite'). |
| optimization_target | string | Optimization goal: eliminate sequential scans, reduce memory buffers, or minimize join costs. |
| explain_plan_or_query* | string | Raw text or JSON output of EXPLAIN / EXPLAIN ANALYZE or the candidate SQL query. |
{
"type": "object",
"required": [
"explain_plan_or_query"
],
"properties": {
"database_engine": {
"type": "string",
"description": "Database engine name (e.g., 'postgres', 'mysql', 'sqlite')."
},
"optimization_target": {
"enum": [
"eliminate_seq_scans",
"reduce_memory_buffers",
"minimize_join_costs"
],
"type": "string",
"description": "Optimization goal: eliminate sequential scans, reduce memory buffers, or minimize join costs."
},
"explain_plan_or_query": {
"type": "string",
"description": "Raw text or JSON output of EXPLAIN / EXPLAIN ANALYZE or the candidate SQL query."
}
}
}Statically parses SQL queries via AST lexical analysis to detect second-order injection, tautology conditions, and stacked queries. Use when auditing dynamic query parameters or untrusted user input before database execution; for sanitizing query strings for telemetry logging, use sanitize_sql_telemetry instead. Stateless read-only edge call (max 32 KB, 60 RPM): accepts 'raw_sql' ('audit_sensitivity' defaults to 'strict_zero_dynamic_taint'), supports '?demo=true' or L402 (10 sats), and returns HTTP 400 if invalid.
| Argument | Type | Description |
|---|---|---|
| raw_sql* | string | Raw SQL query string to parse and audit for injection vulnerabilities. |
| allow_comments | boolean | Whether SQL inline comments are allowed or treated as injection vectors. |
| audit_sensitivity | string | Audit sensitivity mode: strict zero dynamic taint, second order injection check, or standard syntax audit. |
{
"type": "object",
"required": [
"raw_sql"
],
"properties": {
"raw_sql": {
"type": "string",
"description": "Raw SQL query string to parse and audit for injection vulnerabilities."
},
"allow_comments": {
"type": "boolean",
"description": "Whether SQL inline comments are allowed or treated as injection vectors."
},
"audit_sensitivity": {
"enum": [
"strict_zero_dynamic_taint",
"second_order_injection_check",
"standard_syntax_audit"
],
"type": "string",
"description": "Audit sensitivity mode: strict zero dynamic taint, second order injection check, or standard syntax audit."
}
}
}Audits database transaction workflows for concurrency anomalies, dirty reads, non-repeatable reads, and deadlock risks. Use when reviewing financial transfer procedures, inventory decrement operations, or multi-step checkout workflows; for calculating connection pool headroom, use calculate_pool_headroom instead. Stateless read-only edge call (max 32 KB, 60 RPM): accepts 'transaction_steps' ('target_isolation_level' defaults to 'read_committed'), supports '?demo=true' or L402 (15 sats), and returns HTTP 400 if invalid.
| Argument | Type | Description |
|---|---|---|
| transaction_steps* | string | Sequential SQL commands or description of business operations within the transaction. |
| strict_deadlock_check | boolean | Whether to perform exhaustive cross-table lock acquisition ordering analysis. |
| target_isolation_level | string | Candidate SQL isolation level: read committed, repeatable read, or serializable. |
{
"type": "object",
"required": [
"transaction_steps"
],
"properties": {
"transaction_steps": {
"type": "string",
"description": "Sequential SQL commands or description of business operations within the transaction."
},
"strict_deadlock_check": {
"type": "boolean",
"description": "Whether to perform exhaustive cross-table lock acquisition ordering analysis."
},
"target_isolation_level": {
"enum": [
"read_committed",
"repeatable_read",
"serializable"
],
"type": "string",
"description": "Candidate SQL isolation level: read committed, repeatable read, or serializable."
}
}
}Calculates optimal connection pool sizing, idle timeouts, and client headroom based on server RAM and concurrency profile. Use when sizing PgBouncer, HikariCP, or Prisma connection pools to avoid server out-of-memory crashes; for checking transaction isolation hazards, use audit_transaction_isolation instead. Stateless read-only edge call (max 32 KB, 60 RPM): accepts 'server_ram_mb' and 'max_concurrent_clients' ('workload_profile' defaults to 'high_concurrency_oltp'), supports '?demo=true' or L402 (10 sats), and returns HTTP 400 if invalid.
| Argument | Type | Description |
|---|---|---|
| server_ram_mb* | number | Total available RAM in megabytes dedicated to the database server instance. |
| workload_profile | string | Workload operational characteristics: high-concurrency OLTP, heavy analytical OLAP, or serverless edge burst. |
| max_concurrent_clients* | number | Peak anticipated concurrent client connections or serverless worker threads. |
{
"type": "object",
"required": [
"server_ram_mb",
"max_concurrent_clients"
],
"properties": {
"server_ram_mb": {
"type": "number",
"description": "Total available RAM in megabytes dedicated to the database server instance."
},
"workload_profile": {
"enum": [
"high_concurrency_oltp",
"heavy_analytical_olap",
"serverless_edge_burst"
],
"type": "string",
"description": "Workload operational characteristics: high-concurrency OLTP, heavy analytical OLAP, or serverless edge burst."
},
"max_concurrent_clients": {
"type": "number",
"description": "Peak anticipated concurrent client connections or serverless worker threads."
}
}
}Compares source and target DDL schemas to identify breaking changes, destructive column drops, and lock-inducing mutations. Use when verifying CI/CD migration scripts before production deployment to prevent downtime; for verifying relational normal form, use validate_schema_normalization instead. Stateless read-only edge call (max 32 KB, 60 RPM): accepts 'current_schema' and 'target_schema' ('risk_tolerance' defaults to 'zero_downtime_strict'), supports '?demo=true' or L402 (15 sats), and returns HTTP 400 if invalid.
| Argument | Type | Description |
|---|---|---|
| target_schema* | string | Proposed new database DDL schema representing target migration state. |
| current_schema* | string | Current production database DDL schema representing live tables and columns. |
| risk_tolerance | string | Deployment safety policy: zero downtime strict, allow transient locks, or permissive dev. |
{
"type": "object",
"required": [
"current_schema",
"target_schema"
],
"properties": {
"target_schema": {
"type": "string",
"description": "Proposed new database DDL schema representing target migration state."
},
"current_schema": {
"type": "string",
"description": "Current production database DDL schema representing live tables and columns."
},
"risk_tolerance": {
"enum": [
"zero_downtime_strict",
"allow_transient_locks",
"permissive_dev"
],
"type": "string",
"description": "Deployment safety policy: zero downtime strict, allow transient locks, or permissive dev."
}
}
}Compiles SQL DDL schemas into type-safe ORM entities and TypeScript validation schemas (Prisma, Drizzle, SQLAlchemy, Zod). Use when scaffolding application models, generating TypeScript data layers, or synchronizing schemas; for translating raw SQL across dialects, use transpile_sql_dialect instead. Stateless read-only edge call (max 32 KB, 60 RPM): accepts 'schema_ddl' ('orm_target' defaults to 'drizzle_orm_typescript'), supports '?demo=true' or L402 (15 sats), and returns HTTP 400 if invalid.
| Argument | Type | Description |
|---|---|---|
| orm_target | string | Target ORM framework standard: Prisma schema, Drizzle ORM TypeScript, SQLAlchemy Python 2.0, or Zod types. |
| schema_ddl* | string | Database schema DDL statements defining tables, primary keys, and relationships. |
| include_relations | boolean | Whether to generate explicit foreign key relation decorators and navigation properties. |
{
"type": "object",
"required": [
"schema_ddl"
],
"properties": {
"orm_target": {
"enum": [
"prisma_schema",
"drizzle_orm_typescript",
"sqlalchemy_python_2_0",
"zod_types_validation"
],
"type": "string",
"description": "Target ORM framework standard: Prisma schema, Drizzle ORM TypeScript, SQLAlchemy Python 2.0, or Zod types."
},
"schema_ddl": {
"type": "string",
"description": "Database schema DDL statements defining tables, primary keys, and relationships."
},
"include_relations": {
"type": "boolean",
"description": "Whether to generate explicit foreign key relation decorators and navigation properties."
}
}
}Recommends optimal single-column and composite B-Tree/BRIN indexes based on slow query WHERE, JOIN, and ORDER BY clauses. Use when optimizing database response times and eliminating full-table scans; for inspecting full execution plans, use analyze_query_plan instead. Stateless read-only edge call (max 32 KB, 60 RPM): accepts 'slow_queries_or_workload' ('index_type_preference' defaults to 'btree_and_composite'), supports '?demo=true' or L402 (15 sats), and returns HTTP 400 if invalid.
| Argument | Type | Description |
|---|---|---|
| max_new_indexes | integer | Maximum number of index creation statements to recommend. |
| index_type_preference | string | Target indexing strategy: B-tree and composite, BRIN and GIN sparse, or covering indexes with INCLUDE. |
| slow_queries_or_workload* | string | Collection of slow SQL queries or workload log statements to analyze for index gaps. |
{
"type": "object",
"required": [
"slow_queries_or_workload"
],
"properties": {
"max_new_indexes": {
"type": "integer",
"description": "Maximum number of index creation statements to recommend."
},
"index_type_preference": {
"enum": [
"btree_and_composite",
"brin_and_gin_sparse",
"covering_indexes_include"
],
"type": "string",
"description": "Target indexing strategy: B-tree and composite, BRIN and GIN sparse, or covering indexes with INCLUDE."
},
"slow_queries_or_workload": {
"type": "string",
"description": "Collection of slow SQL queries or workload log statements to analyze for index gaps."
}
}
}Masks PII, financial values, and credential literals from raw SQL query logs and slow-query dumps before telemetry storage. Use when scrubbing production database query logs before shipping to APM tools, Datadog, or external log collectors; for auditing SQL injection vulnerabilities, use audit_sql_injection_ast instead. Stateless read-only edge call (max 32 KB, 60 RPM): accepts 'query_logs' ('masking_policy' defaults to 'mask_pii_and_literals'), supports '?demo=true' or L402 (10 sats), and returns HTTP 400 if invalid.
| Argument | Type | Description |
|---|---|---|
| hash_salt | string | Optional salt string for deterministic pseudonymization of user IDs. |
| query_logs* | string | Raw SQL query text or multi-line database query log strings requiring sanitization. |
| masking_policy | string | Scrubbing rigor policy: mask PII and literals, anonymize all constants, or strict AST parameterization. |
{
"type": "object",
"required": [
"query_logs"
],
"properties": {
"hash_salt": {
"type": "string",
"description": "Optional salt string for deterministic pseudonymization of user IDs."
},
"query_logs": {
"type": "string",
"description": "Raw SQL query text or multi-line database query log strings requiring sanitization."
},
"masking_policy": {
"enum": [
"mask_pii_and_literals",
"anonymize_all_constants",
"strict_ast_parameterization"
],
"type": "string",
"description": "Scrubbing rigor policy: mask PII and literals, anonymize all constants, or strict AST parameterization."
}
}
}Generates deterministic relational test seed fixtures respecting foreign key constraints, unique indexes, and data bounds. Use when provisioning mock database datasets for automated testing, staging environments, or sandbox demos; for compiling ORM models from schemas, use generate_orm_models instead. Stateless read-only edge call (max 32 KB, 60 RPM): accepts 'schema_ddl' ('fixture_volume' defaults to 'minimal_smoke_test_5'), supports '?demo=true' or L402 (15 sats), and returns HTTP 400 if invalid.
| Argument | Type | Description |
|---|---|---|
| schema_ddl* | string | Target database schema DDL defining tables, column types, and foreign key relations. |
| fixture_volume | string | Mock dataset volume profile: minimal smoke test (5), standard dataset (50), or stress dataset (500). |
| deterministic_seed | integer | Integer seed for reproducible pseudo-random data generation. |
{
"type": "object",
"required": [
"schema_ddl"
],
"properties": {
"schema_ddl": {
"type": "string",
"description": "Target database schema DDL defining tables, column types, and foreign key relations."
},
"fixture_volume": {
"enum": [
"minimal_smoke_test_5",
"standard_dataset_50",
"stress_dataset_500"
],
"type": "string",
"description": "Mock dataset volume profile: minimal smoke test (5), standard dataset (50), or stress dataset (500)."
},
"deterministic_seed": {
"type": "integer",
"description": "Integer seed for reproducible pseudo-random data generation."
}
}
}Translates natural language questions into dialect-accurate, optimized SQL SELECT queries with schema awareness and safety checks. Use when generating reporting queries or automated data analytics pipelines; for analyzing SQL execution performance and EXPLAIN plans, use analyze_query_plan instead. Stateless read-only edge call (max 32 KB, 60 RPM): accepts 'natural_language_request' and 'schema_ddl' ('sql_dialect' defaults to 'postgresql_dialect'), supports '?demo=true' or L402 (15 sats), and returns HTTP 400 if invalid.
| Argument | Type | Description |
|---|---|---|
| schema_ddl* | string | Database schema DDL statements defining available tables, columns, and relations. |
| sql_dialect | string | Target SQL dialect specification: PostgreSQL dialect, MySQL dialect, or SQLite dialect. |
| read_only_mode | boolean | Whether to enforce strict read-only SELECT query constraints. |
| natural_language_request* | string | Natural language question or reporting requirement to transform into SQL. |
{
"type": "object",
"required": [
"natural_language_request",
"schema_ddl"
],
"properties": {
"schema_ddl": {
"type": "string",
"description": "Database schema DDL statements defining available tables, columns, and relations."
},
"sql_dialect": {
"enum": [
"postgresql_dialect",
"mysql_dialect",
"sqlite_dialect"
],
"type": "string",
"description": "Target SQL dialect specification: PostgreSQL dialect, MySQL dialect, or SQLite dialect."
},
"read_only_mode": {
"type": "boolean",
"description": "Whether to enforce strict read-only SELECT query constraints."
},
"natural_language_request": {
"type": "string",
"description": "Natural language question or reporting requirement to transform into SQL."
}
}
}Transpiles SQL queries and DDL schemas across PostgreSQL, MySQL, and SQLite dialects, rewriting functions and syntax quirks. Use when migrating application queries across database backends or testing against in-memory SQLite; for generating new queries from natural language, use synthesize_sql_query instead. Stateless read-only edge call (max 32 KB, 60 RPM): accepts 'sql_code' and 'source_dialect' ('target_dialect' defaults to 'sqlite'), supports '?demo=true' or L402 (10 sats), and returns HTTP 400 if invalid.
| Argument | Type | Description |
|---|---|---|
| sql_code* | string | SQL query or DDL statement to convert from source dialect into target dialect. |
| source_dialect* | string | Original SQL dialect of the input code: postgresql, mysql, or sqlite. |
| target_dialect* | string | Destination SQL dialect to transpile into: postgresql, mysql, or sqlite. |
{
"type": "object",
"required": [
"sql_code",
"source_dialect",
"target_dialect"
],
"properties": {
"sql_code": {
"type": "string",
"description": "SQL query or DDL statement to convert from source dialect into target dialect."
},
"source_dialect": {
"enum": [
"postgresql",
"mysql",
"sqlite"
],
"type": "string",
"description": "Original SQL dialect of the input code: postgresql, mysql, or sqlite."
},
"target_dialect": {
"enum": [
"postgresql",
"mysql",
"sqlite"
],
"type": "string",
"description": "Destination SQL dialect to transpile into: postgresql, mysql, or sqlite."
}
}
}Audits database schemas for third normal form (3NF) compliance, transitive dependencies, and missing foreign key constraints. Use when reviewing database architectures, preventing update anomalies, or validating relational integrity; for detecting breaking schema migrations, use detect_breaking_migrations instead. Stateless read-only edge call (max 32 KB, 60 RPM): accepts 'schema_ddl' ('target_normal_form' defaults to 'third_normal_form_3nf'), supports '?demo=true' or L402 (10 sats), and returns HTTP 400 if invalid.
| Argument | Type | Description |
|---|---|---|
| schema_ddl* | string | Database schema DDL statements defining table columns, primary keys, and relations. |
| strict_keys | boolean | Whether to enforce explicit foreign key constraints on all ID references. |
| target_normal_form | string | Target normalization standard: 3NF, Boyce-Codd BCNF, or denormalized OLAP star. |
{
"type": "object",
"required": [
"schema_ddl"
],
"properties": {
"schema_ddl": {
"type": "string",
"description": "Database schema DDL statements defining table columns, primary keys, and relations."
},
"strict_keys": {
"type": "boolean",
"description": "Whether to enforce explicit foreign key constraints on all ID references."
},
"target_normal_form": {
"enum": [
"third_normal_form_3nf",
"boyce_codd_bcnf",
"denormalized_olap_star"
],
"type": "string",
"description": "Target normalization standard: 3NF, Boyce-Codd BCNF, or denormalized OLAP star."
}
}
}We read every tool's name, description and inputs the way the model will, looking for instructions hidden from you. A clean result means no warning signs, not a guarantee. Scanned Nov 24, 2026.