Skip to main content
Glama

Server information

pg_server_info
Read-onlyIdempotent

Inspect a PostgreSQL server's version, uptime, role, privileges, database size, settings, extensions, and supported features to guide safe, version-aware tool use on unfamiliar instances.

Instructions

Show PostgreSQL version, uptime, current role and privileges, database size, key settings, installed extensions and which optional features this server supports.

Use it first on an unfamiliar server: tools adapt to the version (9.6 to 19) and to the extensions reported here.

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": "pg_server_info"
  }
}

Input Schema

NameRequiredDescriptionDefault
connectionNo

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

A4.1/5.0
Behavior4/5

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

Annotations already declare readOnlyHint, idempotentHint and openWorldHint=false, so safety is covered. The description adds non-obvious cross-tool behavior: other tools adapt to version (9.6–19) and to extensions reported here, which tells the agent this call changes downstream tool behavior.

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 short paragraphs, front-loaded with what is returned and followed by the sequencing advice. Every clause carries information; there is no restatement of the title or annotations.

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?

With no output schema, the description compensates by listing exactly what the call reports, and it explains the tool's role as a prerequisite for version/extension-adaptive siblings. The only real hole is the undocumented connection parameter for a read-only introspection tool with no annotations gaps elsewhere.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters2/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema coverage is 0% for the single 'connection' parameter, and the description never explains it — no format, no default-server behavior, no guidance on when to pass a target. Since sibling tools likely share this parameter, the gap is partly conventional, but the description does nothing to compensate for the zero coverage.

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?

Names a specific verb+resource ('Show PostgreSQL version, uptime, current role and privileges, database size, key settings, installed extensions') and enumerates the exact payload, which distinguishes it from siblings like pg_health_check or pg_activity that read overlapping server state.

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?

Explicitly states when to use it: 'Use it first on an unfamiliar server,' which gives an agent a concrete ordering rule. It does not name an exclusion or a specific alternative, so it stops short of the top score.

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