Skip to main content
Glama

Insert rows or columns

insert_rows_or_columns

Insert blank rows or columns before a specified position in an Excel sheet, shifting existing references as Excel does; unsupported edits fail.

Instructions

Insert empty rows or columns before start. All references move as in Excel; edits Excel refuses (through an array formula, PivotTable or table header) fail.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
axisYes
pathYes
countNo
sheetYes
startYes1-based row, or column number (A=1).

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed14 schema fields changedv2.0.0
    • removedInput schema / properties / at
      Removed value: -{
      -  "description": "1-based row number, or 1-based column number (A=1).",
      -  "minimum": 1,
      -  "title": "At",
      -  "type": "integer"
      -}
    • removedInput schema / properties / axis / description
      Removed value: -"Whether to act on rows or columns."
    • removedInput schema / properties / axis / title
      Removed value: -"Axis"
    • removedInput schema / properties / count / description
      Removed value: -"How many rows or columns."
    • removedInput schema / properties / count / minimum
      Removed value: -1
    • removedInput schema / properties / count / title
      Removed value: -"Count"
    • removedInput schema / properties / path / description
      Removed value: -"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."
    • removedInput schema / properties / path / title
      Removed value: -"Path"
    • removedInput schema / properties / sheet / description
      Removed value: -"Worksheet name, e.g. 'Sheet1'."
    • removedInput schema / properties / sheet / title
      Removed value: -"Sheet"
    • addedInput schema / properties / start
      Added value: +{
      +  "description": "1-based row, or column number (A=1).",
      +  "type": "integer"
      +}
    • changedInput schema / required
      Previous value: -[
      -  "path",
      -  "sheet",
      -  "axis",
      -  "at"
      -]New value: +[
      +  "path",
      +  "sheet",
      +  "axis",
      +  "start"
      +]
    • removedInput schema / title
      Removed value: -"insert_rows_or_columnsArguments"
    • changedOutput schema / (root)
      Previous value: -{
      -  "properties": {
      -    "result": {
      -      "title": "Result",
      -      "type": "string"
      -    }
      -  },
      -  "required": [
      -    "result"
      -  ],
      -  "title": "insert_rows_or_columnsOutput",
      -  "type": "object"
      -}New value: +null
  2. Addedv1.1.1

TDQS

A3.8/5.0
Behavior4/5

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

Annotations declare a non-readonly, non-idempotent, non-destructive mutation, and the description adds real behavioral value: references shift as in Excel, and edits that Excel refuses (array formulas, PivotTables, table headers) fail rather than partially applying. It does not say whether partial inserts are possible or how the new rows are returned, keeping it short of a 5.

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?

Two compact clauses, front-loaded with the core action followed by the reference-shift and failure semantics. No filler, though the failure clause is dense enough that splitting it would aid scanning.

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 mutation with annotations and no output schema, the description covers the key behavioral risks (reference shifting, refusal cases). It is incomplete only in not explaining `count` or what the tool returns/reports after insertion.

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

Parameters2/5

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

Schema description coverage is only 20% (only `start` is documented), so the description must compensate but mostly restates the insertion point already covered by the schema. `count` (default 1, max 100000) and `path`/`sheet` semantics are left entirely undocumented, and `axis` is only covered via the enum.

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 specific verb (insert) and resource (rows or columns) with a precise insertion point ('before `start`'), which is enough to distinguish it from the sibling delete_rows_or_columns and from write_range/transform_range.

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?

Usage is implied by the description (insert blank rows/columns to shift references), and the failure conditions hint at when it is inapplicable, but no alternative tool or explicit when-to-use guidance is offered against siblings like write_range or set_sheet_layout.

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