Skip to main content
Glama
postgres-mcp-server

postgres-mcp-server

list_tables

Read-only

Discover database schemas and their tables and columns without writing SQL, optionally filtering by schema. Use it to inspect PostgreSQL structure before querying or building migrations.

Instructions

Discover schemas and their tables/columns without writing a query (FR-002)

Input Schema

NameRequiredDescriptionDefault
schemaNoOptional schema name to filter tables (defaults to all non-system schemas)

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.4

TDQS

A3.5/5.0
Behavior3/5

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

readOnlyHint=true already tells the agent this is a safe read, so the bar is lower; the description adds that no query needs to be composed, which is useful framing. It says nothing about result size, pagination, or how system schemas are treated (that detail lives only in the schema), so additional behavioral disclosure is thin.

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 front-loaded sentence with the key constraint ('without writing a query') placed early and no redundant restatement of the name. The trailing requirement tag '(FR-002)' is traceability noise for an agent and is the only inefficiency.

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 zero-required-parameter, single-optional-parameter list tool with a readOnly annotation and full schema coverage, the description covers the essential purpose. The main remaining gap is the shape of the returned hierarchy (schemas -> tables -> columns), which must be inferred from the prose.

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's default behavior ('defaults to all non-system schemas') is fully documented in the schema itself. The description adds no further meaning about the schema filter, so the baseline of 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?

States a specific verb ('discover') and resource ('schemas and their tables/columns'), which clearly signals a metadata-listing tool distinct from run_query. It does not, however, distinguish itself from close siblings like list_databases or describe_table, so an agent must infer the boundary.

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?

'Without writing a query' implies the usage context versus run_query, giving an implicit alternative. There is no explicit guidance on when to pick this over describe_table (single-table detail) or list_databases (top-level enumeration), and no stated preconditions such as required role/permissions that siblings like set_role suggest matter here.

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