Write site files
write_site_filesWrites (creates or replaces) up to 25 web files in a customer's SHARED hosting site's web root and publishes them immediately — this is how an assistant puts an edit on the live site. Full file contents only (no patches): read_site_file first, apply the customer's change, send the whole file back. Web file types only (HTML, CSS, JS, JSON, text, SVG, images, fonts); never PHP, .htaccess or hidden files. The previous version of every replaced file is kept in a restore point outside the served tree. Two-step: (1) confirm:false previews the paths and sizes and says which site; read it to the customer and get an explicit yes. (2) ONLY after an explicit yes in their most recent message, call with confirm:true. 2 MB per call, 1 MB per file; a whole site goes through "Move a site here" in the dashboard, not this.
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": {
"domain": "<domain>",
"files": "<files>"
},
"name": "write_site_files"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| files | Yes | The files to write, each with its full content. | |
| domain | Yes | The hosted site's domain. | |
| confirm | No | false (default) returns the preview; true writes and publishes. Pass true ONLY after explicit user confirmation. |