Skip to main content
Glama
database-mcp

database-mcp

get_schema

Retrieve a compact overview of all tables, columns, and foreign-key relationships in an entire database in one call to support Text-to-SQL querying.

Instructions

Get a compact overview of an entire database in one call: all tables, their columns, and foreign-key relationships. PREFER THIS as your first call after picking a connection — it is cached and token-efficient. Only use describe_table to zoom into one table when this overview is too large.

Tool call template

Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "connection": "<connection>"
    },
    "name": "get_schema"
  }
}

Input Schema

NameRequiredDescriptionDefault
connectionYesNamed connection from list_connections (preferred) or a raw connection string.

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.5

TDQS

A4.5/5.0
Behavior4/5

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

No annotations are supplied, so the description carries the full disclosure burden, and it does substantial work: it reveals the tool is cached and token-efficient, what the response contains, and what to do when the response is too large. It does not state read-only/permission expectations or error behavior, which is a modest gap for a tool with zero annotation coverage.

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?

Two sentences, both front-loaded with the most decision-relevant information (what it returns, then why to prefer it, then the escape hatch). There is no redundant or filler wording.

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?

For a one-parameter read tool with no output schema, the description compensates by naming the return contents (tables, columns, foreign-key relationships) and by characterizing result size and the fallback path. Nothing an agent needs in order to call it correctly appears to be missing.

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 description coverage is 100% for the single connection parameter, so the schema already documents that it accepts a named connection or raw string. The description only implies the parameter via "after picking a connection" and adds no format or fallback detail beyond the schema, making the baseline 3 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?

States a specific verb and resource ("Get a compact overview of an entire database") and enumerates the scope precisely: all tables, their columns, and foreign-key relationships. It also explicitly contrasts itself with describe_table, so an agent can distinguish the two without opening either schema.

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

Usage Guidelines5/5

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

Gives explicit when-to-use guidance ("PREFER THIS as your first call after picking a connection") and a concrete when-not condition with the named alternative ("Only use describe_table ... when this overview is too large"). The selection logic between the two tools is fully specified.

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