#google sheets

43 messages · Page 1 of 1 (latest)

waxen arch
#

What's the best approach as of April 13, 2026 to let openclaw create, update and manage google sheets? I have a sales development scraper openclaw that I want to write the lists of prospects in a google sheet

rose gyroBOT
warm emberBOT
#

To help others find answers, you can mark your question as solved via Right click solution message -> Apps -> âś… Mark Solution

rose gyroBOT
viral smeltBOT
#

I'll check the local docs path and the relevant Google Sheets docs so I can give you a solid answer, not a guessed one.

#

Found the relevant bits. There isn’t a separate first-class Google Sheets tool in OpenClaw docs right now, the supported path is the gog skill/CLI.

#

Best current path is gog, not browser automation and not raw Google API calls from the model.

Recommended setup:

  1. Install gog on the same machine/container where OpenClaw actually runs.
  2. Auth it once for Sheets:
gog auth credentials ~/Downloads/client_secret.json
gog auth add you@gmail.com --services sheets
export GOG_ACCOUNT=you@gmail.com

If you already authorized before and are adding Sheets later, use --force-consent.

  1. Have your scraper produce JSON rows, then write with:
gog sheets append <sheetId> "Prospects!A:Z" --values-json '[[...],[...]]' --insert INSERT_ROWS
#
gog sheets update <sheetId> "Prospects!A2:Z2" --values-json '[[...]]'
gog sheets get <sheetId> "Prospects!A:Z" --json

My opinion: use Sheets as the review/output layer, but keep a stable key like email or LinkedIn URL and do a read-first, then append/update flow for dedupe. Much more reliable than blind appends.

If this is a company Workspace and needs to run fully headless, the cleaner production version is gog with a Workspace service account + domain-wide delegation. For personal/smaller setups, normal OAuth is simpler.

Docs:

If you want, I can sketch the exact OpenClaw workflow for “scrape prospects → dedupe → append/update sheet”.

waxen arch
#

Give me a step by step non-technical user guide on how to set this whole thing up. Thanks

viral smeltBOT
#

I’m going to sanity-check the current docs for the easiest install path, then I’ll write this as a plain-English setup guide.

#

Yep, here’s the simplest non-technical setup guide I’d recommend.

I’m assuming OpenClaw is already installed and running, and you want to connect it to one Google account and one Google Sheet.

Goal

You want this flow:

  1. your scraper finds prospects
  2. OpenClaw can read/write your Google Sheet
  3. new prospects get added, and existing ones can be updated

Step 1, create the Google Sheet first

Start simple. Do this manually in your browser.

  1. Open Google Sheets
#
  1. Create a new blank spreadsheet
  2. Name it something like Sales Prospects
  3. Rename the first tab to Prospects
  4. In row 1, add column names like:
  • Name
  • Company
  • Email
  • LinkedIn
  • Website
  • Notes
  • Status

This makes the automation much easier.

Copy the Sheet ID

In the sheet URL, copy the long ID in the middle.

#

Example:

https://docs.google.com/spreadsheets/d/THIS_PART_IS_THE_SHEET_ID/edit

Save that somewhere. You’ll need it later.


Step 2, make sure you know where OpenClaw is running

This matters a lot.

The Google connection must be set up on the same machine/server/container where OpenClaw runs.

  • If OpenClaw runs on your laptop, do it there
#
  • If OpenClaw runs on a VPS, do it on the VPS
  • If OpenClaw runs in Docker, gog must be installed inside Docker

If you are not sure, tell me how you installed OpenClaw and I’ll translate this part.


Step 3, create Google access for OpenClaw

You need to give OpenClaw a safe Google login path.

In Google Cloud Console:

  1. Go to Google Cloud Console
  2. Create a new project, any name is fine
  3. Enable these APIs:
    • Google Sheets API
#
  • Google Drive API
  1. Go to Credentials
  2. Create an OAuth Client ID
  3. Choose Desktop app
  4. Download the JSON credentials file

You’ll end up with a file that looks something like:

client_secret_....json

Keep that file.


Step 4, install the Google CLI that OpenClaw uses

#

Right now, the easiest OpenClaw path for Google Sheets is gog.

If you’re on a Mac, the easiest install is usually:

brew install gogcli

If you are using OpenClaw onboarding, the Skills step may also help install recommended dependencies.


Step 5, connect gog to your Google account

Run these on the machine where OpenClaw runs:

#
gog auth credentials /path/to/client_secret.json
gog auth add you@gmail.com --services sheets

Replace:

  • /path/to/client_secret.json with your downloaded file
  • you@gmail.com with your real Google email

This opens a Google login/consent screen in your browser. Approve it.

If you had already connected gog before and Sheets access was missing, run:

gog auth add you@gmail.com --services sheets --force-consent
#

Step 6, set your default Google account

This makes life easier:

export GOG_ACCOUNT=you@gmail.com

You can also add that to your shell profile later, but for now just running it is fine.

Optional check:

gog auth list
#

You should see your account there.


Step 7, make sure OpenClaw can see the skill

OpenClaw should pick up the gog skill automatically once the binary exists.

You can check with:

openclaw skills list --eligible

You want to see gog in the list.


#

Step 8, test one simple write first

Before wiring in the scraper, test with one fake row.

Example:

gog sheets append <SHEET_ID> "Prospects!A:G" --values-json '[["Test Person","Test Co","test@example.com","https://linkedin.com/in/test","example.com","test note","new"]]' --insert INSERT_ROWS

Replace <SHEET_ID> with the ID you copied earlier.

Then open the sheet in your browser and confirm the row appeared.

If that works, the hard part is done 🎉


#

Step 9, tell OpenClaw how to use the sheet

Now you can give OpenClaw instructions like:

Read my Google Sheet first, dedupe by email, then append any new prospects to the Prospects tab.

Or:

Update the row for this email if it already exists, otherwise append a new row.

My strong recommendation is:

  • use Email or LinkedIn URL as the unique identifier
  • always have OpenClaw read first, then write
  • avoid blind appends if you care about duplicates

#

Step 10, connect your scraper

The clean setup is:

  1. scraper finds prospects
  2. scraper outputs them in a consistent format
  3. OpenClaw uses gog sheets append or gog sheets update
  4. OpenClaw checks for duplicates before writing

If you want this to be mostly automatic, the next step is usually a small workflow or Lobster pipeline inside OpenClaw.


Simplest “good enough” setup

If you want the easiest version, do exactly this:

#
  • create the sheet manually
  • install gog
  • connect your Google account with OAuth
  • test one append
  • then have OpenClaw append/update that same sheet

That is the least painful route right now.

Important note

If OpenClaw runs on a remote server or in Docker, and you only install gog on your own laptop, it will not work. The Google auth and gog install have to live where OpenClaw actually runs.

Docs

waxen arch
#

I am using a vps, I have my openclaw there. How to setup?

viral smeltBOT
#

Got it. On a VPS, the easiest reliable setup is:

  • install gog on the VPS itself
  • do Google auth in manual mode
  • test one sheet write from the VPS
  • then let OpenClaw use that same setup

Here’s the VPS version, step by step.

1. Do everything on the VPS, not your laptop

SSH into the VPS as the same user that runs OpenClaw.

That matters because gog stores its auth for that user.


#

2. Install gog on the VPS

OpenClaw will use gog for Google Sheets access.

If your OpenClaw runs in Docker, important detail:
install gog in the image, not by hand in a running container, or it disappears on restart.

Docs for that: https://docs.openclaw.ai/install/docker-vm-runtime

If your OpenClaw runs directly on Linux, just install gog on that machine.


3. Create Google credentials

On your own computer browser, in Google Cloud Console:

#
  1. Create a project
  2. Enable:
    • Google Sheets API
    • Google Drive API
  3. Create an OAuth Client ID
  4. Choose Desktop app
  5. Download the JSON credentials file

Then copy that JSON file to the VPS.


4. Use file-based key storage on the VPS

Headless VPS setups usually do not have a desktop keychain, so this helps avoid weird auth prompts later.

In your VPS shell, set:

#
export GOG_KEYRING_BACKEND=file
export GOG_KEYRING_PASSWORD='choose-a-strong-password-here'

5. Add the Google credentials on the VPS

Run:

gog auth credentials /path/to/client_secret.json

Use the real path to the JSON file you copied to the VPS.

#

6. Authenticate your Google account in manual mode

Since the VPS usually has no browser, use:

gog auth add you@gmail.com --services sheets --manual

What happens next:

  1. gog prints a login URL
  2. copy that URL
  3. open it on your own laptop/browser
  4. sign into Google and approve access
  5. after approval, your browser lands on a redirect URL
#
  1. copy that full URL from the browser address bar
  2. paste it back into the VPS terminal when gog asks for it

That completes auth on the VPS.

If you had already authenticated before and need to add Sheets access now, use:

gog auth add you@gmail.com --services sheets --manual --force-consent

7. Set the default Google account

#
export GOG_ACCOUNT=you@gmail.com

Then verify auth:

gog auth list
gog auth status

8. Create your Google Sheet manually

In Google Sheets:

#
  1. create a sheet like Sales Prospects
  2. make a tab called Prospects
  3. add your header row:
    • Name
    • Company
    • Email
    • LinkedIn
    • Website
    • Notes
    • Status

Then copy the sheet ID from the URL.


9. Test one write from the VPS

#

Run one small test:

gog sheets append <SHEET_ID> "Prospects!A:G" --values-json '[["Test Person","Test Co","test@example.com","https://linkedin.com/in/test","example.com","test note","new"]]' --insert INSERT_ROWS

Then open the sheet in your browser and confirm the row showed up.

If this works, the Google side is done.


10. Make sure OpenClaw can see gog

Check:

#
openclaw skills list --eligible

You want to see gog.

If not, it usually means one of these:

  • gog is not installed where OpenClaw is actually running
  • OpenClaw is in Docker, but gog is only on the host
  • you authenticated as a different Linux user than the one running OpenClaw

11. Restart OpenClaw if needed

If gog was just installed, restart the gateway so new sessions pick it up cleanly.

#

After that, OpenClaw should be able to use the Google Sheets flow.


12. Best way to use it for your prospect scraper

My recommendation:

  • use Email as the unique key
  • have OpenClaw read the sheet first
  • skip duplicates
  • append only new rows
  • update existing rows by email if they already exist

That pattern is much safer than blind appends.


#

Very important VPS note

If OpenClaw runs as a service on the VPS, make sure these env vars are available to that service too:

  • GOG_KEYRING_BACKEND=file
  • GOG_KEYRING_PASSWORD=...
  • GOG_ACCOUNT=...

Otherwise it may work in your SSH shell, but fail when OpenClaw runs in the background.


If you’re using Docker

Then the flow is the same, but with 2 extra rules:

  1. bake gog into the Docker image
#
  1. keep the gog config/auth storage on persistent volume storage

The Docker doc is here: https://docs.openclaw.ai/install/docker-vm-runtime


If you want, send me which VPS setup you have:

  • bare Linux
  • Docker Compose
  • systemd service
  • something else

…and I’ll give you the exact next commands for that setup only.

waxen arch
#

How to check if I have docker or not

viral smeltBOT
#

Easiest check, SSH into the VPS and run:

docker --version

What it means:

  • if you see a version like Docker version 28.x..., Docker is installed
  • if you see command not found, Docker is not installed

To check if OpenClaw is actually running inside Docker, run:

docker ps
#

If you see a container for OpenClaw there, then yes, you’re using Docker.

If docker ps fails, or shows nothing relevant, OpenClaw may be running directly on Linux instead.

You can also check for a normal service with:

systemctl status openclaw

or:

ps aux | grep openclaw

If you want, paste the output of these 3 commands and I’ll tell you exactly which setup you have:

#
docker --version
docker ps
systemctl status openclaw
rotund umbra
#

for the sheets integration specifically -- the google sheets MCP server works but can be flaky with large datasets. we found that batching writes in chunks of 50 rows and adding a small delay between batches made it way more reliable.