Labsco
MCP SERVER

AWS PostgreSQL MCP Server

by T1nker-1220

Read-only SQL against an AWS RDS PostgreSQL database, through a single query tool.

Relational SQL Databases
Summary
One tool, reads only, credentials outside the code.

A single query tool is a smaller surface than a schema-plus-query-plus-execute server, and for a production RDS instance that is the right trade — the model cannot write, and the schema is still discoverable through ordinary catalogue queries. Give it a database user with read grants on exactly the schemas you want visible; the server's read-only check is a floor, not your access policy.

What it is

A Node MCP server that opens a connection to a PostgreSQL database on AWS and exposes one tool for running read queries against it.

What you get
  • A `query` tool taking `sql` and returning the rows
  • Read-only enforcement: only SELECT, SHOW and similar statements are allowed
  • Credentials supplied through the client's env block rather than living in the code
  • Enough access to introspect the schema — querying information_schema tells the model what exists before it writes anything else
Requirements

`pnpm install` then `pnpm run build`. Configure `DB_HOST`, `DB_PORT`, `DB_NAME`, `DB_USER` and `DB_PASSWORD` in the client's env block, and point the command at the built build/index.js with an absolute path over stdio.