> For the complete documentation index, see [llms.txt](https://kartiktambi.gitbook.io/app-docs/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://kartiktambi.gitbook.io/app-docs/quick-guides/google-sheets-as-an-api.md).

# Google Sheets as an API

## Updating Multiple fields at once

The current update block of Google Sheets datasource in Thunkable allows us to update only one field at a time. Working with this block is easy, but certainly not efficient if we want to update multiple fields for a certain row.

Let's have a look at how we can do this efficiently with Google Apps Script & the Thunkable API component.

### Setting up Apps Script on our Spreadsheet

![In the Extensions menu in toolbar, click on Apps Script, which opens a new app script project for this spreadsheet in a new tab.](/files/Wie7zszG0s2jCqJtao8W)

![The new tab opened will look like this, which would have code.gs file opened in our Apps Script project. You can rename your apps script project by clicking the 'Untitled Project' beside the apps script logo.](/files/Md9OmRJuOSHy73dg8XbM)

![](/files/tc3dJAEelzHiXgItYLMq)

![](/files/N9TIPNfYOyolTxbnooHB)

![](/files/MGPdNAJAykH5SkWUBeNM)

![](/files/yF8zOCSrMVZqhHaJxJmF)

![](/files/WXWo9uzQemtlefMAIyQl)


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://kartiktambi.gitbook.io/app-docs/quick-guides/google-sheets-as-an-api.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
