CrateDB MCP Server

$pip install cratedb-mcp
README.md

Connects AI assistants to CrateDB clusters for Text-to-SQL and data analysis.

CrateDB MCP Server

![Status][badge-status] ![CI][badge-ci] ![Coverage][badge-coverage] ![Downloads per month][badge-downloads-per-month]

![License][badge-license] ![Release Notes][badge-release-notes] ![PyPI Version][badge-package-version] ![Python Versions][badge-python-versions]

» Documentation | Issues | Source code | License | CrateDB | CrateDB Handbook | Community Forum

About

The CrateDB MCP Server for natural-language Text-to-SQL and documentation retrieval specializes in CrateDB database clusters. The Model Context Protocol (MCP) is a protocol that standardizes providing context to language models and AI assistants.

The CrateDB Model Context Protocol (MCP) Server connects AI assistants directly to your CrateDB clusters and the CrateDB knowledge base, enabling seamless interaction through natural language.

It serves as a bridge between AI tools and your analytics database, allowing you to analyze data, the cluster state, troubleshoot issues, and perform operations using conversational prompts.

Documentation

The project documentation is available at https://cratedb-mcp.readthedocs.io/. It includes information on how to install and operate the package.

Project information

Acknowledgements

Kudos to the authors of all the many software components and technologies this project is building upon.

Contributing

The cratedb-mcp package is an open-source project, and is managed on GitHub. Contributions of any kind are welcome and appreciated. To learn how to set up a development sandbox, please refer to the development documentation.

Status

The software is in the beta stage, so breaking changes may happen. Version pinning is strongly recommended, especially if you use it as a library.

Tools (3)

query_sqlExecute a SQL query against the CrateDB cluster to retrieve or analyze data.
get_cluster_statusRetrieve information about the health and state of the CrateDB cluster.
search_documentationSearch the CrateDB knowledge base and documentation for technical information.

Environment Variables

CRATEDB_CONNECTION_STRINGrequiredThe connection URI for the CrateDB cluster (e.g., crate://user:pass@host:port)

Configuration

claude_desktop_config.json
{"mcpServers":{"cratedb":{"command":"uvx","args":["cratedb-mcp"],"env":{"CRATEDB_CONNECTION_STRING":"crate://admin:password@localhost:4200"}}}}

Try it

Show me the total number of records in the 'sensors' table grouped by city.
Check the health status of my CrateDB cluster and identify any disconnected nodes.
How do I configure a partitioned table in CrateDB? Search the documentation.
Find the top 10 most expensive queries currently running on the cluster.
Analyze the data in the 'logs' table to find the peak error rate over the last 24 hours.

Frequently Asked Questions

What are the key features of CrateDB MCP Server?

Natural-language Text-to-SQL conversion for CrateDB clusters.. Direct connection to CrateDB knowledge base for documentation retrieval.. Cluster state monitoring and troubleshooting capabilities.. Seamless bridge between AI tools and analytics databases..

What can I use CrateDB MCP Server for?

Data analysts performing ad-hoc queries using conversational English.. Database administrators troubleshooting cluster health and performance issues.. Developers looking for specific CrateDB syntax or configuration guidance from the handbook.. Automated reporting on cluster metrics and table statistics..

How do I install CrateDB MCP Server?

Install CrateDB MCP Server by running: pip install cratedb-mcp

What MCP clients work with CrateDB MCP Server?

CrateDB MCP Server works with any MCP-compatible client including Claude Desktop, Claude Code, Cursor, and other editors with MCP support.

Use CrateDB MCP Server with Conare

Manage MCP servers visually, upload persistent context, and never start from zero with Claude Code & Codex.

Try Free