Skip to main content
Glama
urjeetpatel

db-tools-mcp

by urjeetpatel

add_database

Configure a new database source in the configuration file, including optional connection testing. Supports SQL Server and Snowflake via linked server.

Instructions

Add a new database source to config.yaml and optionally test the connection.

db_type='sqlserver': url (required) -- SQLAlchemy connection URL, e.g.: "mssql+pyodbc:///?odbc_connect=DRIVER=ODBC Driver 17 for SQL Server; Server=myserver;Database=MyDB;Trusted_Connection=Yes;"

db_type='snowflake' (via SQL Server linked server + OPENQUERY): sqlserver_url (required) -- SQLAlchemy URL for the gateway SQL Server linked_server (required) -- Linked server name (e.g. "SNOWFLAKE") snowflake_database (required) -- Snowflake database (e.g. "MY_DB")

Common: include_schemas -- ["*"] for all (default), or explicit list exclude_schemas -- defaults to system schemas for the db_type test_connection -- set False to skip the live connection test

After adding, call refresh_metadata(source='') to populate the cache.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
urlNo
nameYes
db_typeYes
linked_serverNo
sqlserver_urlNo
exclude_schemasNo
include_schemasNo
test_connectionNo
snowflake_databaseNo

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault

No arguments

Behavior4/5

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

With no annotations provided, the description carries the burden of disclosing behavior. It explains optional parameters (test_connection), default values (include_schemas defaults to ['*']), and post-usage requirements. It also details two distinct db_type behaviors. It does not mention error handling or side effects, but overall is informative.

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

Conciseness4/5

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

The description is well-organized with sections for each db_type and common parameters. It includes examples but remains focused. Slightly verbose due to examples, but structure aids readability.

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?

Given 9 parameters, 0% schema coverage, no annotations, and existence of an output schema, the description covers the key aspects: parameter usage, conditional behavior, and post-usage steps. It omits output details but the output schema exists. Adequate for the tool's complexity.

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?

Schema description coverage is 0%, so the description must compensate. It provides detailed explanations for url, sqlserver_url, linked_server, snowflake_database, include_schemas, exclude_schemas, and test_connection with examples. It does not explain 'name' or 'db_type' in depth, but these are self-explanatory.

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 clearly states 'Add a new database source to config.yaml and optionally test the connection,' specifying the action and resource. It also distinguishes this tool from siblings like list_sources or refresh_metadata.

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

Usage Guidelines4/5

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

The description explains when to use the tool (adding a database source) and provides context for different db_types (sqlserver, snowflake). It explicitly recommends calling refresh_metadata afterwards. However, it does not explicitly state when NOT to use or compare to alternatives.

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

Install Server

Other Tools

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/urjeetpatel/db-tools-mcp'

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