Skip to main content
Glama
azmym

postgres-mcp

by azmym

Server Configuration

Describes the environment variables required to run the server.

NameRequiredDescriptionDefault
POSTGRES_MCP_PSQLNoPath to the psql binary, used when psql is not on PATH or to skip the search.
POSTGRES_MCP_CONFIGNoOverride the location of the config file (default: ~/.config/postgres-mcp/config.toml).
POSTGRES_MCP_READ_ONLYNoSet to '1' to force every configured database read-only, regardless of the config file.0

Instructions

Guidance the server publishes about itself, which clients place ahead of the tool catalog so the model reads it before choosing anything.

This server publishes no instructions, or was last inspected before Glama recorded them.

Capabilities

Features and capabilities supported by this server

Protocol revision2025-11-25

CapabilityDetails
tools
{
  "listChanged": true
}
logging
{}
prompts
{
  "listChanged": false
}
resources
{
  "subscribe": false,
  "listChanged": false
}
extensions
{
  "io.modelcontextprotocol/ui": {}
}
experimental
{}

Tools

Functions exposed to the LLM to take actions

NameDescription
list_databasesA

List the configured PostgreSQL databases and their read-only status.

Returns each database's name, connection target and whether it accepts writes. Passwords are never included.

execute_sqlA

Run SQL against a configured database and return the rows as CSV.

database is a name from list_databases. Whether writes are permitted is fixed by configuration and cannot be changed per call: against a read-only database, only read queries run.

describe_schemaA

Describe a schema's tables, or one table's columns and indexes.

Without table, lists the schema's tables, views and column counts. With table, returns that table's columns, constraints and indexes. Always read-only, even against a writable database.

test_connectionA

Check psql and connectivity, for one database or all of them.

Reports the path to the psql binary, the server version, the connected user, and each database's configured read-only or read-write mode. Omit database to check every configured entry, which also validates the config file.

Prompts

Interactive templates invoked by user choice

NameDescription

No prompts

Resources

Contextual data attached and managed by the client

NameDescription

No resources

TDQS

A4.3/5.0

Scored across 4 tools

Disambiguation4/5

execute_sql and describe_schema are clearly distinct, and list_databases is primarily about enumerating configured databases. test_connection overlaps somewhat by reporting each database's read-only/write mode, but its focus on psql and connectivity makes the boundary clear enough.

Naming Consistency5/5

All tool names follow a consistent verb_noun snake_case pattern: list_databases, execute_sql, test_connection, describe_schema. There are no mixed conventions or vague verbs.

Tool Count5/5

Four tools is well-scoped for a focused Postgres server: enumeration, querying, introspection, and diagnostics. Each tool earns its place without redundancy.

Completeness4/5

Arbitrary SQL execution covers CRUD/write operations where permitted, while list_databases and describe_schema enable discovery and introspection. A minor gap is the lack of a direct list-schemas tool, but agents can work around it via information_schema queries.

Maintenance

ActivityMaintained
ResponsivenessNo issues