Kusto MCP Server
Enables GitHub Copilot in VS Code to interact with Azure Data Explorer through KQL queries and schema exploration.
Click on "Deploy Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@Kusto MCP Server show top 10 states from StormEvents"
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
Kusto MCP Server
An MCP (Model Context Protocol) server that provides tools for interacting with Azure Data Explorer (Kusto) clusters. Query, manage connections, and explore schemas using AI assistants like Claude and GitHub Copilot.
Features
Execute KQL queries and scripts
Manage multiple cluster connections
Explore database schemas
Full Azure authentication support
Works with Claude Desktop, Claude Code CLI, and VS Code with GitHub Copilot
Related MCP server: Kusto MCP Server
Prerequisites
Node.js 18+
.NET 8 Runtime
Kusto CLI (
microsoft.azure.kusto.toolsNuGet package)Azure CLI (for authentication)
Install Kusto CLI
dotnet tool install -g Microsoft.Azure.Kusto.ToolsOr via NuGet:
nuget install microsoft.azure.kusto.tools -Version 14.0.3Installation
Via npm (recommended)
npm install -g kusto-mcp-serverVia npx (no installation required)
npx kusto-mcp-serverUsage with AI Assistants
Claude Desktop
Add to your Claude Desktop configuration:
Windows:
%APPDATA%\Claude\claude_desktop_config.jsonmacOS:
~/Library/Application Support/Claude/claude_desktop_config.jsonLinux:
~/.config/claude/claude_desktop_config.json
{
"mcpServers": {
"kusto": {
"command": "npx",
"args": ["-y", "kusto-mcp-server"],
"env": {
"KUSTO_CLI_PATH": "~/.nuget/packages/microsoft.azure.kusto.tools/14.0.3/tools/net8.0/Kusto.Cli.dll"
}
}
}
}Claude Code (CLI)
claude mcp add kusto -- npx -y kusto-mcp-serverVerify it's connected:
claude mcp listVS Code with GitHub Copilot
Add to your VS Code settings.json (or .vscode/mcp.json in your workspace):
{
"mcp": {
"servers": {
"kusto": {
"command": "npx",
"args": ["-y", "kusto-mcp-server"],
"env": {
"KUSTO_CLI_PATH": "~/.nuget/packages/microsoft.azure.kusto.tools/14.0.3/tools/net8.0/Kusto.Cli.dll"
}
}
}
}
}Or use the VS Code command palette:
Open Command Palette (
Ctrl+Shift+P/Cmd+Shift+P)Run "MCP: Add Server"
Select "Command (stdio)"
Enter command:
npx -y kusto-mcp-serverEnter server ID:
kusto
Authentication
Before using the server, authenticate with Azure:
az loginAvailable Tools
Query Tools
Tool | Description |
| Execute KQL queries (primary tool) |
| Advanced execution with full CLI options |
| Execute script files |
Connection Management
Tool | Description |
| Add/update a named connection |
| List all configured connections |
| Test connectivity |
| Remove a connection |
| Set the default connection |
Schema & Help
Tool | Description |
| Get database schema information |
| Get help and CLI options |
Usage Examples
Add a Connection
kusto_connection_add({
name: "my-cluster",
cluster: "https://mycluster.kusto.windows.net",
database: "MyDatabase",
authMethod: "azcli",
isDefault: true
})Execute a Query
kusto_query({
query: "StormEvents | summarize count() by State | top 10 by count_",
connectionName: "my-cluster"
})Get Schema
kusto_schema({
scope: "tables",
connectionName: "my-cluster"
})Execute Multiple Commands
kusto_execute({
commands: [
".show tables",
"StormEvents | count"
],
connectionName: "my-cluster"
})Configuration
Environment variables:
Variable | Description | Default |
| Path to Kusto.Cli.dll | Auto-detected |
| Default query timeout (ms) | 60000 |
| Default max rows | 10000 |
Development
# Clone the repository
git clone https://github.com/yeshsurya/kusto-mcp-server.git
cd kusto-mcp-server
# Install dependencies
npm install
# Build
npm run build
# Watch mode
npm run dev
# Run tests
npm testLicense
MIT
Available Tools
10 toolskusto_connection_addB
Add or update a named connection configuration for Azure Data Explorer.
Inputs: name (required), cluster (required), database (required), authMethod, +2 more.
kusto_connection_listA
List all configured Kusto connections.
Inputs: no named parameters.
kusto_connection_removeB
Remove a saved connection configuration.
Inputs: name (required).
kusto_connection_set_defaultC
Set a connection as the default.
Inputs: name (required).
kusto_connection_testB
Test connectivity to a Kusto cluster using a saved connection.
Inputs: connectionName.
kusto_executeA
Execute advanced Kusto commands with full CLI options. Use this for control commands, multiple statements, or when you need fine-grained control.
Inputs: commands (required), connectionName, connectionString, database, +5 more.
kusto_helpB
Get help information about the Kusto CLI and available options.
Inputs: verbose, category.
kusto_queryC
Execute a KQL (Kusto Query Language) query against an Azure Data Explorer cluster. This is the primary tool for running queries.
Inputs: query (required), connectionName, database, maxRows, +2 more.
kusto_schemaA
Get database schema information including tables, columns, and their types.
Inputs: scope (required), tableName, connectionName, database.
kusto_scriptC
Execute a Kusto script file containing multiple KQL statements. Useful for running saved queries or batch operations.
Inputs: scriptPath (required), connectionName, database, multiLine, +3 more.
Tool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections.
Loading tool schema changelog…
TDQS
Scored across 10 tools
All tools are clearly distinct: connection management (add, list, remove, set_default, test), query execution (query, execute, script), schema retrieval, and help. No overlapping purposes.
All tools follow a consistent 'kusto_verb_noun' pattern using snake_case, making it easy to predict tool names and understand their roles.
10 tools is appropriate for a database query server, covering connection management, query execution, scripting, schema, and help without being excessive or insufficient.
Core workflows are covered (connection CRUD, query, script, schema, help). Missing explicit update for connections (though add serves upsert) and possibly a dedicated list-databases tool, but schema provides that info.
Maintenance
Related MCP Connectors
The MCP server for Azure DevOps, bringing the power of Azure DevOps directly to your agents.
MCP server for progressive tool usage at any scale (see https://klavis.ai)
MCP server for Klever blockchain smart contract development.
Related MCP Servers
- AlicenseNot gradedqualityDmaintenanceMCP Server for interacting with Cube semantic layers that provides tools for querying and describing data from Cube deployments.15GPL 3.0
- AlicenseBqualityDmaintenanceAn MCP server that provides access to Azure Data Explorer (ADX) clusters, allowing users to list tables, execute queries, and retrieve schema information.71MIT
- FlicenseNot gradedqualityDmaintenanceMCP server for executing Kusto Query Language (KQL) queries against Azure Data Explorer clusters, integrating with Claude Desktop and VS Code via Azure CLI authentication.-
- AlicenseNot gradedqualityDmaintenanceAn MCP server that exposes core Azure services as read-mostly tools any MCP client can call, including Blob Storage, Key Vault, Service Bus, and Resource Manager.1MIT