common-set-item-template-by-path
Change the template of a Sitecore content item by specifying its path, enabling content structure updates and field mapping between templates.
Instructions
Sets the item template by the item's path.
Input Schema
TableJSON Schema
| Name | Required | Description | Default |
|---|---|---|---|
| path | Yes | The path of the item to set the template for. | |
| template | Yes | The path representing the template item. | |
| fieldsToCopy | No | The key-value pairs map the old template fields to the new template fields. The key represents the old template field, and the value represents the new template field. | |
| database | No | The database containing the item (defaults to the context database). |