Skip to main content
Glama
mcp-readonly-db

mcp-readonly-db

Describe a table

describe_table
Read-onlyIdempotent

Inspect a table's columns, types, nullability, primary/foreign keys, and row count to understand its schema and relationships before querying.

Instructions

Show a table's columns (name, type, nullability, primary key), foreign keys and row count.

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": {
      "table": "<table>"
    },
    "name": "describe_table"
  }
}

Input Schema

NameRequiredDescriptionDefault
tableYesExact table or view name, as returned by list_tables

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv1.0.0

TDQS

B3.2/5.0
Behavior3/5

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

Annotations already declare readOnlyHint=true, idempotentHint=true, destructiveHint=false, and openWorldHint=false, so the safety profile is fully covered. The description adds genuine value by disclosing the payload contents, including row count. It does not note whether the row count is exact or an estimate, or what happens for an unknown table name, which are the remaining behavioral gaps.

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?

One tightly written sentence with no filler, front-loaded with the primary output (columns) before secondary details. The parenthetical enumeration is efficient rather than padded. Nothing needs to be cut.

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 one-parameter, read-only, closed-world tool with a fully documented parameter, the description covers what an agent needs: what it returns and how to identify the target. With no output schema present, the enumerated return fields do the necessary work. Minor gaps remain around error handling for missing tables and row-count precision.

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%, and the single parameter is documented as an exact table or view name as returned by list_tables. The description adds no extra meaning about case sensitivity, qualification (schema prefix), or view handling beyond what the schema states, so the baseline 3 applies.

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 pairs a specific verb ("Show") with a specific resource (a table's structure) and enumerates exactly what is returned: columns with name/type/nullability/primary key, foreign keys, and row count. An agent can distinguish this from list_tables, sample_rows, or run_query. It stops short of explicitly naming a sibling it is not, which keeps it from a 5.

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?

There is no explicit when-to-use or when-not-to-use guidance in the description. The only workflow hint comes indirectly from the schema ("as returned by list_tables"), implying this is a discovery step before querying, but the description itself never says to call this to learn a schema or to prefer it over run_query for introspection.

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

Deploy Server

Other Tools