Skip to main content
Glama
@cmssy/mcp-server

@cmssy/mcp-server

Official

Add block to page

add_block_to_page
Destructive

Adds a block to a page and generates its block ID automatically. Inserts content blocks at a set position in the page body or layout blocks into a named region.

Instructions

Add a block to a page (auto-generates the block id). Pass layoutRegion to add a layout block; omit it for a content block in the page body. If the result includes blockWarnings, the saved content violates the workspace block manifest (unknown field, wrong value shape, or a stored block whose type is no longer registered) - correct the content and save again, unless the warning is about a stored block whose type is no longer registered: that one is a manifest problem, so restore or sync the type, or find the block with list_block_usage and migrate or remove it. When the warnings also say when the workspace block manifest was last synced, the field or type may simply be newer than the manifest: if the site's code declares it, keep the content and sync the manifest (cmssy sync-manifest in the site's repo) instead. A block whose type the workspace block manifest does not register is refused unless the page already stores that block - pick registered types from list_block_types.

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": {
      "pageId": "<pageId>",
      "block": "<block>"
    },
    "name": "add_block_to_page"
  }
}

Input Schema

NameRequiredDescriptionDefault
blockYes
pageIdYesPage id or slug
positionNo0-based insert position (content blocks only; default: end)
layoutRegionNoLayout region (e.g. 'header','footer') for a layout block; omit for a content block

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed3 schema fields changedv0.73.2
    • addedInput schema / additionalProperties
      Added value: +false
    • changedInput schema / properties / pageId / description
      Previous value: -"Page id"New value: +"Page id or slug"
    • addedInput schema / required
      Added value: +[
      +  "pageId",
      +  "block"
      +]
  2. First observedv0.73.1

TDQS

A4/5.0
Behavior4/5

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

Annotations already declare readOnlyHint=false and destructiveHint=true; the description goes further by disclosing that ids are auto-generated and by giving a detailed remediation path for blockWarnings, including who can fix the problem (restore/sync the type, migrate via list_block_usage, or run cmssy sync-manifest in the site repo). It does not mention page-lock or publish-state requirements implied by the take_over_page_lock sibling, leaving a gap for a mutating tool.

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

Conciseness3/5

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

The purpose and layoutRegion rule are front-loaded, which is good, but the blockWarnings sentence is a sprawling multi-clause run-on that repeats 'a stored block whose type is no longer registered' three times. The remediation logic could be structured as a short list rather than one dense paragraph.

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

Completeness4/5

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

For a 4-parameter nested mutation tool with no output schema, the description covers the important non-obvious behavior: auto-generated ids, layout vs content mode, and the full meaning and resolution of blockWarnings. Missing only preconditions such as page lock or publish state, which matter for a destructive write.

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

Parameters3/5

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

Schema coverage is 75% and the schema already documents pageId, position, layoutRegion, and the block content shape, so the description's restatement of layoutRegion adds little. It never mentions the position parameter or the meaning of style/advanced/settings, so it does not compensate for the remaining coverage gap beyond the baseline.

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?

Opens with a specific verb+resource ('Add a block to a page') plus a key side effect (auto-generates the block id), then immediately splits the operation into two modes (layout block via layoutRegion vs content block in the page body). This makes it distinguishable from update_block_content, patch_block_content, and remove_block_from_page 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 conditional guidance ('Pass layoutRegion to add a layout block; omit it for a content block in the page body') and routes the agent to list_block_types when picking block types and list_block_usage when hunting an existing block. It stops short of stating when to prefer this over a sibling that writes blocks in bulk, but the add-vs-update distinction is clear from the verb.

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