Skip to main content
Inserts or upserts rows in a Google Spreadsheet. Display name “Google Sheets Update”. Off by default.

Authentication and enablement

Requires a workspace Google Sheets OAuth integration. access_token is injected (x-variable-service: google_sheets) and is never chosen by the model. Enable the tool on the agent and bind the integration.

Inputs

  • spreadsheet_id (required): the spreadsheet ID from the URL.
  • strategy (required): insert (append) or upsert (update on key match, else append).
  • columns (required): header names, letters (A, B), or 1-based numbers. Row values map in this order.
  • rows (required): array of rows; each row’s length must equal columns.
  • sheet_name (optional): defaults to the first sheet.
  • key_column (upsert only): must also appear in columns.

Output

Counts of rows inserted/updated plus the target spreadsheet and sheet. rows_updated counts sheet rows written, so two input rows carrying the same key count once.

Limits and side effects

  • Writes to the customer’s Google Sheet.
  • Upsert matching is on key_column. If two sheet rows carry the same key the whole upsert fails rather than guessing; if two input rows carry the same key, the last one wins.
  • Matching ignores case and surrounding spaces, and the matched key cell is left as the sheet already spells it — an upsert keyed Apple against a sheet holding " apple " updates that row’s other columns without rewriting the key.

Expected errors

  • Missing/invalid Sheets integration token.
  • Empty columns or rows, or a row whose length does not match columns.
  • key_column missing on upsert.
  • Spreadsheet or sheet not found.
  • Google accepted the write but confirmed no cells were written.