common-set-item-template
Set or change the template of a Sitecore item using its ID or path, and optionally map fields to copy values between old and new templates.
Instructions
Sets the item template.
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": {
"template": "<template>"
},
"name": "common-set-item-template"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| id | No | The ID of the item to set the template for. Supply this or path. | |
| path | No | The path of the item to set the template for. Supply this or id. | |
| database | No | Database to resolve an id against (default master). | |
| 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. |