sql-check
SQL guard: single statement, read-only, table allowlist — Checks one SQL string (up to 20000 characters; PostgreSQL, MySQL, SQLite or generic) before an agent executes it: exactly one statement, read-only (SELECT/VALUES/SHOW/EXPLAIN without side effects), and every table it reads or writes on a caller allowlist. Tokenizer-level: comments, string literals, quoted identifiers and dollar quoting cannot hide a second statement; reports statement kind, refere
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"sql": "<sql>"
},
"name": "sql-check"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| sql | Yes | ||
| dialect | No | Lexical rules; default ansi. | |
| readOnly | No | Default true: anything but a plain read fails. | |
| transpileTo | No | Always answered unsupported. | |
| allowedTables | No | Allowed tables, lower-cased match: 'users', 'public.users' or 'public.*'. Unqualified and qualified names are different entries. |