Run SQL that changes the database
execute_sqlPHP + MySQL plans: runs one SQL statement that can change the site's database (CREATE/ALTER/DROP TABLE, INSERT, UPDATE, DELETE, …). Changes are permanent: confirm destructive changes (DROP, DELETE, TRUNCATE, large UPDATEs) with the user first. Use ? placeholders with params for values. One statement per call; 30-second limit.
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": {
"site": "<site>",
"query": "<query>"
},
"name": "execute_sql"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| site | Yes | The website's domain, as shown by list_sites (e.g. "example.com" or "name.hostingfor.ai"). | |
| query | Yes | One SQL statement. | |
| params | No | Values for ? placeholders, in order. |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| note | No | ||
| rows | No | One object per row, keyed by column name. | |
| columns | No | ||
| warnings | No | ||
| insert_id | No | ||
| more_rows | No | ||
| row_count | No | ||
| duration_ms | Yes | ||
| affected_rows | No |