Schema reads and query execution are the whole job, and the reconnection and keep-alive behaviour is what makes it usable across a long conversation rather than only the first few minutes. Whatever the connected database user can do, the assistant can do.
A Python MCP server for CockroachDB. It connects over a JDBC URL, lists tables, returns table structure and executes SQL, with automatic reconnection and a keep-alive so a long session does not drop, plus database status resources and SQL query templates.
- A connection opened from a JDBC URL, username and password (connect_database), or established as soon as the client attaches (initialize_connection)
- Every table in the database listed (get_tables)
- One table's structure returned in full (get_table_schema)
- SQL executed against the cluster (execute_query)
- A manual disconnect when you want the connection closed (disconnect_database)
- Automatic reconnection and a keep-alive, so an idle session does not time out
- Database status exposed as a resource, plus SQL query templates and detailed logging
Python with the repo's requirements and uv, or a one-command install through Smithery. The JDBC URL, username and password go in the client config, and the grants on that database user decide what any query can do.
One command — npx -y @smithery/cli install @Swayingleaves/cockroachdb-mcp-server --client claude
