Skip to main content
Glama
pg-readonly-mcp

pg-readonly-mcp

by landaida

list_tables

List readable PostgreSQL tables as schema.table with row-count estimates and comments, so you can identify available data before writing SELECT-only queries.

Instructions

List the tables this server may read (schema.table), with a row-count estimate and comment.

Tool call template

This tool declares no required parameters. Add optional parameters from the input schema as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {},
    "name": "list_tables"
  }
}

Input Schema

NameRequiredDescriptionDefault

No arguments

Output Schema

NameRequiredDescriptionDefault

No arguments

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

A4.1/5.0
Behavior5/5

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

With no annotations supplied, the description carries the burden and does so: it discloses that results are limited to tables the server is permitted to read, and that entries carry a row-count estimate (implying approximate, not exact, counts) and a comment. That is real behavioral context an agent could not get from the empty schema.

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?

A single sentence with the output shape front-loaded after the verb; every clause ('may read', 'schema.table', 'row-count estimate', 'comment') adds information. Nothing is redundant.

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 parameterless read tool with an output schema present, the description covers scope, entry format, and result fields, which is sufficient. Minor gaps remain around pagination or size limits for servers with many tables, but nothing blocks correct invocation.

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?

The tool takes zero parameters, so there is nothing for the description to disambiguate; baseline 4 applies. The description does not introduce any phantom parameter concepts, keeping the contract clean.

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?

Names a specific verb (List) and resource (tables), and adds scope ('this server may read') plus the shape of each entry ('schema.table') and the extra fields returned (row-count estimate and comment). It is clearly distinct from describe_table and query by implication, though it never explicitly contrasts with them.

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?

Usage is only implied: an agent can infer this is the discovery step before describe_table or query, but the description never states when to prefer it over those siblings or any preconditions (e.g., connection/auth state). No exclusions or alternatives are named.

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