Skip to main content
Glama
taylorwilsdon

Google Workspace MCP Server - Control Gmail, Calendar, Docs, Sheets, Slides, Chat, Forms & Drive

Resize Sheet Dimensions

resize_sheet_dimensions
Destructive

Resize columns and rows, auto-fit content, freeze panes, hide or unhide, and insert or delete rows and columns in a Google Sheet, all in one call.

Instructions

Manages sheet-level dimension properties: resize columns/rows, auto-resize to fit content, freeze rows/columns, hide/unhide rows/columns, and insert/delete rows/columns.

Every row number and column letter refers to the sheet as it was before the call, even when one call both inserts and deletes. Deletes are applied before inserts, and an insert position inside a deleted span lands where that span was.

Input Schema

NameRequiredDescriptionDefault
hide_rowsNoList of 1-based row numbers to hide. Example: [3, 4].
row_sizesNoDict mapping 1-based row numbers to pixel heights. Example: {"1": 40, "3": 60}. Can be a JSON string or Python dict.
sheet_nameNoSheet name to target. Defaults to the first sheet if not provided.
delete_rowsNoList of 1-based row numbers to delete. Example: [5, 6]. Best for non-contiguous rows.
insert_rowsNoNumber of rows to insert.
unhide_rowsNoList of 1-based row numbers to unhide. Example: [3, 4].
column_sizesNoDict mapping column letters to pixel widths. Example: {"A": 200, "C": 300}. Can be a JSON string or Python dict.
hide_columnsNoList of column letters to hide. Example: ["C", "D"].
delete_columnsNoList of column letters to delete. Example: ["E", "F"].
insert_columnsNoNumber of columns to insert.
insert_rows_atNo1-based row number to insert before. Appends to the end of the sheet if omitted.
spreadsheet_idYesThe ID of the spreadsheet. Required.
unhide_columnsNoList of column letters to unhide. Example: ["C", "D"].
auto_resize_rowsNoList of 1-based row numbers to auto-resize to fit content. Example: [1, 2].
delete_row_rangeNoContiguous range of rows to delete, as "start:end" (1-based, inclusive). Example: "5:10" deletes rows 5 through 10. More efficient than delete_rows for large contiguous ranges.
frozen_row_countNoNumber of rows to freeze from the top. Use 0 to unfreeze all rows.
insert_columns_atNoColumn letter to insert before (e.g. "C"). Appends to the end if omitted.
user_google_emailYesThe user's Google email address. Required.
auto_resize_columnsNoList of column letters to auto-resize to fit content. Example: ["A", "B"].
frozen_column_countNoNumber of columns to freeze from the left. Use 0 to unfreeze all columns.

Output Schema

NameRequiredDescriptionDefault
resultYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed26 schema fields changedv1.28.0
    • changedInput schema / properties / auto_resize_columns / anyOf
      Previous value: -[
      -  {
      -    "type": "string"
      -  },
      -  {
      -    "items": {
      -      "type": "string"
      -    },
      -    "type": "array"
      -  },
      -  {
      -    "type": "null"
      -  }
      -]New value: +[
      +  {
      +    "type": "string"
      +  },
      +  {
      +    "items": {
      +      "type": "string"
      +    },
      +    "type": "array"
      +  }
      +]
    • changedInput schema / properties / auto_resize_rows / anyOf
      Previous value: -[
      -  {
      -    "type": "string"
      -  },
      -  {
      -    "items": {
      -      "type": "integer"
      -    },
      -    "type": "array"
      -  },
      -  {
      -    "type": "null"
      -  }
      -]New value: +[
      +  {
      +    "type": "string"
      +  },
      +  {
      +    "items": {
      +      "type": "integer"
      +    },
      +    "type": "array"
      +  }
      +]
    • changedInput schema / properties / column_sizes / anyOf
      Previous value: -[
      -  {
      -    "type": "string"
      -  },
      -  {
      -    "additionalProperties": true,
      -    "type": "object"
      -  },
      -  {
      -    "type": "null"
      -  }
      -]New value: +[
      +  {
      +    "type": "string"
      +  },
      +  {
      +    "additionalProperties": true,
      +    "type": "object"
      +  }
      +]
    • changedInput schema / properties / delete_columns / anyOf
      Previous value: -[
      -  {
      -    "type": "string"
      -  },
      -  {
      -    "items": {
      -      "type": "string"
      -    },
      -    "type": "array"
      -  },
      -  {
      -    "type": "null"
      -  }
      -]New value: +[
      +  {
      +    "type": "string"
      +  },
      +  {
      +    "items": {
      +      "type": "string"
      +    },
      +    "type": "array"
      +  }
      +]
    • removedInput schema / properties / delete_row_range / anyOf
      Removed value: -[
      -  {
      -    "type": "string"
      -  },
      -  {
      -    "type": "null"
      -  }
      -]
    • addedInput schema / properties / delete_row_range / type
      Added value: +"string"
    • changedInput schema / properties / delete_rows / anyOf
      Previous value: -[
      -  {
      -    "type": "string"
      -  },
      -  {
      -    "items": {
      -      "type": "integer"
      -    },
      -    "type": "array"
      -  },
      -  {
      -    "type": "null"
      -  }
      -]New value: +[
      +  {
      +    "type": "string"
      +  },
      +  {
      +    "items": {
      +      "type": "integer"
      +    },
      +    "type": "array"
      +  }
      +]
    • removedInput schema / properties / frozen_column_count / anyOf
      Removed value: -[
      -  {
      -    "type": "integer"
      -  },
      -  {
      -    "type": "null"
      -  }
      -]
    • addedInput schema / properties / frozen_column_count / type
      Added value: +"integer"
    • removedInput schema / properties / frozen_row_count / anyOf
      Removed value: -[
      -  {
      -    "type": "integer"
      -  },
      -  {
      -    "type": "null"
      -  }
      -]
    • addedInput schema / properties / frozen_row_count / type
      Added value: +"integer"
    • changedInput schema / properties / hide_columns / anyOf
      Previous value: -[
      -  {
      -    "type": "string"
      -  },
      -  {
      -    "items": {
      -      "type": "string"
      -    },
      -    "type": "array"
      -  },
      -  {
      -    "type": "null"
      -  }
      -]New value: +[
      +  {
      +    "type": "string"
      +  },
      +  {
      +    "items": {
      +      "type": "string"
      +    },
      +    "type": "array"
      +  }
      +]
    • changedInput schema / properties / hide_rows / anyOf
      Previous value: -[
      -  {
      -    "type": "string"
      -  },
      -  {
      -    "items": {
      -      "type": "integer"
      -    },
      -    "type": "array"
      -  },
      -  {
      -    "type": "null"
      -  }
      -]New value: +[
      +  {
      +    "type": "string"
      +  },
      +  {
      +    "items": {
      +      "type": "integer"
      +    },
      +    "type": "array"
      +  }
      +]
    • removedInput schema / properties / insert_columns / anyOf
      Removed value: -[
      -  {
      -    "type": "integer"
      -  },
      -  {
      -    "type": "null"
      -  }
      -]
    • addedInput schema / properties / insert_columns / type
      Added value: +"integer"
    • removedInput schema / properties / insert_columns_at / anyOf
      Removed value: -[
      -  {
      -    "type": "string"
      -  },
      -  {
      -    "type": "null"
      -  }
      -]
    • addedInput schema / properties / insert_columns_at / type
      Added value: +"string"
    • removedInput schema / properties / insert_rows / anyOf
      Removed value: -[
      -  {
      -    "type": "integer"
      -  },
      -  {
      -    "type": "null"
      -  }
      -]
    • addedInput schema / properties / insert_rows / type
      Added value: +"integer"
    • removedInput schema / properties / insert_rows_at / anyOf
      Removed value: -[
      -  {
      -    "type": "integer"
      -  },
      -  {
      -    "type": "null"
      -  }
      -]
    • addedInput schema / properties / insert_rows_at / type
      Added value: +"integer"
    • changedInput schema / properties / row_sizes / anyOf
      Previous value: -[
      -  {
      -    "type": "string"
      -  },
      -  {
      -    "additionalProperties": true,
      -    "type": "object"
      -  },
      -  {
      -    "type": "null"
      -  }
      -]New value: +[
      +  {
      +    "type": "string"
      +  },
      +  {
      +    "additionalProperties": true,
      +    "type": "object"
      +  }
      +]
    • removedInput schema / properties / sheet_name / anyOf
      Removed value: -[
      -  {
      -    "type": "string"
      -  },
      -  {
      -    "type": "null"
      -  }
      -]
    • addedInput schema / properties / sheet_name / type
      Added value: +"string"
    • changedInput schema / properties / unhide_columns / anyOf
      Previous value: -[
      -  {
      -    "type": "string"
      -  },
      -  {
      -    "items": {
      -      "type": "string"
      -    },
      -    "type": "array"
      -  },
      -  {
      -    "type": "null"
      -  }
      -]New value: +[
      +  {
      +    "type": "string"
      +  },
      +  {
      +    "items": {
      +      "type": "string"
      +    },
      +    "type": "array"
      +  }
      +]
    • changedInput schema / properties / unhide_rows / anyOf
      Previous value: -[
      -  {
      -    "type": "string"
      -  },
      -  {
      -    "items": {
      -      "type": "integer"
      -    },
      -    "type": "array"
      -  },
      -  {
      -    "type": "null"
      -  }
      -]New value: +[
      +  {
      +    "type": "string"
      +  },
      +  {
      +    "items": {
      +      "type": "integer"
      +    },
      +    "type": "array"
      +  }
      +]
  2. Addedv1.0.1

TDQS

A3.9/5.0
Behavior4/5

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

Annotations already declare destructiveHint=true, idempotentHint=false, and openWorldHint=true, so safety is covered structurally. The description adds genuinely non-obvious behavioral semantics: all row/column references resolve against the pre-call sheet state, deletes apply before inserts, and an insert position inside a deleted span lands where that span was. It does not discuss permission requirements or reversibility, but with annotations present this is a strong addition.

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 tight paragraphs: the first front-loads the operation scope, the second carries the one piece of non-obvious behavior that matters. Every sentence earns its place and nothing is repeated from the schema.

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 20 parameters, an output schema present, and full annotation coverage, the description supplies the purpose and the ordering semantics an agent needs to call it correctly. It could add a note on whether multiple dimension operations may be combined in one call, but overall it is sufficient.

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. The description goes beyond the schema by defining cross-parameter semantics — reference resolution against the pre-call sheet, delete-before-insert ordering, and the fate of inserts inside deleted spans — which the per-parameter schema text does not express. That earns above baseline.

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

Purpose4/5

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

The description names a specific resource (sheet-level dimension properties) and enumerates concrete operations: resize, auto-resize, freeze, hide/unhide, insert/delete rows and columns. This makes clear the tool is broader than its 'resize' name suggests, distinguishing it from siblings like format_sheet_range and move_sheet_rows. It stops short of explicitly naming a sibling to route away from, so 4 rather than 5.

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?

There is no explicit statement of when to use this tool versus format_sheet_range, manage_sheet_tab, or move_sheet_rows. The operation names imply usage, and parameter descriptions contain local guidance ('best for non-contiguous rows', 'more efficient than delete_rows for large contiguous ranges'), but tool-level when/when-not guidance is absent.

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