sheets-cli
Google Sheets for humans & agents
A fast, deterministic CLI for reading and writing Google Sheets. Key-based updates instead of fragile row indices. Batch operations for atomic multi-step workflows. JSON everywhere.
Designed for both humans at the terminal and AI agents that need programmatic spreadsheet access.
COMMANDS
read tableExtract table as JSON with auto header detection
update keyModify cells by column value, not fragile row index
appendAdd rows with JSON values
batchExecute multiple operations atomically
update key?Traditional spreadsheet APIs update by row number. But row numbers change when data is sorted, filtered, or when rows are inserted.
FRAGILE
update --row 5 --set Status=DoneRow 5 today might be row 8 tomorrow.
STABLE
update key --key-col Name --key Acme --set Status=DoneFinds "Acme" wherever it is.
FEATURES
Update rows by matching a key column instead of fragile row indices. Data moves? Updates still work.
Execute multiple reads, writes, and updates in a single API request. Atomic and efficient.
All input and output uses structured JSON. Deterministic, parseable, AI-friendly.
Preview changes before applying them. See exactly what will happen without modifying data.
Install as a skill for Claude Code, OpenAI Codex, and VS Code. AI discovers it automatically.
Exit codes and error messages designed for automation. Validation, auth, permissions, API errors all distinct.
Install as a skill so your AI assistant can read, write, and update spreadsheets on your behalf.
Example prompts for your AI
"Read the Projects sheet and summarize active tasks"
"Update the status of Acme to Done in the tracker"
"Append today's metrics to the dashboard sheet"
QUICK START
- Built with
- Bun + TypeScript
- Output
- Structured JSON
- Auth
- OAuth 2.0 (Desktop app)
- Requirements
- Bun runtime
- License
- MIT (Open Source)
- ›CI/CD pipelines — Update deployment trackers
- ›Data ingestion — Batch append from scripts
- ›AI workflows — Let agents manage your sheets
- ›Manual ops — Quick terminal-based updates