Skip to main content
Glama
eric-patton

postgres-schema-mcp

by eric-patton

List tables

list_tables
Read-onlyIdempotent

Identify the largest tables and views in a schema with estimated row counts and disk size, revealing expensive targets before querying.

Instructions

List the tables and views in one schema, largest first, with an estimated row count and total on-disk size. Use this to find out what is expensive before you query it. Row counts are planner estimates, not exact counts.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
schemaYesSchema name, for example "public".

Schema Changelog

Changes observed during successful MCP inspections. Dates show when Glama detected each change.

  1. First observedv0.1.1

TDQS

A4.3/5.0
Behavior4/5

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

Annotations already declare read-only/idempotent/non-destructive behavior, so the description adds beyond them by disclosing that row counts are planner estimates rather than exact numbers and that views are included. This is useful non-obvious behavioral context.

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 compact sentences: the first states the core behavior and output, the second adds a use case and a critical caveat. No filler or redundant restating of the tool name.

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 listing tool with no output schema, the description conveys what is returned (tables and views, estimated row counts, on-disk size), the ordering, and the estimation caveat. Nothing essential is missing for correct invocation.

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?

The input schema already fully describes the single 'schema' parameter with an example, and schema description coverage is 100%. The description adds no parameter-level detail beyond confirming the scope is one schema, so the baseline 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?

The description uses a specific verb ('List') with a concrete resource ('tables and views in one schema') and adds distinctive return details (ordering by size, estimated row count, on-disk size). This clearly separates it from siblings like list_schemas and describe_table.

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?

It gives an explicit use case: 'Use this to find out what is expensive before you query it.' It does not explicitly state when not to use it or name alternatives, but the intended context is clear enough for an agent to select this tool.

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

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/eric-patton/postgres-schema-mcp'

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