Skip to main content
Glama

Merge or unmerge cells

merge_cells
Destructive

Merge a cell range into one cell or split a merged range back into individual cells. Keeps only the top-left value when merging.

Instructions

Merge a range into one cell, or split a merged range again.

Merging keeps only the top-left value.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
pathYesPath to an .xlsx, .xlsm, .xltx or .xltm file. Relative paths are resolved in the server's workbook directory when one is configured; otherwise use an absolute path.
rangeYesA cell or rectangular range in A1 notation, e.g. 'A1:D20'.
sheetYesWorksheet name, e.g. 'Sheet1'.
actionNoMerge the range or split it again.merge

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
resultYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed9 schema fields changedv1.1.1
    • addedInput schema / properties / action
      Added value: +{
      +  "default": "merge",
      +  "description": "Merge the range or split it again.",
      +  "enum": [
      +    "merge",
      +    "unmerge"
      +  ],
      +  "title": "Action",
      +  "type": "string"
      +}
    • removedInput schema / properties / end_cell
      Removed value: -{
      -  "title": "End Cell",
      -  "type": "string"
      -}
    • removedInput schema / properties / filepath
      Removed value: -{
      -  "title": "Filepath",
      -  "type": "string"
      -}
    • addedInput schema / properties / path
      Added value: +{
      +  "description": "Path to an .xlsx, .xlsm, .xltx or .xltm file. Relative paths are resolved in the server's workbook directory when one is configured; otherwise use an absolute path.",
      +  "title": "Path",
      +  "type": "string"
      +}
    • addedInput schema / properties / range
      Added value: +{
      +  "description": "A cell or rectangular range in A1 notation, e.g. 'A1:D20'.",
      +  "title": "Range",
      +  "type": "string"
      +}
    • addedInput schema / properties / sheet
      Added value: +{
      +  "description": "Worksheet name, e.g. 'Sheet1'.",
      +  "title": "Sheet",
      +  "type": "string"
      +}
    • removedInput schema / properties / sheet_name
      Removed value: -{
      -  "title": "Sheet Name",
      -  "type": "string"
      -}
    • removedInput schema / properties / start_cell
      Removed value: -{
      -  "title": "Start Cell",
      -  "type": "string"
      -}
    • changedInput schema / required
      Previous value: -[
      -  "filepath",
      -  "sheet_name",
      -  "start_cell",
      -  "end_cell"
      -]New value: +[
      +  "path",
      +  "sheet",
      +  "range"
      +]
  2. First observedv1.0.0

TDQS

A4/5.0
Behavior4/5

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

Annotations declare destructiveHint=true and readOnlyHint=false, but the description adds the concrete consequence: only the top-left value survives a merge. That is meaningful data-loss context beyond the binary hint. It stops short of describing unmerge edge cases or errors.

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

Conciseness5/5

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

Two short sentences, front-loaded with the operation and immediately followed by the critical data-loss note. Nothing redundant; every sentence carries weight.

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?

With a full schema, output schema present, and annotations covering the safety profile, the description only needs to convey purpose and the destructive consequence, which it does. Edge-case behavior (unmerging a non-merged range, partial overlaps) is left unstated.

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 description coverage is 100% and each parameter (path, sheet, range, action) is fully documented in the schema, including the enum and default. The description adds no parameter-level detail, so the baseline of 3 applies.

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 (merge/split) and resource (a cell range), and explicitly covers both directions of the operation tied to the `action` parameter. An agent immediately understands this handles cell merging, distinct from formatting or writing siblings.

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

Usage Guidelines3/5

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

The two modes (merge vs. split) are stated, which implies when each action applies, but no alternatives are named and no prerequisites or conflict conditions (e.g., overlapping merged ranges) are given. No sibling tool is referenced for comparison.

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