pgbrake

v0.3.0
io.github.lexang/pgbrake Checked 7 hours ago Published 25 days ago

Postgres brake for AI agents: risky SQL waits for approval, UPDATE/DELETE get one-command undo.

These tools were reported by the server itself during our smoke test (tools/list), not copied from the README.

query

Run a read-only SQL query (SELECT/EXPLAIN). Writes are rejected here.

ParameterTypeDescription
sql *string

execute

Run SQL that may modify data. Returns rows, a change id for undo, or an approval id when a human must approve first.

ParameterTypeDescription
sql *string
approval_id

undo

Reverse a change made through pgbrake, by change id.

ParameterTypeDescription
change_id *string
forceboolean

list_changes

List recent changes that can be undone.

ParameterTypeDescription
limitinteger

approval_status

Check whether an approval id has been approved by a human yet.

ParameterTypeDescription
approval_id *string