Postgres gateway for AI agents: blocks destructive SQL, holds risky writes, undoes applied ones.
MCPpedia last refreshed this data
io.github.ege-usta/lomberk is an MCP server that postgres gateway for AI agents: blocks destructive SQL, holds risky writes, undoes applied ones. Its tool list has not been published yet over stdio and http, requires no API key, and scores 87/100 on MCPpedia's security, maintenance and efficiency rubric.
Config is the same across clients - only the file and path differ.
{
"mcpServers": {
"io-github-ege-usta-lomberk": {
"args": [
"lomberk"
],
"command": "uvx"
}
}
}Are you the author?
Add this badge to your README to show your security score and help users find safe servers.
Every agent write, reversible. Lomberk is an MCP gateway for PostgreSQL. AI agents send SQL through it instead of holding database credentials. It blocks destructive commands, holds large or sensitive writes for a human, records every changed row, and can undo any applied write, including foreign-key cascades.
This server supports HTTP transport. Be the first to test it - help the community know if it works.
Five weighted categories - click any category to see the underlying evidence.
No known CVEs.
Checked lomberk against OSV.dev.
Click any tool to inspect its schema.
Be the first to review
Have you used this server?
Share your experience - it helps other developers decide.
Sign in to write a review.
Others in data / ai-ml
Token-efficient database MCP server for PostgreSQL, MySQL, MariaDB, SQL Server, Oracle, SQLite
Manage Supabase projects — databases, auth, storage, and edge functions
Codebase knowledge graph for AI agents — 162 languages, sub-ms queries, 99% fewer tokens.
An open-source AI agent that brings the power of Gemini directly into your terminal.
MCP Security Weekly
Get CVE alerts and security updates for io.github.ege-usta/lomberk and similar servers.
Start a conversation
Ask a question, share a tip, or report an issue.
Sign in to join the discussion.
Every agent write, reversible. Lomberk is an MCP gateway for PostgreSQL. AI agents send SQL through it instead of holding database credentials. It blocks destructive commands, holds large or sensitive writes for a human, records every changed row, and can undo any applied write, including foreign-key cascades.
Just want a seatbelt for Claude Code? Lomberk Seatbelt is a free plugin that makes your agent ask before DROP, TRUNCATE, DELETE without WHERE, prisma migrate reset, dropdb and friends. Install it in two commands.
You need uv and the owner's connection string of a PostgreSQL 14+ database (a role that can create roles: postgres on Supabase, Neon and RDS).
uvx lomberk setup # asks for the owner connection string; what you type stays out of your shell history
In a script, set LOMBERK_INSTALL_DSN instead and add --yes.
Setup creates two least-privilege roles with generated passwords, installs Lomberk, lists your tables and makes the ones you pick undoable, then writes lomberk.yaml and a private .env (mode 600) and runs lomberk doctor on them. It never changes a role or file that already exists. The owner connection string is used once and never saved. At the end it prints the line for your MCP client, for example:
claude mcp add lomberk -e LOMBERK_CONFIG=/path/to/lomberk.yaml -- uvx lomberk serve
Cursor, Claude Desktop, VS Code and Codex get their config snippet too. Then ask your agent to change something:
lomberk log # what your agents changed, newest first
lomberk undo cp_… # put it back, cascades included
lomberk approve cp_… # let a held write run (or: lomberk reject cp_…)
lomberk doctor # check the setup any time
Supabase, Neon, RDS, Railway: docs/hosted-postgres.md. On Supabase, use the session pooler connection string (IPv4); setup derives the lomberk_agent.<project-ref> login names from it.
| Tool | |
|---|---|
execute_sql | One statement through the hard gate, the policy and capture. Replies with a checkpoint (cp_…), APPROVAL REQUIRED, or why it was denied |
describe_tables | The tables it can use, their columns (secret ones hidden) and which writes wait for a human |
wait_for_approval | Waits for a person to approve or reject a held write, reporting progress, then says whether it ran |
checkpoint_status | What happened to one of its writes: waiting, applied, rejected or undone |
list_my_changes | Its own recent writes with their tokens, so it can tell you what to undo |
The agent can't approve or undo anything. That takes the admin key, the CLI or (Pro) Slack, SSO or the panel.
In April 2026 an autonomous coding agent deleted a production database in 9 seconds (through an over-privileged infrastructure token). Lomberk closes the other door: an agent's own database access. Here is what a rogue agent can and can't do when its SQL goes through Lomberk.

git clone https://github.com/e
... [View full README on GitHub](https://github.com/ege-usta/lomberk#readme)