Skip to main content
Glama

Sheets Write

sheets_write
Idempotent

Write data to a Google Sheet range, overwriting existing values. Specify sheet name, range (e.g., 'A1:C10'), and row data.

Input Schema

NameRequiredDescriptionDefault
rangeYesA1 notation range (e.g., "Sheet1!A1")
valuesYesArray of rows, each row is an array of cell values
spreadsheet_idYesSpreadsheet ID
value_input_optionNoHow to interpret input. USER_ENTERED (default) parses formulas/dates/numbers. RAW stores literal strings.

Output Schema

NameRequiredDescriptionDefault
errorNoError code if connection required
messageNoError message if connection required
updatedRowsNoNumber of rows updated
updatedCellsNoTotal number of cells updated
updatedRangeNoRange that was updated
spreadsheetIdNoSpreadsheet ID that was written to
updatedColumnsNoNumber of columns updated

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed1 schema field changed
    • changedOutput schema / (root)
      Previous value: -nullNew value: +{
      +  "properties": {
      +    "error": {
      +      "description": "Error code if connection required",
      +      "type": "string"
      +    },
      +    "message": {
      +      "description": "Error message if connection required",
      +      "type": "string"
      +    },
      +    "spreadsheetId": {
      +      "description": "Spreadsheet ID that was written to",
      +      "type": "string"
      +    },
      +    "updatedCells": {
      +      "description": "Total number of cells updated",
      +      "type": "integer"
      +    },
      +    "updatedColumns": {
      +      "description": "Number of columns updated",
      +      "type": "integer"
      +    },
      +    "updatedRange": {
      +      "description": "Range that was updated",
      +      "type": "string"
      +    },
      +    "updatedRows": {
      +      "description": "Number of rows updated",
      +      "type": "integer"
      +    }
      +  },
      +  "type": "object"
      +}
  2. Changed1 schema field changed
    • addedInput schema / examples
      Added value: +[
      +  {
      +    "range": "Sheet1!A1",
      +    "spreadsheet_id": "1BxiMVs0XRA5nFMmqvzausWYMYq6nS8twLu0gKBvMZsk",
      +    "values": [
      +      [
      +        "Name",
      +        "Age",
      +        "City"
      +      ],
      +      [
      +        "Alice",
      +        "30",
      +        "New York"
      +      ],
      +      [
      +        "Bob",
      +        "25",
      +        "Los Angeles"
      +      ]
      +    ]
      +  },
      +  {
      +    "range": "Data!B2:C5",
      +    "spreadsheet_id": "1BxiMVs0XRA5nFMmqvzausWYMYq6nS8twLu0gKBvMZsk",
      +    "value_input_option": "USER_ENTERED",
      +    "values": [
      +      [
      +        "100",
      +        "200"
      +      ],
      +      [
      +        "300",
      +        "400"
      +      ]
      +    ]
      +  }
      +]
  3. First observed

TDQS

A3.9/5.0
Behavior3/5

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

Annotations already provide readOnlyHint=false, idempotentHint=true, destructiveHint=false. The description adds that it 'overwrites existing values', which is consistent. However, it does not add significant behavioral context beyond what annotations already convey, such as authentication needs or rate limits.

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?

The description is a single, efficient sentence that front-loads the purpose and includes a concrete range example. Every word earns its place, with no fluff or redundancy.

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?

Given the complete schema with examples and the existence of an output schema, the description sufficiently covers the tool's purpose and basic usage. It explicitly mentions the key parameters (sheet name, range, row data) and the fact that it overwrites, which is the core functionality.

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% with detailed parameter descriptions and examples. The description merely summarizes parameters ('Specify sheet name, range, and row data') without adding new semantic meaning beyond what the schema provides.

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 tool writes data to a Google Sheet range and overwrites existing values. It uses a specific verb ('write') and resource ('Google Sheet range'), and distinguishes itself from sibling tools like sheets_append and sheets_read by explicitly mentioning overwriting.

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 description implies when to use this tool (when overwriting values) but does not explicitly contrast with sheets_append for appending rows or provide when-not-to-use guidance. The differentiation is implicit through the word 'overwriting', but no alternative tools are named.

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

Try in Browser

Glama MCP Gateway

Add one secure layer between your agents and this server.