database_dump
Create a .sql dump of a MySQL database on the FastPanel host via SSH, returning the file path and byte size.
Instructions
Dump a database to a .sql file ON the FastPanel host via SSH (mysqldump). Writes a file you can then download (scp/sftp); returns the path and byte size. The file can only be written inside the staging dir (default /root/fastpanel-mcp-dumps, override with FASTPANEL_DUMP_DIR) — arbitrary output paths are rejected. Targets the host's LOCAL MySQL via root socket auth; remote servers and non-MySQL engines are rejected. WRITE (it creates a root-owned file) — set dry_run:true to preview, confirm:true to execute. Requires SSH configured (FASTPANEL_SSH_HOST).
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": {
"database_id": "<database_id>"
},
"name": "database_dump"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| confirm | No | ||
| dry_run | No | ||
| database_id | Yes | Database id from databases_list | |
| output_path | No | Absolute .sql path INSIDE the staging dir. Default: <staging>/<name>-<timestamp>.sql |