Skip to main content
Glama
Rabin0404

pg-mcp-bridge

by Rabin0404

query

Execute a single SQL statement, with allowed operations determined by the server's access mode (readonly, readwrite, or full).

Instructions

Run a single SQL statement. Allowed statements depend on server access_mode: readonly (SELECT/EXPLAIN/SHOW), readwrite (+ INSERT/UPDATE/DELETE), full (+ CREATE/ALTER/DROP and other DDL). Use ping to see the current access_mode. Only one statement per call.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
sqlYesSQL statement (permissions enforced by server access_mode)
Behavior4/5

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

In the absence of annotations, the description reveals behavioral traits such as varying permissions by access_mode and the single-statement constraint. It implicitly warns about potential destructive actions by mentioning DDL/DML permissions, though it could detail error 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?

The description is concise and well-structured: three sentences that front-load the primary action, then detail constraints. No extraneous information.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness3/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

While the description covers the main functionality and constraints, it lacks details on the return format or error handling, which are not covered by an output schema. For a SQL query tool, knowing the result type would improve completeness.

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?

With 100% schema coverage, the description adds meaning by categorizing SQL types by access_mode and linking to ping. It goes beyond the schema's 'permissions enforced' note to provide concrete examples of allowed statements.

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 clearly states the tool runs a single SQL statement, which is specific to the query action. It distinguishes from siblings like list_schemas and list_tables by focusing on executing arbitrary SQL rather than metadata listing.

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 explains that allowed statements depend on server access_mode and suggests using ping to check the current mode. It also explicitly limits to one statement per call. While not covering all alternatives, it provides clear usage context.

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

Install Server

Other Tools

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/Rabin0404/pg-mcp-server'

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