PostgreSQL with GitHub OAuth
by coleam00 · Databases · mcp-server, database
Provides secure PostgreSQL database access with GitHub OAuth authentication, enabling read-only operations for all authenticated users while restricting write operations to allowlisted GitHub usernames through role-based access control.
This MCP server provides AI assistants with secure database access through GitHub OAuth authentication and PostgreSQL integration, built by Cole Medin using Cloudflare Workers with Durable Objects for stateful session management. The implementation features role-based access control where all authenticated GitHub users can perform read-only database operations like table listing and SELECT queries, while write operations (INSERT, UPDATE, DELETE) are restricted to specific GitHub usernames defined in an allowlist. Built with TypeScript using the workers-mcp framework, Hono for HTTP handling, and the postgres library for database connectivity, it includes SQL injection protection, query validation, connection pooling optimized for Cloudflare Workers' constraints, and optional Sentry integration for error monitoring and performance tracking. The server supports both simple math operations for testing and full PostgreSQL database management, making it valuable for teams building AI-powered database applications that need secure, authenticated access to production databases with granular permission controls based on GitHub identity.
Source: https://github.com/coleam00/remote-mcp-server-with-auth
Install
git clone https://github.com/coleam00/remote-mcp-server-with-authTags: mcp-server, database
⭐ 290 GitHub stars · Source: pulsemcp
About Databases MCP servers and Claude skills
Databases MCP servers extend what AI agents can do inside Claude Code, Cursor, Copilot, Codex, and Windsurf. The Skiln directory indexes 16,000+ such integrations across 22 categories.
PostgreSQL with GitHub OAuth is one of hundreds of Databases entries indexed on Skiln. Browse the full Databases category or the complete directory of Claude skills, MCP servers, agents, commands, and hooks.
Related Databases MCPs and skills
- Snowflake by snowflake-labs
Bridges AI applications with Snowflake's data platform for database interaction
- Apache Doris by apache
Enables direct SQL query execution and metadata retrieval from Apache Doris databases without switching contexts.
- SQL Server Performance Monitor by erikdarlingdata
SQL Server performance monitoring with DuckDB storage and natural language queries for CPU, wait stats, blocking, query performance, memory, and I/O.
- MySQL Database Manager by wenb1n-dev
Provides direct access to MySQL databases with advanced features like multiple SQL execution, table metadata querying, execution plan analysis, and Chinese field to pinyin conversion through a configurable Python-based server.
- Microsoft SQL Server (MSSQL) by richardhan
Securely integrates with Microsoft SQL Server databases for data analysis, reporting, and management.
- ExecuteAutomation Database Server by executeautomation
Enables direct interaction with SQLite and SQL Server databases through a modular adapter architecture for data analysis, database management, and business intelligence workflows without exposing raw credentials.
- Security Detections by mhaggis
Aggregates security detection rules from Sigma, Splunk ESCU, Elastic, and KQL into a unified searchable SQLite database with MITRE ATT&CK mappings and CVE tracking for security analysts and threat hunters.
- DB Connector (MySQL/PostgreSQL) by freepeak
Enables direct interaction with MySQL and PostgreSQL databases through a Go-based connectivity layer that supports both local stdio and production SSE transport modes for querying, analyzing, and manipulating structured data.
Frequently asked questions
How do I install PostgreSQL with GitHub OAuth?
Add the install command above to your Claude Code, Cursor, or Windsurf MCP configuration. Most servers register via npx, a local command, or a Docker image. Refer to the source repository for environment variables and credential requirements.
Which clients support PostgreSQL with GitHub OAuth?
Any MCP-compatible client works: Claude Desktop, Claude Code CLI, Cursor, Windsurf, Zed, and VS Code with the official MCP extension. OpenAI Codex and GitHub Copilot increasingly support MCP via adapter bridges.
Is PostgreSQL with GitHub OAuth free?
The server itself is typically open source. Any upstream service (API keys, paid tiers, hosted infrastructure) may have its own pricing. Check the source repository for details.