mcpField
D
Dremio Python MCP

Dremio Python MCP

Local
github.com/ucesysDatabases1Updated 80w ago

About Dremio Python MCP

Dremio Python MCP provides MCP clients with a standard interface to Dremio databases, for users who need to browse catalogs or query data. It supports read-only SQL and exposes catalog, schema, table, and table-structure information.

Key features

  1. 01Lists catalogs, schemas, and tables
  2. 02Retrieves table schema information
  3. 03Runs SQL and returns structured results
  4. 04Restricts queries to read-only operations
  5. 05Supports TLS and password or token authentication

Use cases

  1. 01Browse a Dremio data catalog
  2. 02Inspect table fields and schemas
  3. 03Run read-only SQL queries and review results

MCP support

The MCP server exposes Dremio data resources and tools for listing catalogs, schemas, and tables, as well as executing SQL.

Configuration

Local server config is the same for every client. Copy it into your client’s MCP config file.

No install method listed yet

We haven’t collected a package or remote endpoint for this server. Follow the instructions in the project README.

Repository

Tools

No tool list yet

Local servers expose tools only once running on your machine, and the maintainer has not provided a tool list.

Details

From the project README

Dremio Model-Context Protocol (MCP)

This project implements a Model-Context Protocol (MCP) server for Dremio. It provides a standardized way to interact with Dremio databases through the MCP.

Features

Resources

Exposes Dremio data through Resources:

  • dremio://catalogs - Lists all catalogs
  • dremio://schemas/{catalog} - Lists all schemas in a catalog
  • dremio://tables/{catalog}/{schema} - Lists all tables in a schema
  • dremio://schema/{table_name} - Gets schema information for a table
Tools
  • list_catalogs

    • Lists all available catalogs in Dremio
    • Usage: list_catalogs()
  • list_schemas

    • Lists all schemas in a specific catalog
    • Usage: list_schemas("catalog_name")
  • list_tables

    • Lists all tables in a specific schema
    • Usage: list_tables("catalog_name", "schema_name")
  • execute_sql

    • Executes a SQL query against Dremio
    • Returns results in a structured format with metadata
    • Usage: execute_sql("SELECT * FROM catalog.schema.table LIMIT 10")

Requirements

  • Python 3.10+
  • Dremio instance (Cloud or Software)
  • PyArrow with Flight support

Installation

Using pip
pip install -e .
Using uv (recommended)
# Install uv if you don't have it
curl -sSf https://astral.sh/uv/install.sh | bash

# Install the package
uv pip install -e .

Configuration

Create a config.yaml file in the root directory with the following configuration:

# Dremio connection settings
dremio:
  # Connection type: 'software' for Dremio Software or 'cloud' for Dremio Cloud
  type: software

  # Dremio Software connection details
  software:
    hostname: localhost
    port: 32010
    username: your_username
    password: your_password
    use_ssl: false

# Query settings
query:
  # Maximum number of rows to return in a query result
  max_rows: 10000
  # Maximum number of columns to return in schema request
  max_columns: 1000
  # Timeout in seconds for query execution
  timeout: 300
Environment Variables

You can also configure the server using environment variables:

DREMIO_HOSTNAME=localhost
DREMIO_PORT=32010
DREMIO_USERNAME=your_username
DREMIO_PASSWORD=your_password
DREMIO_USE_SSL=false

For Dremio Cloud:

DREMIO_TYPE=cloud
DREMIO_ENDPOINT=data.dremio.cloud
DREMIO_PAT_TOKEN=your_personal_access_token

Usage

Running the Server
# If installed from package
mcp-dremio-server

# Or run directly
python run_mcp_server.py
Integration with Claude or Other MCP Clients

Add the following configuration to your MCP client settings:

MacOS
// ~/Library/Application\ Support/Claude/claude_desktop_config.json
{
  "mcpServers": {
    "dremio_service": {
      "command": "/Users/USERNAME/.local/bin/uv",
      "args": [
                "--directory",
                "/Users/USERNAME/PycharmProjects/dremio-python-mcp",
                "run",
                "run_mcp_server.py"
            ]
    }
  }
}
Windows
// %APPDATA%/Claude/claude_desktop_config.json
{
  "mcpServers": {
    "dremio-mcp": {
      "command": "mcp-dremio-server",
      "args": []
    }
  }
}

Example Usage

Listing Catalogs and Schemas
// List all catalogs
list_catalogs()

// List schemas in a catalog
list_schemas("my_catalog")

// List tables in a schema
list_tables("my_catalog", "my_schema")
Executing SQL Queries
// Execute a query
results = execute_sql("SELECT * FROM my_catalog.my_schema.my_table LIMIT 10")

Security Features

  • SQL Validation: Prevents execution of non-read-only queries
  • Input Validation: Prevents SQL injection via table/schema names
  • TLS Support: Secure communication with Dremio
  • Authentication: Support for username/password and token authentication

Debugging

Since MCP servers run over stdio, debugging can be challenging. For the best debugging experience, use the MCP Inspector:

npx @modelcontextprotocol/inspector mcp-dremio-server

Upon launching, the Inspector will display a URL that you can access in your browser to begin debugging.

License

This project is licensed under the MIT License - see the LICENSE file for details.

Comments

Markdown supported

New to MCP?

From what the protocol is to installing your first server, these answers cover most first questions.

An open protocol that defines how AI applications connect to external tools and data in a uniform way. Clients talk to the model; MCP servers provide tools, resources and prompt templates. They exchange standard messages, so one server can be reused by many clients.