PostgreSQL MCP Server
Ermöglicht über das Model Context Protocol schreibgeschützten Zugriff auf PostgreSQL-Datenbanken. KI-Agenten können Schemas prüfen, SELECT-Abfragen ausführen und Tabellenstrukturen erkunden. Verwendet schreibgeschützte Transaktionsisolierung, um versehentliche Änderungen zu verhindern. Der Server gehörte zu den Referenzservern und ist inzwischen archiviert unter servers-archived verfügbar.
Diese Beschreibung wurde automatisch übersetzt und noch nicht redaktionell geprüft.
Verbinden
Fügen Sie diese Konfiguration hinzu zu .claude/mcp.json
{
"mcpServers": {
"postgres": {
"command": "npx",
"args": [
"-y",
"@modelcontextprotocol/server-postgres",
"postgresql://localhost/mydb"
],
"env": {
"POSTGRES_CONNECTION_STRING": "<YOUR_POSTGRES_CONNECTION_STRING>"
}
}
}
}Werkzeuge (3)
query
Execute a read-only SQL query against the connected PostgreSQL database and return results.
{
"type": "object",
"required": [
"sql"
],
"properties": {
"sql": {
"type": "string",
"description": "SQL query to execute (SELECT statements only)"
}
}
}list_tables
List all tables in the connected PostgreSQL database with their schemas.
{
"type": "object",
"properties": {
"schema": {
"type": "string",
"description": "Schema name to filter tables (defaults to public)"
}
}
}describe_table
Get the column definitions, types, and constraints for a specific table.
{
"type": "object",
"required": [
"table_name"
],
"properties": {
"schema": {
"type": "string",
"description": "Schema name (defaults to public)"
},
"table_name": {
"type": "string",
"description": "Name of the table to describe"
}
}
}Ressourcen (1)
postgres://{host}/{database}/schemaAccess to the database schema information including tables, columns, and relationships.
Prompts
Dieser Server stellt keine Prompts bereit.
Serverinformationen
- Lizenz
- MIT
- Version
- 0.6.2
- Sterne
- 265
- Zuletzt aktualisiert
- 27. Januar 2026