Skip to main content
Glama

Write values to many ranges

batch_write_values
DestructiveIdempotent

Overwrite multiple Google Sheets ranges in one call to reduce quota usage. Supports USER_ENTERED or RAW input; null values leave cells untouched.

Instructions

Overwrites several A1 ranges in ONE call — one write against the per-minute quota instead of one per range, so always prefer this over looping write_values. data is a list of {range, values} pairs; all are written with the same value_input_option (USER_ENTERED parses formulas/numbers/dates, RAW stores literally). Returns totalUpdatedCells and a per-range responses[] breakdown. Like write_values, null entries skip cells rather than clearing them.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
dataYesThe ranges to write, each with its own 2-D values matrix.
spreadsheet_idYesThe spreadsheet id — the long id from the URL (docs.google.com/spreadsheets/d/<spreadsheetId>/edit) or from create_spreadsheet / search_spreadsheets output.
value_input_optionNoUSER_ENTERED (default) parses formulas/numbers/dates; RAW stores literal strings.
Behavior5/5

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

The description discloses overwriting behavior (destructive), idempotent nature (consistent overwrite), and return fields (totalUpdatedCells, responses[]). It explains USER_ENTERED vs RAW and null skipping. These details add value beyond the annotations (destructiveHint, idempotentHint) without contradiction.

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?

Three sentences, each earning its place: the quota advantage, the input structure and options, and the return value. No fluff, front-loaded with the key differentiator.

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

Completeness5/5

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

For a multi-range write tool, it covers the alternative (write_values), the input format, the option semantics, null behavior, and return fields. With no output schema, it provides enough for an agent to call it correctly. The mention of returns is sufficient for the given complexity.

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 100%, so parameters are well-documented. The description adds a high-level summary of the data structure and explains value_input_option choices, but these are largely redundant with the schema. It provides narrative coherence but no substantial new semantic information.

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?

The description clearly states the action (overwrites several A1 ranges in one call), distinguishes it from looping write_values, and highlights the benefit of a single quota write. It is specific and unambiguous.

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

Usage Guidelines5/5

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

Explicitly instructs to prefer this over looping write_values, referencing the alternative directly. Also explains value_input_option semantics and null skipping, providing clear context for when to use this tool.

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

Install Server

Other Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/A1-x-Tech/mcp-google-sheets'

If you have feedback or need assistance with the MCP directory API, please join our Discord server