---
title: "Batch updates values in multiple ranges of a Google Sheet."
method: POST
path: "/batchUpdateValues"
---

# Batch updates values in multiple ranges of a Google Sheet.

`POST /batchUpdateValues`

This function allows for updating values in multiple specified ranges of a Google Sheet with provided data in a single batch request. It takes the sheet ID, an array of update inputs, and an optional value input option. The function returns a promise that resolves to an array of API responses, each containing information about an update operation in the batch.

## Request body

- object
  - `body` object — Body of the batchUpdateValues sls call
    - `arguments` unknown[], required
      - unknown
    - `auth` object — Authentication object
      - `strategy` 'oauth2' — Authentication strategy
      - `variables` unknown[] — Variables for the authentication strategy
        - unknown
    - `packageName` string — @microfox/google-sheets

## Response `200`

Successful response

- object[]
  - `spreadsheetId` string — The ID of the spreadsheet that was updated.
  - `updatedRange` string — The range (in A1 notation) that was updated.
  - `updatedRows` integer — The number of rows that were updated.
  - `updatedColumns` integer — The number of columns that were updated.
  - `updatedCells` integer — The number of cells that were updated.

## Other responses

- `400` — Bad Request - Invalid input parameters
- `403` — Forbidden - Insufficient permissions to access the sheet
- `404` — Not Found - Sheet ID not found
- `500` — Internal Server Error

## Changes

- **2025-05-29** `470b95f73df9` — 1 warning, 2 info
  - removed the optional property `items/updatedData` from the response with the `200` status
  - added the non-success response with the status `403`
  - added the non-success response with the status `404`
- **2025-05-28** `77260ff78232` — 3 info
  - removed the non-success response with the status `403`
  - removed the non-success response with the status `404`
  - added the optional property `items/updatedData` to the response with the `200` status

[Change history](https://skmtc.dev/microfox-ai/apis/google-sheets-sdk-api/changes/batchUpdateValues/post.md)

---

[API](https://skmtc.dev/microfox-ai/apis/google-sheets-sdk-api.md) · [All operations](https://skmtc.dev/microfox-ai/apis/google-sheets-sdk-api/llms.txt) · [OpenAPI document](https://skmtc-service-production.skmtc.workers.dev/v1/apis/microfox-ai/google-sheets-sdk-api/revisions/85db428f2808/schema)
