Model Context Protocol (MCP) is a standardized protocol designed to manage context between large language models (LLMs) and external systems. This repository provides an installer and an MCP Server for Singlestore, enabling seamless integration.
With MCP, you can use Claude Desktop, Cursor, or any compatible MCP client to interact with SingleStore using natural language, making it easier to perform complex operations effortlessly.
- Python >= v3.11.0
- uvx installed on your python environment
- Claude Desktop, Cursor, or another supported LLM client
The simplest way to set up the MCP server is to use the initialization command:
uvx singlestore-mcp-server init
This command will:
- Automatically locate the configuration file for your platform
- Create or update the configuration to include the SingleStore MCP server
- Configure browser-based OAuth authentication
- Provide instructions for starting the server
To specify a client (e.g., claude
or cursor
), use the --client
flag:
uvx singlestore-mcp-server init --client=<client>
To install mcp-server-singlestore
automatically via Smithery:
npx -y @smithery/cli install @singlestore-labs/mcp-server-singlestore --client=<client>
Replace <client>
with claude
or cursor
as needed.
- Add the following configuration to your client configuration file. Check the client's configuration file here:
-
{ "mcpServers": { "singlestore-mcp-server": { "command": "uvx", "args": [ "singlestore-mcp-server", "start" ] } } }
No API keys, tokens, or environment variables required! The server automatically handles authentication via browser OAuth when started.
- Restart your client after making changes to the configuration.
The server implements the following tools:
- workspace_groups_info: Retrieve details about the workspace groups accessible to the user
- No arguments required
- Returns details of the workspace groups
- workspaces_info: Retrieve details about the workspaces in a specific workspace group
- Arguments:
workspaceGroupID
(string) - Returns details of the workspaces
- Arguments:
- organization_info: Retrieve details about the user's current organization
- No arguments required
- Returns details of the organization
- list_of_regions: Retrieve a list of all regions that support workspaces for the user
- No arguments required
- Returns a list of regions
- execute_sql: Execute SQL operations on a connected workspace
- Arguments:
workspace_group_identifier
,workspace_identifier
,username
,password
,database
,sql_query
- Returns the results of the SQL query in a structured format
- Arguments:
- list_virtual_workspaces: List all starter workspaces accessible to the user
- No arguments required
- Returns details of available starter workspaces
- create_virtual_workspace: Create a new starter workspace with a user
- Arguments:
name
: Name of the starter workspacedatabase_name
: Name of the database to createusername
: Username for accessing the workspacepassword
: Password for the userworkspace_group
: Object containingname
(optional) andcellID
(mandatory)
- Returns details of the created workspace and user
- Arguments:
- execute_sql_on_virtual_workspace: Execute SQL operations on a virtual workspace
- Arguments:
virtual_workspace_id
,username
,password
,sql_query
- Returns the results of the SQL query in a structured format including data, row count, columns, and status
- Arguments:
- list_notebook_samples: List all notebook samples available in SingleStore Spaces
- No arguments required
- Returns details of available notebook samples
- create_notebook: Create a new notebook in the user's personal space
- Arguments:
notebook_name
,content
(optional) - Returns details of the created notebook
- Arguments:
- list_personal_files: List all files in the user's personal space
- No arguments required
- Returns details of all files in the user's personal space
- create_scheduled_job: Create a new scheduled job to run a notebook
- Arguments:
name
: Name for the jobnotebook_path
: Path to the notebook to executeschedule_mode
: Once or Recurringexecution_interval_minutes
: Minutes between executions (optional)start_at
: When to start the job (optional)description
: Description of the job (optional)create_snapshot
: Whether to create notebook snapshots (optional)runtime_name
: Name of the runtime environmentparameters
: Parameters for the job (optional)target_config
: Target configuration for the job (optional)
- Returns details of the created job
- Arguments:
- get_job_details: Get details about a specific job
- Arguments:
job_id
- Returns detailed information about the specified job
- Arguments:
- list_job_executions: List execution history for a specific job
- Arguments:
job_id
,start
(optional),end
(optional) - Returns execution history for the specified job
- Arguments:
- Python >= 3.11
- uv for dependency management
- Clone the repository:
git clone https://github.com/singlestore-labs/mcp-server-singlestore.git
cd mcp-server-singlestore
- Install dependencies:
uv sync --dev
- Set up pre-commit hooks (optional but recommended):
uv run pre-commit install
# Quick quality checks (fast feedback)
./scripts/check.sh
# Run tests independently
./scripts/test.sh
# Comprehensive validation (before PRs)
./scripts/check-all.sh
# Create and publish releases
./scripts/release.sh
# Run test suite with coverage
./scripts/test.sh
# Or use pytest directly
uv run pytest
uv run pytest --cov=src --cov-report=html
We use Ruff for both linting and formatting:
# Format code
uv run ruff format src/ tests/
# Lint code
uv run ruff check src/ tests/
# Lint and fix issues automatically
uv run ruff check --fix src/ tests/
Releases are managed through git tags and automated PyPI publication:
- Create release:
./scripts/release.sh
(interactive tool) - Automatic publication: Triggered by pushing version tags
- No manual PyPI uploads - fully automated pipeline
See scripts/dev-workflow.md
for detailed workflow documentation.
To build the Docker image for the MCP server, run the following command in the project root:
docker build -t mcp-server-singlestore .
To run the Docker container, use the following command:
docker run -d \
-p 8000:8000 \
--name mcp-server \
mcp-server-singlestore