Update a block template
update_templateUpdate a WordPress block template or template part's markup to take effect site-wide immediately, storing changes in the database so the theme file remains untouched.
Instructions
Update a block template or template part's markup. This changes the layout of every page that uses it, so it takes effect site-wide immediately. WordPress stores the customisation in the database, leaving the theme's own file untouched — you can always revert in the Site Editor.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| id | Yes | Template id, e.g. "twentytwentyfour//single". | |
| kind | No | Whether the id names a template or a template part. | template |
| title | No | New template title. | |
| content | Yes | Full block markup for the template. | |
| site_id | No | Which configured WordPress site to act on. Optional — with a single site configured it is used automatically; with several, the default site is used unless you name one. Run list_sites for valid ids. | |
| description | No | New template description. |