Skip to main content
Glama
Antonytm

mcp-sitecore-server

by Antonytm

get-allowed-components-by-placeholder

Read-only

Lists renderings a Sitecore placeholder permits before you add a component, using site/global settings and dynamic wildcard matching. Returns allowed control IDs and unresolved IDs.

Instructions

Lists the renderings a placeholder allows on a given page, read from the placeholder settings items that govern it. Call this before adding a rendering: a placeholder that forbids a component will still accept it silently, and the page will render. Resolves site-level settings first (/Presentation/Placeholder Settings) and falls back to the global tree (/sitecore/layout/Placeholder Settings/Project/...); settingsItemPath in the result says which item answered. Handles dynamic placeholders: a runtime path like /headless-main/page-section-1/container-2 is matched on its leaf segment against wildcard keys such as container-{*}. Allowed control IDs that resolve to no item are reported under 'Unresolved' rather than dropped silently — that is a content defect worth seeing. Found=false means no settings item governs the key, so check the spelling before treating it as unrestricted.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
pathNoThe full path of the item, database prefix optional (e.g. master:/sitecore/content/Stride/Cova/Home or /sitecore/content/Stride/Cova/Home). Supply this or pageId.
pageIdNoThe ID of the page item (e.g. {110D559F-DEA5-42EA-9C1C-8A5DF7E70EF9}). Supply this or path.
projectNoOverrides the folder searched under /sitecore/layout/Placeholder Settings/Project. Defaults to the project (tenant) folder of the site the item belongs to, and falls back to the whole global Placeholder Settings tree.
databaseNoThe database to read. Defaults to master, and is ignored when path carries its own prefix.
languageNoThe item language. Defaults to the context language.
placeholderPathYesThe placeholder to resolve. Accepts a bare key ('headless-main', 'container', 'container-{*}') or a full runtime placeholder path ('/headless-main/page-section-1/container-2'), in which case the leaf segment is matched — including against the wildcard keys dynamic placeholders use.

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv2.0.5

TDQS

A4.6/5.0
Behavior5/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

Despite readOnlyHint covering the safety profile, the description adds substantial behavioral context: the two-tier resolution order (site-level then global fallback), which item answered via settingsItemPath, dynamic-placeholder leaf matching against wildcard keys, and how unresolved control IDs and Found=false are surfaced. This is far beyond what annotations provide.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The purpose and pre-call guidance are front-loaded, then resolution order and edge cases follow. It is dense and every sentence carries information (resolution order, dynamic placeholders, Unresolved, Found=false), though the length pushes against ideal conciseness.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness5/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

With no output schema, the description carries the burden of explaining returns and does so thoroughly — settingsItemPath, Unresolved, and Found=false are all defined with their implications. Nothing material for correct invocation or interpretation is missing.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters4/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema coverage is 100%, so the baseline is 3, but the description adds real meaning: it explains the bare-key vs full-runtime-path forms of placeholderPath and the leaf-segment matching, and clarifies the project parameter's precedence and fallback. It stops short of detailing path/pageId/database/language interactions beyond the schema.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

States a concrete verb and resource — 'Lists the renderings a placeholder allows on a given page' — and immediately grounds it in the placeholder settings items that govern it. An agent can distinguish this from sibling tools like add-rendering-to-placeholder and presentation-get-placeholder-setting without opening any schema.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines4/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

Gives explicit when-to-use context: 'Call this before adding a rendering,' with a concrete consequence ('a placeholder that forbids a component will still accept it silently'). It routes the agent into the add-rendering workflow well, though it doesn't name a specific sibling as an alternative or state when not to call it.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Deploy Server

Other Tools