Skip to main content
Glama

Insert rows or columns

insert_rows_or_columns

Insert empty rows or columns before a given position in Excel, shifting cells down or right; dependent formulas, merged ranges, charts, and tables are not updated.

Instructions

Insert empty rows or columns before position at, shifting the rest down or right.

Formulas, merged ranges, charts and tables that refer to shifted cells are not updated, so check them afterwards.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
atYes1-based row number, or 1-based column number (A=1).
axisYesWhether to act on rows or columns.
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.
countNoHow many rows or columns.
sheetYesWorksheet name, e.g. 'Sheet1'.

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
resultYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. Addedv1.1.1

TDQS

A4.2/5.0
Behavior4/5

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

Annotations already declare the safety profile (readOnlyHint=false, idempotentHint=false, destructiveHint=false), so the bar is lower. The description adds genuinely useful non-obvious behavior: formulas, merged ranges, charts and tables referencing shifted cells are not updated. It does not contradict the non-destructive hint, since nothing is deleted, only shifted.

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, the core operation front-loaded, and the side-effect caveat in a compact trailing clause. Every sentence earns its place with no repetition of schema fields.

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?

An output schema exists, so return values need not be described. The description covers what the operation does and the important downstream side effects on formulas and structures; edge cases such as behavior beyond the last row or on a missing sheet are left implicit but are minor for this tool.

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 contributes real meaning by clarifying the insertion semantics ('before position `at`') and tying axis to physical direction ('down or right') beyond the bare '1-based row/column number' wording in 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 specific verb (insert), resource (empty rows or columns) and positional scope (before position `at`, shifting contents down or right). The direction semantics make it unmistakably distinct from the sibling delete_rows_or_columns without opening either schema.

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 only implied by the precise operation described; there is no explicit when-to-use statement and no routing toward alternatives such as write_range or set_sheet_layout. The 'check them afterwards' line is a caution rather than guidance on selection, so a minimum-viable 3 fits.

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