MCP server for PostgreSQL database operations
PostgreSQL MCP has basic tool definitions with descriptions and schemas, but significant gaps limit production readiness. All 7 tools have descriptions (10-100 chars, mostly adequate) and input schemas with type info. However, parameter descriptions are minimal or missing context about constraints, formats, and dependencies. No output schemas documented. Error handling returns raw exceptions rather than actionable recovery guidance. No tool annotations (readOnlyHint, destructiveHint) despite clear risk levels. Missing idempotency guidance for write operations. Parameter naming inconsistencies (e.g., 'condition' vs 'where_clause') and no enum constraints on SQL-like inputs invite hallucinated values.
Create a new table in the PostgreSQL database with specified columns.
Delete rows from a PostgreSQL table that match a condition.
Drop (delete) an existing table from the PostgreSQL database.
Execute a custom SQL query against the PostgreSQL database.
Insert a new row of data into a PostgreSQL table.
Query data from a PostgreSQL table with filtering, sorting, and limiting options.
Update existing rows in a PostgreSQL table that match a condition.
No output schemas documented. Tools return JSON strings but LLMs cannot infer field structure, types, or pagination. Downstream tool chaining requires guesswork.
Error responses return raw exception tracebacks (traceback.format_exc()) instead of actionable recovery guidance. LLMs cannot determine if errors are retryable, user-fixable, or fatal.
Destructive tools (drop_table, delete_data) lack confirmation/dry-run support. No tool annotations (destructiveHint) to warn agents. Agents can irreversibly delete data without safeguards.
Inferred effective spec: <=2025-11-25.
| Scored | Grade | Overall | Spec posture | Rubric |
|---|---|---|---|---|
| 2026-09-23 | D | 53 | <=2025-11-25 | v2 |
Parameter descriptions lack constraint details. 'condition' param in update_data/delete_data has no format guidance (e.g., 'WHERE clause syntax: id = %s'). 'columns' in create_table lacks structure example. LLMs guess at valid formats.
No tool annotations (readOnlyHint, destructiveHint, idempotentHint). Agents cannot distinguish safe reads from destructive writes without parsing descriptions. Risk of accidental data loss.