Skip to main content
Glama
KannaKim

PostgreSQL MCP Server

by KannaKim

PostgreSQL MCP 서버

PostgreSQL을 위한 범용 모델 컨텍스트 프로토콜(MCP) 서버로, AI 에이전트가 PostgreSQL 데이터베이스를 안전하게 검사하고 쿼리할 수 있게 합니다.

기능

  • list_tables: public 스키마의 모든 테이블을 나열합니다.

  • get_schema: 특정 테이블의 스키마(열, 유형, null 허용 여부)를 가져옵니다.

  • run_query: 읽기 전용 SQL 쿼리(SELECT/WITH만 허용)를 실행하며, 대규모 응답을 방지하기 위해 최대 100행으로 제한합니다.

Related MCP server: PostgreSQL MCP Server

사전 요구 사항

  • Python 3.13+

  • uv

  • PostgreSQL 데이터베이스

설치

저장소를 복제한 경우 uvx 또는 uv run을 사용하여 직접 실행할 수 있습니다.

사용법

이 서버는 DATABASE_URL 환경 변수가 설정되어 있어야 합니다.

연결 문자열 예시: postgres://user:password@localhost:5432/mydatabase

직접 실행

DATABASE_URL="postgresql://postgres:poggerpogger@localhost:5432/boxboxWeb" uv run main.py

Claude Desktop / MCP 클라이언트와 함께 사용

MCP 클라이언트 구성(예: Claude Desktop의 claude_desktop_config.json)에 다음을 추가하세요:

{
  "mcpServers": {
    "postgres": {
      "command": "uv",
      "args": [
        "run",
        "/path/to/2025postgresqlmcp/main.py"
      ],
      "env": {
        "DATABASE_URL": "postgres://user:password@localhost:5432/mydatabase"
      }
    }
  }
}
F
license - not found
A
quality
D
maintenance

Maintenance

Maintainers
Response time
Release cycle
Releases (12mo)
Commit activity

Resources

Unclaimed servers have limited discoverability.

Looking for Admin?

If you are the server author, to access and configure the admin panel.

Related MCP Servers

  • A
    license
    Not graded
    quality
    D
    maintenance
    Provides read-only access to PostgreSQL databases, enabling LLMs to inspect database schemas and execute read-only SQL queries.
    66,136
    MIT
  • A
    license
    Not graded
    quality
    D
    maintenance
    Enables AI assistants to safely interact with PostgreSQL databases through read-only operations, providing schema discovery, table inspection, and query execution capabilities with structured context awareness.
    MIT
  • F
    license
    Not graded
    quality
    D
    maintenance
    Enables AI assistants to safely interact with PostgreSQL databases, perform queries, inspect schemas, and analyze query performance.
    2

View all related MCP servers

Related MCP Connectors

  • Query PostgreSQL databases in plain English — LLM-generated, safety-validated SQL.

  • Explore, query, and inspect SQLite databases with ease. List tables, preview results, and view det…

  • Comprehensive PostgreSQL documentation and best practices, including ecosystem tools

View all MCP Connectors

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/KannaKim/PostgresqlMCPServer'

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