common-add-base-template-by-id
Adds a base template to a template item by its ID.
Read and write Sitecore from an agent — items, GraphQL, security and PowerShell — across XM Cloud and XM/XP.
LABSCO SUMMARY
The Item Service handles ordinary content, GraphQL answers the read-heavy questions after you introspect the schema, and PowerShell Extensions covers everything the first two do not, with the command documentation available so a model can write a correct script. The security surface is unusually complete: ACLs, locks, roles and domains are all here, which makes this an administration tool as much as a content one, and worth scoping credentials for accordingly.
A Sitecore server that bridges three API surfaces at once: the Item Service, GraphQL endpoints per schema, and Sitecore PowerShell Extensions.
A reachable Sitecore instance and credentials for each surface you enable: GRAPHQL_ENDPOINT with GRAPHQL_SCHEMAS, GRAPHQL_API_KEY and optional extra headers; ITEM_SERVICE_SERVER_URL with ITEM_SERVICE_DOMAIN, ITEM_SERVICE_USERNAME and ITEM_SERVICE_PASSWORD; and POWERSHELL_SERVER_URL with the matching POWERSHELL_DOMAIN, POWERSHELL_USERNAME and POWERSHELL_PASSWORD. Published on npm as @antonytm/mcp-sitecore-server, with Docker and from-source options. TRANSPORT selects stdio, streamable-http or sse. Works with XM Cloud and with XM/XP.
One command plus a key — npx -y @antonytm/mcp-sitecore-server, then supply credentials
USE CASES
Search for the item, then read it and its children by id or path.
Create the item under its parent from the template id, then edit its fields.
Introspect the schema so the query is valid, then run it against edge or master.
Read the PowerShell command documentation, then run the script against the instance.
Read the item's access list, test it for the account in question, and set the entry that is missing.
Read the item's template and the items that reference it before touching anything.
Counted once with only startup setup. Other versions, modes or optional credentials may expose a different list.
common-add-base-template-by-idAdds a base template to a template item by its ID.
common-add-base-template-by-pathAdds a base template to a template item by its path.
common-add-item-version-by-idCreates a version of the item (by its id) in a new language based on an existing language version.
common-add-item-version-by-pathCreates a version of the item (by its path) in a new language based on an existing language version.
common-convert-from-item-clone-by-idConverts an item from a clone to a fully independent item by its ID.
common-convert-from-item-clone-by-pathConverts an item from a clone to a fully independent item by its path.
common-get-archiveGets Sitecore database archives.
common-get-archive-itemGets a list of items found in the specified archive.
common-get-cacheGets information about Sitecore caches.
common-get-databaseGets information about Sitecore databases.
common-get-item-clone-by-idReturns all the clones for the specified item by its ID.
common-get-item-clone-by-pathReturns all the clones for the specified item by its path.
common-get-item-field-by-idGets item fields as either names or fields or template fields by its ID.
common-get-item-field-by-pathGets item fields as either names or fields or template fields by its path.
common-get-item-reference-by-idGets item references for a Sitecore item by its ID, showing where it is used throughout the system.
common-get-item-reference-by-pathGets item references for a Sitecore item by its path, showing where it is used throughout the system.
common-get-item-referrer-by-idGets items referring to a Sitecore item by its ID, showing which items reference it.
common-get-item-referrer-by-pathGets items referring to a Sitecore item by its path, showing which items reference it.
common-get-item-template-by-idGets template information for a Sitecore item by its ID.
common-get-item-template-by-pathGets template information for a Sitecore item by its path.
common-get-item-workflow-event-by-idGets entries from the workflow history for the specified item by its ID.
common-get-item-workflow-event-by-pathGets entries from the workflow history for the specified item by its path.
common-get-sitecore-jobGets list of the current Sitecore jobs.
common-invoke-workflow-by-idExecutes workflow action for a Sitecore item by its ID.
common-invoke-workflow-by-pathExecutes workflow action for a Sitecore item by its path.
common-new-item-clone-by-idCreates a new item clone based on the item provided by its ID.
common-new-item-clone-by-pathCreates a new item clone based on the item provided by its path.
common-new-item-workflow-event-by-idCreates a new entry in the workflow history for a Sitecore item by its ID.
common-new-item-workflow-event-by-pathCreates a new entry in the workflow history for a Sitecore item by its path.
common-publish-item-by-idPublishes a Sitecore item by its ID.
common-publish-item-by-pathPublishes a Sitecore item by its path.
common-remove-archive-itemRemoves items permanently from the specified archive.
common-remove-base-template-by-idRemoves a base template from a template item by its ID.
common-remove-base-template-by-pathRemoves a base template from a template item by its path.
common-remove-item-version-by-idRemoves a version of a Sitecore item by ID.
common-remove-item-version-by-pathRemoves a version of a Sitecore item by path.
common-reset-item-field-by-idResets item fields, specified as either names, fields or template fields by ID.
common-reset-item-field-by-pathResets item fields, specified as either names, fields or template fields by path.
common-restart-applicationRestarts the Sitecore Application pool.
common-restore-archive-itemRestores items to the original database from the specified archive.
common-set-item-template-by-idSets the item template by the item's ID.
common-set-item-template-by-pathSets the item template by the item's path.
common-test-base-template-by-idChecks if the item inherits from the specified template by its ID.
common-test-base-template-by-pathChecks if the item inherits from the specified template by its path.
common-update-item-referrer-by-idUpdates all references to the specified item (by its ID) to point to a new provided in the -NewTarget or removes links to the item.
common-update-item-referrer-by-pathUpdates all references to the specified item (by its path) to point to a new provided in the -NewTarget or removes links to the item.
configPrints the configuration of the Sitecore MCP server.
get-powershell-documentationGets the documentation describing all Sitecore Powershell commands.
indexing-find-itemFinds items using the Sitecore Content Search API. Date format should be in ISO 8601 format (e.g., '2023-10-01T00:00:00Z').
indexing-get-search-indexGet information about Sitecore search indexes. Can filter by name, database, running status, or corrupted status.
indexing-initialize-search-indexInitialize one or more Sitecore search indexes. If no name is provided, all indexes will be initialized.
indexing-initialize-search-index-item-by-idRebuilds the index for a given tree with the specified root item by id and index name. Supports wildcard filtering for the index name.
indexing-initialize-search-index-item-by-pathRebuilds the index for a given tree with the specified root item by path and index name. Supports wildcard filtering for the index name.
indexing-remove-search-index-item-by-idRemoves the item with the specified ID from the search index. Supports wildcard filtering for the index name.
indexing-remove-search-index-item-by-pathRemoves the item with the specified path from the search index. Supports wildcard filtering for the index name.
indexing-resume-search-indexResume one or more Sitecore search indexes. If no name is provided, all paused indexes will be resumed.
indexing-stop-search-indexStop one or more Sitecore search indexes. If no name is provided, all running indexes will be stopped.
indexing-suspend-search-indexSuspend one or more Sitecore search indexes. If no name is provided, all running indexes will be suspended.
introspection-graphql-edgeIntrospection Sitecore GraphQL edge schema, use this tool before doing a query to get the schema information if you do not have it available as a resource already.
introspection-graphql-masterIntrospection Sitecore GraphQL master schema, use this tool before doing a query to get the schema information if you do not have it available as a resource already.
item-service-create-itemCreate a new Sitecore item under parent path with name using template id.
item-service-delete-itemDelete a Sitecore item by its ID.
item-service-edit-itemEdit a Sitecore item by its ID.
item-service-get-itemGet a Sitecore item by its ID.
item-service-get-item-by-pathGet a Sitecore item by its path.
item-service-get-item-childrenGet children of a Sitecore item by its ID.
item-service-get-item-descendantsGet descendants of a Sitecore item by its ID.
item-service-get-languagesGet Sitecore languages.
item-service-run-stored-queryRun a stored Sitecore query by its definition item ID.
item-service-run-stored-searchRun a stored Sitecore search by its definition item ID.
item-service-search-itemsSearch Sitecore items using the ItemService RESTful API.
logging-get-logsRetrieves Sitecore logs from the log directory.
presentation-add-placeholder-setting-by-idAdds a placeholder setting to the item specified by ID.
presentation-add-placeholder-setting-by-pathAdds a placeholder setting to the item specified by path.
presentation-add-rendering-by-idAdds a rendering to presentation of an item specified by item ID.
presentation-add-rendering-by-pathAdds a rendering to presentation of an item specified by path.
presentation-get-default-layout-deviceGets the default layout.
presentation-get-layout-by-idGets item layout by Id.
presentation-get-layout-by-pathGets item layout by path.
presentation-get-layout-deviceGets the layout for the device specified.
presentation-get-placeholder-setting-by-idGets placeholder setting assigned on the item specified by ID.
presentation-get-placeholder-setting-by-pathGets placeholder setting assigned on the item specified by path.
presentation-get-rendering-by-idGets rendering definition by item id.
presentation-get-rendering-by-pathGets rendering definition by item path.
presentation-get-rendering-parameter-by-idGets rendering parameter for the item specified by ID.
presentation-get-rendering-parameter-by-pathGets rendering parameter for the item specified by path.
presentation-merge-layout-by-idMerges final and shared layouts by item Id.
presentation-merge-layout-by-pathMerges final and shared layouts by item path.
presentation-remove-placeholder-setting-by-idRemoves placeholder setting from the item specified by ID.
presentation-remove-placeholder-setting-by-pathRemoves placeholder setting from the item specified by path.
presentation-remove-rendering-by-idRemoves renderings from an item by owners item ID.
presentation-remove-rendering-by-pathRemoves renderings from an item by owners item path.
presentation-remove-rendering-parameter-by-idRemoves the specified rendering parameter from the rendering placed on the item specified by ID.
presentation-remove-rendering-parameter-by-pathRemoves the specified rendering parameter from the rendering placed on the item specified by path.
presentation-reset-layout-by-idResets the layout of an item by Id.
presentation-reset-layout-by-pathResets the layout of an item by path.
presentation-set-layout-by-idSets layout for an item specified by Id.
presentation-set-layout-by-pathSets layout for an item specified by path.
presentation-set-rendering-by-idUpdates rendering specified by item ID with new values.
presentation-set-rendering-by-pathUpdates rendering specified by item path with new values.
presentation-set-rendering-parameter-by-idAdds and updates the specified rendering parameter from the rendering placed on the item specified by ID.
presentation-set-rendering-parameter-by-pathAdds and updates the specified rendering parameter from the rendering placed on the item specified by path.
presentation-switch-rendering-by-idSwitches an existing rendering specified by item ID with an alternate one for the item specified by item ID.
presentation-switch-rendering-by-pathSwitches an existing rendering specified by path with an alternate one for the item specified by path.
presentation-switch-rendering-by-unique-idSwitches an existing rendering specified by unique ID with an alternate one for the item specified by item ID.
provider-get-item-by-idGets a Sitecore item by its ID.
provider-get-item-by-pathGets a Sitecore item by its path.
provider-get-item-by-queryGets a Sitecore item by Sitecore query.
provider-get-item-by-uriGets a Sitecore item by its URI.
query-graphql-edgeQuery a Sitecore GraphQL edge endpoint with the given query and variables.
query-graphql-masterQuery a Sitecore GraphQL master endpoint with the given query and variables.
run-powershell-scriptRuns a PowerShell script and returns the output.
security-add-item-acl-by-idAdds an access control entry to a Sitecore item by its ID.
security-add-item-acl-by-pathAdds an access control entry to a Sitecore item by its path.
security-add-role-memberAdds a member to a Sitecore role.
security-clear-item-acl-by-idClears all access rules from a Sitecore item by its ID.
security-clear-item-acl-by-pathClears all access rules from a Sitecore item by its path.
security-disable-userDisables the Sitecore user account.
security-enable-userEnables the Sitecore user account.
security-get-current-userGet the current Sitecore user.
security-get-domainGet all Sitecore domains.
security-get-domain-by-nameGet a Sitecore domain by its name.
security-get-item-acl-by-idGets the access control list (ACL) of a Sitecore item by its ID.
security-get-item-acl-by-pathGets the access control list (ACL) of a Sitecore item by its path.
security-get-role-by-filterGet Sitecore roles by filter criteria.
security-get-role-by-identityGet a Sitecore role by its identity.
security-get-role-memberGet members of a Sitecore role.
security-get-user-by-filterGet a Sitecore users by filter.
security-get-user-by-identityGet a Sitecore user by its name.
security-lock-item-by-idLock a Sitecore item by its ID.
security-lock-item-by-pathLock a Sitecore item by its path.
security-new-domainCreates a new Sitecore domain.
security-new-roleCreates a new Sitecore role.
security-new-userCreates a new Sitecore user.
security-protect-item-by-idProtect a Sitecore item by its ID.
security-protect-item-by-pathProtect a Sitecore item by its path.
security-remove-domainRemoves a Sitecore domain.
security-remove-roleRemoves a Sitecore role.
security-remove-role-memberRemoves members from a Sitecore role.
security-remove-userRemoves the Sitecore user.
security-set-item-acl-by-idSets an access control entry to a Sitecore item by its ID.
security-set-item-acl-by-pathSets an access control entry to a Sitecore item by its path.
security-set-userUpdates properties of a Sitecore user account.
security-set-user-passwordSets a new password for a Sitecore user.
security-test-accountTests if a Sitecore user exists and has specific properties.
security-test-item-acl-by-idTests whether a user or role has specific access rights to a Sitecore item by its ID.
security-test-item-acl-by-pathTests whether a user or role has specific access rights to a Sitecore item by its path.
security-unlock-item-by-idUnlocks a Sitecore item by its ID.
security-unlock-item-by-pathUnlocks a Sitecore item by its path.
security-unlock-userUnlocks a Sitecore user account that has been locked out due to failed login attempts.
security-unprotect-item-by-idUnprotect a Sitecore item by its ID.
security-unprotect-item-by-pathUnprotect a Sitecore item by its path.
sitecore-cli-documentationGets Sitecore CLI documentation describing the most often used commands like index rebuild, item serialization, etc.
BEFORE YOU INSTALL
153 tools when we connected. GraphQL tools are per schema, so GRAPHQL_SCHEMAS changes the count. Six unchecked security import, export, login and logout tools are not registered. Two documented names are misspelled; the shipped ones are introspection-graphql-edge/-master and security-test-account.
All 3 documented clients run the server on your machine.
CONTEXT COST
Rated by the size of the 153 tool definitions that ride along on every turn, not by how many there are
INSTALLATION
npx -y @antonytm/mcp-sitecore-serverCheck the values in the block before you paste it: GRAPHQL_ENDPOINT, ITEM_SERVICE_SERVER_URL and POWERSHELL_SERVER_URL point at your Sitecore instance (xmcloudcm.localhost is the project's local example), GRAPHQL_API_KEY is the API key for your GraphQL endpoint, and the USERNAME and PASSWORD pairs are the Sitecore account used for Item Service and PowerShell Remoting authentication (admin / b is the example login).
{
"mcpServers": {
"Sitecore": {
"type": "stdio",
"command": "npx",
"args": [
"@antonytm/mcp-sitecore-server@latest"
],
"env": {
"TRANSPORT": "stdio",
"GRAPHQL_ENDPOINT": "https://xmcloudcm.localhost/sitecore/api/graph/",
"GRAPHQL_SCHEMAS": "edge,master,core",
"GRAPHQL_API_KEY": "{6D3F291E-66A5-4703-887A-D549AF83D859}",
"GRAPHQL_HEADERS": "",
"ITEM_SERVICE_DOMAIN": "sitecore",
"ITEM_SERVICE_USERNAME": "admin",
"ITEM_SERVICE_PASSWORD": "b",
"ITEM_SERVICE_SERVER_URL": "https://xmcloudcm.localhost/",
"POWERSHELL_DOMAIN": "sitecore",
"POWERSHELL_USERNAME": "admin",
"POWERSHELL_PASSWORD": "b",
"POWERSHELL_SERVER_URL": "https://xmcloudcm.localhost/"
}
}
}
}Check the values in the block before you paste it: GRAPHQL_ENDPOINT, ITEM_SERVICE_SERVER_URL and POWERSHELL_SERVER_URL point at your Sitecore instance (xmcloudcm.localhost is the project's local example), GRAPHQL_API_KEY is the API key for your GraphQL endpoint, and the USERNAME and PASSWORD pairs are the Sitecore account used for Item Service and PowerShell Remoting authentication (admin / b is the example login).
{
"servers": {
"Sitecore": {
"type": "stdio",
"command": "npx",
"args": [
"@antonytm/mcp-sitecore-server@latest"
],
"env": {
"TRANSPORT": "stdio",
"GRAPHQL_ENDPOINT": "https://xmcloudcm.localhost/sitecore/api/graph/",
"GRAPHQL_API_KEY": "{6D3F291E-66A5-4703-887A-D549AF83D859}",
"ITEM_SERVICE_USERNAME": "admin",
"ITEM_SERVICE_PASSWORD": "b",
"ITEM_SERVICE_SERVER_URL": "https://xmcloudcm.localhost/",
"POWERSHELL_USERNAME": "admin",
"POWERSHELL_PASSWORD": "b",
"POWERSHELL_SERVER_URL": "https://xmcloudcm.localhost/"
}
}
}
}Check the values in the block before you paste it: GRAPHQL_ENDPOINT, ITEM_SERVICE_SERVER_URL and POWERSHELL_SERVER_URL point at your Sitecore instance (xmcloudcm.localhost is the project's local example), GRAPHQL_API_KEY is the API key for your GraphQL endpoint, and the USERNAME and PASSWORD pairs are the Sitecore account used for Item Service and PowerShell Remoting authentication (admin / b is the example login).
{
"mcpServers": {
"Sitecore": {
"type": "stdio",
"command": "npx",
"args": [
"@antonytm/mcp-sitecore-server@latest"
],
"env": {
"TRANSPORT": "stdio",
"GRAPHQL_ENDPOINT": "https://xmcloudcm.localhost/sitecore/api/graph/",
"GRAPHQL_API_KEY": "{6D3F291E-66A5-4703-887A-D549AF83D859}",
"ITEM_SERVICE_USERNAME": "admin",
"ITEM_SERVICE_PASSWORD": "b",
"ITEM_SERVICE_SERVER_URL": "https://xmcloudcm.localhost/",
"POWERSHELL_USERNAME": "admin",
"POWERSHELL_PASSWORD": "b",
"POWERSHELL_SERVER_URL": "https://xmcloudcm.localhost/"
}
}
}
}