# pg_mcp_qauth

> pg_mcp_qauth — martystev-pg-mcp-qauth. Use this tool when you need to authenticate and authorize PostgreSQL database access using OAuth 2.1 and JWT tokens from Keycloak or Authentik, with features like role-based access control and SQL query auditing. It solves problems related to secure database access and row-level security isolation for Claude Code and VS Code users. The tool takes JWT tokens as input and outputs authorized database access with audited SQL queries.

Canonical page: https://skillsregistry.net/skills/martystev-pg-mcp-qauth  
JSON: https://api.skillsregistry.net/v1/skills/martystev-pg-mcp-qauth

## Description

Postgres MCP server with OAuth 2.1 authentication, Keycloak/Authentik JWT verification, AST SQL guardrails, and role/RLS data isolation for Claude Code & Cursor.

## Trust

- **Trust score (0–1):** 0.74
- **Verification tier:** verified
- **Last scanned:** 2026-09-28

## Facts

- **Version:** 1.0.0
- **Skill type:** atomic
- **Execution layer:** container
- **Runtime environment:** vm
- **License:** MIT
- **Updated:** 2026-09-28

## Source

- **Source listing:** [GitHub](https://github.com/MartyStev/pg_mcp_qauth)

## Use it

Resolve this record through the SkillsRegistry MCP server (no auth, read-only):

```
claude mcp add --transport http --scope user skillsregistry https://api.skillsregistry.net/mcp
```

```json
{
  "jsonrpc": "2.0",
  "id": 1,
  "method": "tools/call",
  "params": {
    "name": "get_skill",
    "arguments": {
      "slug": "martystev-pg-mcp-qauth"
    }
  }
}
```

REST: `GET https://api.skillsregistry.net/v1/skills/martystev-pg-mcp-qauth` · pull for local use: `GET https://api.skillsregistry.net/v1/skills/martystev-pg-mcp-qauth/pull`

---
SkillsRegistry indexes agent skills from public registries and GitHub. Skills we have analysed are scanned with Circle-IR and scored on six dimensions; each listing states its scan coverage. More: https://skillsregistry.net/llms.txt
