# Google Drive Sheets

Each sheet you select lands as its own table in one bucket of the current project.

**Before you start**

You need:

- **A Google account that can open the spreadsheets you want to import.** You sign in with it when you authorize the configuration. The connector asks for full Google Drive access (`drive`) and read-only access to spreadsheets.

What each tab needs:

- **Prompt tab:** Kai, the **Kai Agent** button in the top bar, on supported stacks. A new Free Plan project has it from the start; elsewhere an organization admin turns it on once: Get started with Kai (/kai/getting-started/).
- **UI tab:** a browser.
- **CLI / API tab:** kbagent (/cli/getting-started/), connected to your project. The checks only read.


## Configuration
[Create a new configuration](https://help.keboola.com/components/configurations/#create-a-configuration) of the **Google Drive** connector.
Then click **Authorize Account** to [authorize the configuration](https://help.keboola.com/components/authorization/). 

Click **New Sheet** to configure extraction and **Select spreadsheet** to list accessible spreadsheets 
in your account:

![Screenshot - Empty configuration](https://help.keboola.com/components/extractors/storage/google-drive/google-drive-1.png)

You may be asked once again to log in. In that case, use the same account in which you authorized the first step of the setup.
Choose the document you want to import:

![Screenshot - Select document](https://help.keboola.com/components/extractors/storage/google-drive/google-drive-2.png)

The sheets of the selected document are shown; you can select which sheets you want to import:

![Screenshot - Select sheet](https://help.keboola.com/components/extractors/storage/google-drive/google-drive-3.png)

## Modify Configuration
When a sheet is added to the connector, it is displayed in the list of extracted sheets:

![Screenshot - Sheet list](https://help.keboola.com/components/extractors/storage/google-drive/google-drive-4.png)

Configured tables are stored as [configuration rows](https://help.keboola.com/components/#configuration-rows).
The list shows the name (and the link) of the imported document and sheet, and also the name of the destination
table in [Storage](https://help.keboola.com/storage/). You can modify the destination table name by editing the sheet extraction.

Click **Run Component**.

**Check:**

### Prompt

```text title="Prompt" wrap
Did the latest job of my Google Drive configuration succeed, and which tables did it load, with row counts?
```

Kai only reads here, so it asks for no approval, and its answer links to what it found in your project.

### UI

The job ends with status **Success** and Storage has one table per selected sheet, under the destination
table name shown in the list of extracted sheets.

### CLI / API

```bash
kbagent job list --component-id keboola.ex-google-drive --config-id 123456789 --limit 1
kbagent storage tables
```

Replace `123456789` with your configuration ID: `status` shows whether the job succeeded, and the tables it loaded have the latest `last_import_date`, with their rows in `rows_count`.

---
