wp_update_template
Updates the content of a template or template part. Reads the current version first and returns before/after snapshots.
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_id": "<site_id>",
"slug": "<slug>",
"content": "<content>"
},
"name": "wp_update_template"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| slug | Yes | The template or template part slug. | |
| type | No | The template type to update. | wp_template |
| title | No | Optional updated human-readable title. | |
| content | Yes | The new template markup. | |
| site_id | Yes | The connected site's id returned by list_sites. Call list_sites first; do not use a URL or WordPress post ID. |