Skip to main content
Glama
patrickfreyer

snowflake-mcp

Node-based Snowflake MCP

License: MIT CI

A TypeScript-based MCP (Model Context Protocol) server that enables Large Language Models (LLMs) like Claude to directly query and interact with Snowflake databases.

๐ŸŒŸ Features

  • ๐Ÿ”Œ Easy Integration - Simple setup with Claude Desktop, Cursor, or any MCP-compatible tool

  • ๐Ÿ”’ Secure - Multiple authentication methods including environment variables and key-pair authentication

  • ๐Ÿš€ High Performance - Built with TypeScript and the native Snowflake Node.js driver

  • ๐Ÿ“Š Full Database Access - Query, explore schemas, list tables, and analyze data

  • ๐Ÿ› ๏ธ Developer Friendly - Comprehensive TypeScript types and error handling

Related MCP server: Snowflake MCP Server

๐Ÿ“‹ Prerequisites

  • Node.js 18 or higher

  • npm or yarn

  • Snowflake account with appropriate access permissions

  • MCP-compatible client (Claude Desktop, Cursor, Continue, etc.)

๐Ÿš€ Quick Start

Installation Options

The easiest way to install this MCP server in Claude Desktop is using the pre-built MCPB package:

  1. Download the latest release:

    • Go to Releases

    • Download the snowflake-mcp-v1.0.0.mcpb file

  2. Install in Claude Desktop:

    • Open Claude Desktop

    • Navigate to Settings โ†’ Developer โ†’ MCP Servers

    • Click "Install from file"

    • Select the downloaded .mcpb file

    • Configure your Snowflake credentials when prompted

Option 2: Build MCPB Package from Source

# Clone the repository
git clone https://github.com/patrickfreyer/mcp-server-snowflake.git
cd mcp-server-snowflake

# Install dependencies
npm install

# Build the TypeScript server
npm run build

# Create the MCPB package
./build-mcpb.sh

# The package will be created as snowflake-mcp-v1.0.0.mcpb
# Install this file in Claude Desktop as described above

Option 3: Manual Installation (For Development)

# Clone the repository
git clone https://github.com/patrickfreyer/mcp-server-snowflake.git
cd mcp-server-snowflake

# Install dependencies
npm install

# Build the server
npm run build

Configuration

Configuration depends on your installation method:

For MCPB Package Users

When you install the MCPB package, Claude Desktop will automatically prompt you for:

  • Snowflake Account (e.g., your-account.region.provider)

  • Warehouse name

  • Username (typically your email)

  • Password

  • Role (optional)

  • Database (optional)

  • Schema (optional)

These credentials are securely stored in Claude Desktop's configuration.

For Manual Installation

  1. Set up environment variables:

# Copy the example environment file
cp .env.example .env

# Edit .env with your Snowflake credentials
SNOWFLAKE_ACCOUNT=your-account.region.provider
SNOWFLAKE_USER=your.email@company.com
SNOWFLAKE_PASSWORD=your-password
SNOWFLAKE_WAREHOUSE=YOUR_WAREHOUSE  # Optional
SNOWFLAKE_DATABASE=YOUR_DATABASE     # Optional
SNOWFLAKE_SCHEMA=YOUR_SCHEMA        # Optional
SNOWFLAKE_ROLE=YOUR_ROLE           # Optional
  1. Configure your MCP client:

Claude Desktop

Add to ~/Library/Application Support/Claude/claude_desktop_config.json:

{
  "mcpServers": {
    "snowflake": {
      "command": "node",
      "args": ["/absolute/path/to/mcp-server-snowflake/dist/index.js"],
      "env": {
        "SNOWFLAKE_ACCOUNT": "your-account.region.provider",
        "SNOWFLAKE_USER": "your.email@company.com",
        "SNOWFLAKE_PASSWORD": "your-password",
        "SNOWFLAKE_WAREHOUSE": "YOUR_WAREHOUSE",
        "SNOWFLAKE_DATABASE": "YOUR_DATABASE",
        "SNOWFLAKE_SCHEMA": "YOUR_SCHEMA",
        "SNOWFLAKE_ROLE": "YOUR_ROLE"
      }
    }
  }
}

Cursor

Add to Cursor settings:

{
  "mcp.servers": {
    "snowflake": {
      "command": "node",
      "args": ["/path/to/mcp-server-snowflake/dist/index.js"],
      "env": {
        "SNOWFLAKE_ACCOUNT": "your-account",
        "SNOWFLAKE_USER": "your-user",
        "SNOWFLAKE_PASSWORD": "your-password"
      }
    }
  }
}

๐Ÿ“š Available Tools

The MCP server provides the following tools for interacting with Snowflake:

read_query

Execute SELECT queries on your Snowflake database.

// Example
{
  "query": "SELECT * FROM customers LIMIT 10"
}

list_databases

List all available databases in your Snowflake account.

list_schemas

List all schemas in a specific database.

// Example
{
  "database": "MY_DATABASE"  // Optional
}

list_tables

List all tables in a specific schema.

// Example
{
  "database": "MY_DATABASE",  // Optional
  "schema": "MY_SCHEMA"       // Optional
}

describe_table

Get detailed information about a table's structure.

// Example
{
  "table_name": "DATABASE.SCHEMA.TABLE"
}

๐Ÿ”’ Security

Environment Variables

The recommended approach for credentials:

export SNOWFLAKE_ACCOUNT="your-account"
export SNOWFLAKE_USER="your-user"
export SNOWFLAKE_PASSWORD="your-password"

Key-Pair Authentication (Production)

For production environments, we recommend using key-pair authentication:

  1. Generate a key pair

  2. Configure your Snowflake user with the public key

  3. Update the server configuration to use the private key

File Permissions

Secure your configuration files:

chmod 600 ~/.env
chmod 600 ~/Library/Application\ Support/Claude/claude_desktop_config.json

๐Ÿ“ฆ Building MCPB Packages

The MCPB (MCP Bundle) format allows for easy distribution and installation of MCP servers in Claude Desktop.

Building a Package

# Ensure the project is built
npm run build

# Create the MCPB package
./build-mcpb.sh

This will create a snowflake-mcp-v1.0.0.mcpb file containing:

  • Compiled server code

  • Manifest with configuration schema

  • Production dependencies

  • Installation metadata

Package Contents

The MCPB package includes:

  • manifest.json - Defines configuration parameters and server entry point

  • dist/ - Compiled TypeScript server code

  • node_modules/ - Production dependencies only

  • README.md - Package documentation

Manifest Configuration

The manifest.json file defines:

  • User configuration parameters (without default values for security)

  • Server entry point and environment variable mapping

  • Tool definitions for Snowflake operations

  • Package metadata (name, version, author, etc.)

๐Ÿงช Development

Setup Development Environment

# Install dependencies
npm install

# Run in development mode
npm run dev

# Run tests
npm test

# Lint code
npm run lint

# Type check
npm run type-check

Project Structure

mcp-server-snowflake/
โ”œโ”€โ”€ src/
โ”‚   โ””โ”€โ”€ index.ts          # Main server implementation
โ”œโ”€โ”€ dist/                 # Compiled JavaScript (generated)
โ”œโ”€โ”€ tests/               # Test files
โ”œโ”€โ”€ .env.example         # Environment variable template
โ”œโ”€โ”€ .github/
โ”‚   โ””โ”€โ”€ workflows/       # CI/CD workflows
โ”œโ”€โ”€ manifest.json        # MCPB package configuration
โ”œโ”€โ”€ build-mcpb.sh        # Script to build MCPB package
โ”œโ”€โ”€ package.json         # Node.js dependencies
โ”œโ”€โ”€ tsconfig.json        # TypeScript configuration
โ”œโ”€โ”€ LICENSE             # MIT License
โ”œโ”€โ”€ CONTRIBUTING.md     # Contribution guidelines
โ””โ”€โ”€ README.md          # This file

๐Ÿค Contributing

We welcome contributions! Please see our Contributing Guide for details.

How to Contribute

  1. Fork the 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

๐Ÿ“ License

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

๐Ÿ†˜ Support

If you encounter any issues or have questions:

  1. Check the Troubleshooting section below

  2. Search existing issues

  3. Create a new issue

๐Ÿ”ง Troubleshooting

Common Issues

"Missing required Snowflake configuration"

  • Ensure all required environment variables are set

  • Check for typos in variable names

  • Verify the .env file is in the correct location

Connection Failed

  • Verify your Snowflake account format: account.region.provider

  • Check network connectivity and firewall settings

  • Ensure your IP is whitelisted in Snowflake network policies

Permission Denied

  • Verify your Snowflake role has necessary permissions

  • Check warehouse access rights

  • Ensure database and schema permissions are granted

Debug Mode

Enable verbose logging:

export DEBUG=mcp:*
node dist/index.js

๐Ÿš€ Roadmap

  • Add support for write operations (INSERT, UPDATE, DELETE)

  • Implement connection pooling

  • Add support for Snowflake stored procedures

  • Create a web-based configuration UI

  • Add support for multiple Snowflake accounts

  • Implement query result caching

  • Add data visualization capabilities

๐Ÿ‘ฅ Authors

  • Patrick Freyer - Initial work

๐Ÿ™ Acknowledgments

  • Anthropic for the MCP protocol specification

  • Snowflake for their excellent Node.js SDK

  • The open-source community for continuous support and contributions

๐Ÿ“Š Stats

GitHub stars GitHub forks GitHub watchers


Made with โค๏ธ by Patrick Freyer

Available Tools

5 tools
describe_tableB

Get table schema information

ParametersJSON Schema
NameRequiredDescriptionDefault
table_nameYesThe table name (can include database.schema.table)

TDQS

B3.2/5.0
Behavior2/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

No annotations provided, and description is minimal. It does not disclose what schema information is returned (e.g., columns, types), whether it is a safe read operation, or any permission requirements.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness3/5

Is the description appropriately sized, front-loaded, and free of redundancy?

Extremely concise at one sentence, but may be too sparse. It conveys the basic action but lacks helpful details that would not be excessive.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness2/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

With no output schema, the description should clarify the return format. It does not mention what the schema information includes (e.g., columns, data types, constraints), leaving the agent guessing.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters3/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema coverage is 100% and the parameter description is clear. The tool description adds no extra meaning beyond what the schema already provides.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

Description clearly states 'Get table schema information', with a specific verb and resource. It distinguishes from siblings like list_tables (list names) and read_query (read data) by focusing on schema metadata.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines3/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

No explicit when-to-use or when-not-to-use guidance. Usage is somewhat implied by the name and purpose, but no alternatives or exclusions are mentioned.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

list_databasesA

List all available databases

ParametersJSON Schema
NameRequiredDescriptionDefault

No parameters

TDQS

A3.9/5.0
Behavior3/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

The description implies a read-only, non-destructive operation, which is appropriate. However, it lacks details about potential side effects, authentication requirements, or behavior when no databases exist. Since annotations are absent, more transparency would be beneficial.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is a single, concise sentence that conveys the entire purpose without any unnecessary words. It is well front-loaded and every word earns its place.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness5/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Given the tool's simplicity (no parameters, no output schema), the description fully captures its functionality. The sibling tools provide context for differentiation. No additional information is necessary.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters4/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

There are zero parameters, and schema coverage is 100%. The description adds no parameter information, which is acceptable because no parameters exist. Baseline is 4 per the scoring rules.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description succinctly states 'List all available databases', which is a specific verb and resource. It clearly distinguishes from sibling tools like list_tables or list_schemas by specifying the scope (all databases) and the action (list).

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines2/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

No guidance is provided on when to use this tool versus alternatives. There is no mention of prerequisites, such as being connected to a database system, or when to prefer list_schemas or list_tables instead.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

list_schemasB

List all schemas in a database

ParametersJSON Schema
NameRequiredDescriptionDefault
databaseNoThe database name (optional, uses current if not specified)

TDQS

B3.4/5.0
Behavior2/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

No annotations provided, so description carries full burden. It only states the operation without disclosing potential side effects, authorization needs, or performance implications. As a read-only listing, minimal transparency is acceptable but still lacking.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

Single sentence, front-loaded with action and resource, no wasted words. Perfectly concise.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness4/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

For a simple list tool with one optional parameter and no output schema, the description sufficiently conveys purpose. However, it could be slightly more informative about what schemas are or how they relate to siblings.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters3/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Input schema covers the only parameter 'database' with a description. The description adds no further meaning, so baseline score of 3 is appropriate.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

Description clearly states the action 'List' and resource 'schemas' with scope 'in a database'. It distinguishes from sibling tools like list_tables and list_databases by targeting schemas specifically.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines2/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

No guidance on when to use this tool versus alternatives like list_tables or list_databases. The description does not mention prerequisites, typical use cases, or exclusions.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

list_tablesB

List all tables in a schema

ParametersJSON Schema
NameRequiredDescriptionDefault
databaseNoThe database name (optional)
schemaNoThe schema name (optional)

TDQS

B3.2/5.0
Behavior2/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

With no annotations, the description carries the full burden but only states the basic action. It does not disclose authentication needs, behavior when parameters are omitted, or potential side effects.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is a single sentence that is front-loaded and contains no extraneous information. It is appropriately concise.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness2/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Given optional parameters and no output schema, the description lacks details on return format, behavior when parameters are omitted, and potential limitations. It is incomplete for effective use.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters3/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema coverage is 100%, so the schema already documents both parameters adequately. The description adds no extra meaning beyond the schema, meeting the baseline of 3.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description 'List all tables in a schema' uses a specific verb ('List') and resource ('tables'), clearly distinguishing the tool from siblings like describe_table, list_databases, and list_schemas.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines2/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

No guidance is provided on when to use this tool versus alternatives (e.g., when to use describe_table instead). The description lacks context on prerequisites or scenarios.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

read_queryB

Execute a SELECT query on Snowflake

ParametersJSON Schema
NameRequiredDescriptionDefault
queryYesThe SELECT query to execute

TDQS

B3.1/5.0
Behavior2/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

No annotations provided, so the description carries the burden. It only states the basic action, omitting details like read-only nature, potential for large results, permission requirements, or side effects.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is a single, direct sentence with no extraneous words, achieving perfect conciseness.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness3/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

For a simple tool with one parameter and no output schema, the description is minimally complete but lacks details on return format, read-only confirmation, or performance expectations.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters3/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema coverage is 100% with a parameter description. The tool description does not add meaning beyond what the schema already provides, so baseline 3 is appropriate.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose4/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description clearly states it executes a SELECT query on Snowflake, identifying the verb and resource. However, it does not explicitly indicate it is read-only or what it returns, which could be improved.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines2/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

No guidance on when to use this tool versus sibling tools like describe_table or list_tables. The purpose is implied but not differentiated.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Tool Schema Changelog

Recent tool additions, removals, and schema changes observed during successful MCP inspections. Dates show when Glama detected each change.

  1. 5 tool updatesv1.0.0
    • First observeddescribe_table
    • First observedlist_databases
    • First observedlist_schemas
    • First observedlist_tables
    • First observedread_query

TDQS

A3.7/5.0
Disambiguation5/5

Each tool has a clearly distinct purpose: browsing databases, schemas, tables, describing table schema, and executing SELECT queries. No overlap or ambiguity.

Naming Consistency5/5

All tool names follow a consistent verb_noun pattern in snake_case (e.g., list_databases, describe_table, read_query), making them predictable and easy for an agent to interpret.

Tool Count5/5

With 5 tools, the server is well-scoped for exploring a Snowflake database and executing queries. The count is neither too few nor excessive.

Completeness4/5

The tools cover the core workflow of discovering database objects and querying them. Missing operations like listing views or running DDL are minor gaps, but the set feels complete for typical read-only exploration.

Maintenance

ActivityInactive
ResponsivenessNo issues

Resources

Unclaimed servers have limited discoverability.

Looking for Admin?

If you are the server author, to access and configure the admin panel.

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
    A
    quality
    Not graded
    maintenance
    Enables AI assistants to securely connect to Snowflake data warehouses and execute SQL queries through natural language interactions. Supports multiple authentication methods and provides formatted query results with built-in security controls.
    1
    2
    -
  • A
    license
    Not graded
    quality
    D
    maintenance
    Enables AI assistants to perform comprehensive Snowflake database operations including DDL, DML, and warehouse management. It allows users to query data, manage database objects, and configure permissions using natural language commands.
    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
    679
    MIT

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/patrickfreyer/mcp-server-snowflake'

If you have feedback or need assistance with the MCP directory API, please join our Discord server