Skip to main content
Glama
MCP Snowflake Server

MCP Snowflake Server

🚀 Enhanced MCP Snowflake Server v2.0

A powerful Model Context Protocol (MCP) server that provides Claude with comprehensive Snowflake database access capabilities.

GitHub Stars Docker Tools

✨ Enhanced Features

This server provides 7 powerful tools for comprehensive Snowflake exploration:

🔍 Discovery Tools

  • list_databases - Show all available databases

  • list_schemas - List schemas in databases

  • list_tables - Show tables in schemas

  • search_tables - Find tables by pattern

📊 Analysis Tools

  • describe_table - Show detailed table structure

  • get_table_sample - Retrieve sample data

  • execute_query - Run custom SQL queries

🐳 Production Ready

  • Docker containerization with health checks

  • Comprehensive documentation (3 reference formats)

  • Production-grade deployment setup

  • 50+ ready-to-use prompts

Related MCP server: Snowflake MCP Server

🚀 Quick Start

  1. Clone the repository

git clone https://github.com/muthuramanathanm/mcp-snowflake-service.git
cd mcp-snowflake-service
  1. Configure credentials

# Create .env file with your Snowflake credentials
cp .env.example .env
# Edit .env with your actual credentials
  1. Build and run with Docker

docker build -t mcp-snowflake-server .
# The Docker wrapper script handles everything automatically

Option 2: Local Installation

  1. Clone and install dependencies

git clone https://github.com/muthuramanathanm/mcp-snowflake-service.git
cd mcp-snowflake-service
pip install -r requirements.txt

⚙️ Configuration

Cursor IDE MCP Configuration

Add the following to your Cursor MCP configuration file (~/.cursor/mcp.json):

{
  "mcpServers": {
    "snowflake": {
      "mode": "stdio",
      "command": "/path/to/mcp-snowflake-service/docker-mcp-wrapper.sh",
      "cwd": "/path/to/mcp-snowflake-service"
    }
  }
}

Local Python Deployment

{
  "mcpServers": {
    "snowflake": {
      "mode": "stdio", 
      "command": "python",
      "args": ["server.py"],
      "cwd": "/path/to/mcp-snowflake-service"
    }
  }
}

Configuration Notes:

  • Docker approach: Uses the included wrapper script for containerized deployment

  • Local approach: Runs Python directly (requires local Python environment)

  • Update paths: Replace /path/to/mcp-snowflake-service with your actual installation path

Snowflake Credentials

Create a .env file in the project root directory:

SNOWFLAKE_USER=your_username
SNOWFLAKE_PASSWORD=your_password  
SNOWFLAKE_ACCOUNT=your_account.region    # Example: autodesk-stg.us-east-1
SNOWFLAKE_DATABASE=your_database
SNOWFLAKE_WAREHOUSE=your_warehouse

Security Note: Never commit the .env file to version control. Add it to your .gitignore.

🔄 Connection Management

The server provides robust automatic connection management:

  • Automatic initialization

    • Creates connection when first query is received

    • Validates connection parameters and credentials

    • Handles authentication and session setup

  • Connection maintenance

    • Tracks connection state and health

    • Handles connection timeouts gracefully

    • Automatically reconnects if connection is lost

    • Implements retry logic with exponential backoff

  • Resource management

    • Properly closes connections when server stops

    • Releases database resources appropriately

    • Prevents connection leaks and orphaned sessions

📚 Usage & Examples

Natural Language Prompts

The server supports intuitive natural language queries. Here are some examples:

Discovery Commands

  • "What databases are available?"

  • "What schemas are in EDH_PUBLISH database?"

  • "Find tables with 'subscription' in the name"

  • "What tables are in the PARTNER_WEB_SERVICES_PRIVATE schema?"

Analysis Commands

  • "Show me the structure of the ACCOUNT table"

  • "Give me 5 sample rows from the SUBSCRIPTION table"

  • "Describe the CONTRACTLINEITEM_INT table"

Custom SQL

  • "Execute: SELECT COUNT() FROM EDH_PUBLISH.EDH_SHARED.SUBSCRIPTION"*

  • "Run: SELECT * FROM ACCOUNT WHERE ID IS NOT NULL LIMIT 3"

Manual Testing

For development and testing, you can run the server standalone:

# Local testing
python server.py

# Docker testing  
./test-docker-mcp.sh

🌟 Key Features

  • 🔍 7 Powerful Tools - Complete Snowflake exploration toolkit

  • 🐳 Docker Ready - Production-grade containerized deployment

  • 📖 Rich Documentation - 3 comprehensive reference formats

  • 🚀 Natural Language - Intuitive prompts for immediate productivity

  • 🔒 Secure - Robust error handling and credential management

  • ⚡ High Performance - Optimized connection pooling and caching

📁 Documentation

This repository includes comprehensive documentation:

  • MCP_PROMPTS_REFERENCE.md - Complete guide with 50+ examples and workflows

  • QUICK_PROMPTS.txt - Copy-paste ready prompts for immediate use

  • PROMPTS_REFERENCE.json - Structured reference for automation

  • README_DOCKER.md - Detailed Docker deployment guide

🛠️ Development

To contribute or report issues:

  1. Fork this repository

  2. Create your feature branch (git checkout -b feature/AmazingFeature)

  3. Commit your changes (git commit -m 'Add some AmazingFeature')

  4. Push to the branch (git push origin feature/AmazingFeature)

  5. Open a Pull Request

🔐 Security Notes

  • Access Control: Snowflake access is controlled through database user permissions

  • Read-Only Use: For read-only access, use a Snowflake user with read-only permissions

  • Credential Security: Never commit .env files or credentials to version control

  • Network Security: Use appropriate firewall rules and VPN access as needed

📄 License

License: MIT

This project is licensed under the MIT License.


Built with ❤️ for the developer community. Star ⭐ this repo if you find it useful!

Tool Schema Changelog

Recent tool additions, removals, and schema changes observed during successful MCP inspections.

Loading tool schema changelog…

    Related MCP Connectors

    Related MCP Servers

    • A
      license
      B
      quality
      D
      maintenance
      Enables interaction with Snowflake databases through SQL queries, schema exploration, and data analysis. Supports read/write operations, table management, and automatic insight tracking for comprehensive database operations through natural language.
      7
      GPL 3.0
    • A
      license
      Not graded
      quality
      D
      maintenance
      Enables Claude to interact with Snowflake data warehouses through natural language for executing SQL queries, exploring schemas, and monitoring data freshness. It streamlines data analysis workflows by bringing Snowflake capabilities directly into the AI conversation.
      MIT
    • A
      license
      A
      quality
      D
      maintenance
      Enables AI agents to execute SQL queries and explore Snowflake databases using natural language, with schema discovery, table inspection, and readonly mode.
      11
      163 npm
      MIT
    • A
      license
      Not graded
      quality
      D
      maintenance
      Enables read-only querying of Snowflake databases through Claude, supporting multiple authentication methods and SQL operations like SELECT, SHOW, DESCRIBE.
      14
      MIT