Overview
Tool Name
Purpose
The google_drive_tools integration connects your workflows to Google Drive and Google Workspace. Authenticate once, then create and edit Sheets and Docs, manage files and folders, export query results, collaborate with comments, and automate updates across projects.Key Features & Functions
Sheets Operations
Read and write cell ranges, append data, and keep analytics outputs live in Google Sheets.
Docs Operations
Create, read, update, and append content in Google Docs for living project documentation.
Files and Folders
List folders, get links, manage versions, and delete files when they are no longer needed.
Collaboration
Retrieve comments, add replies, and coordinate reviews without leaving your workflow.
Exports and Sync
Save query results directly to new Sheets and share links with stakeholders.
Service Accounts
Run unattended jobs with service account credentials for scheduled automations.
Input Parameters for Each Function
google_drive
Parameters
| Name | Definition | Format |
|---|---|---|
| action | Operation to perform. Allowed values include LOGIN, LIST, SET_ROOT_FOLDER, GET_ROOT_FOLDER, GET_FILE_VERSION_NUM, GET_COMMENTS, ADD_COMMENT, ADD_REPLY_TO_COMMENT, GET_SHEET, EDIT_SHEET, GET_LINK_FROM_FILE_ID, GET_FILE_BY_NAME, SAVE_QUERY_RESULTS_TO_G_SHEET, CREATE_SHEET, READ_DOC, CREATE_DOC, APPEND_DOC, UPDATE_DOC, DELETE_FILE, USE_SERVICE_ACCOUNT. | String |
| thread_id | Authentication context identifier. Used with LOGIN. | String |
| g_folder_id | Folder id for listing or setting root. Used with LIST, SET_ROOT_FOLDER. | String |
| g_file_name | Name filter or lookup. Used with LIST, GET_FILE_BY_NAME. | String |
| g_file_id | Target file id. Used with GET_FILE_VERSION_NUM, GET_COMMENTS, ADD_COMMENT, ADD_REPLY_TO_COMMENT, GET_SHEET, EDIT_SHEET, READ_DOC, APPEND_DOC, UPDATE_DOC, DELETE_FILE, GET_LINK_FROM_FILE_ID. | String |
| g_sheet_cell | A1 notation range. Used with GET_SHEET, EDIT_SHEET. | String |
| g_sheet_values | Values to write or comment text. Used with EDIT_SHEET, ADD_COMMENT, ADD_REPLY_TO_COMMENT. | String |
| g_doc_title | Document or sheet title for creation. Used with CREATE_DOC, CREATE_SHEET, SAVE_QUERY_RESULTS_TO_G_SHEET. | String |
| g_doc_content | Body content to write. Used with APPEND_DOC, UPDATE_DOC. | String |
| g_sheet_query | SQL to execute then export to a new Sheet. Used with SAVE_QUERY_RESULTS_TO_G_SHEET. | String |
Use
SAVE_QUERY_RESULTS_TO_G_SHEET to publish analytics in one step: run SQL, create a Sheet, and return a shareable link.Use Cases
- Stakeholder reporting
- Export daily or weekly query results to Sheets and hand off a live link.
- Living project docs
- Spin up a Doc per project, append meeting outcomes, and centralize decisions.
- Operational runbooks
- Keep checklists and status pages in Sheets, edited programmatically by jobs.
- Team reviews
- Fetch comment threads, add replies, and resolve items from a pipeline step.
- Discovery
- List folders, locate files by name, and share links in Slack or email.
D**eleting a file with **
DELETE_FILE**removes it from Drive. ** Confirm ownership, backups, and sharing expectations before proceeding.Workflow/How It Works
- Authenticate
- Choose
LOGINfor user auth orUSE_SERVICE_ACCOUNTfor unattended jobs.
- Choose
- Locate or create
- Use
LISTorGET_FILE_BY_NAMEto find targets, orCREATE_SHEETandCREATE_DOCto start fresh.
- Use
- Edit content
EDIT_SHEETto update ranges,APPEND_DOCorUPDATE_DOCto maintain Docs.
- Collaborate
- Pull threads with
GET_COMMENTS, add discussion viaADD_COMMENTandADD_REPLY_TO_COMMENT.
- Pull threads with
- Share
- Call
GET_LINK_FROM_FILE_IDand post the link through your notification channel.
- Call
For scheduled exports, prefer service accounts. They avoid interactive prompts and keep ownership consistent within a shared folder.
Integration Relevance
- data_connector_tools to run SQL that feeds
SAVE_QUERY_RESULTS_TO_G_SHEET. - project_manager_tools to attach Drive links to tasks and milestones.
- file_manager_tools to register copies of Drive exports when a repository of record is required.
- delegate_work to orchestrate spreadsheet updates as part of multi-agent routines.
- slack_tools to distribute Drive links and comment status to channels.
Configuration Details
- Complete OAuth 2.0 setup or provide a service account with access to target folders.
- Keep a designated shared folder for automation and set it with
SET_ROOT_FOLDER. - Use A1 notation for ranges, for example
A1,A1:B10,Sheet1!C2:D100. - Respect organization sharing policies when generating and distributing links.
- Record file ids where long-lived automations need deterministic targets.
Limitations or Notes
- API rate limits can throttle large batch operations. Use pagination and backoff.
- Very large Sheets may have write limits per call. Split updates into smaller ranges.
- Service account visibility depends on folder sharing. Share the folder with the service account email.
- Tokens expire. Renew user sessions or rotate service account keys as part of operations hygiene.
- Complex Docs formatting can vary when updated programmatically. Validate critical layouts.
- Concurrent edits may produce version conflicts. Serialize writes for hot files.
- Organization quotas can block new file creation. Monitor storage usage.
Output
- Authentication
- Login confirmation and token status.
- File and Folder Operations
- Listings with ids, names, mime types, and modified timestamps.
- Sheets
- Read results for requested ranges and write confirmations with affected ranges.
- Docs
- Document content snapshots, append confirmations, and update results.
- Comments
- Comment threads, new comment ids, and reply confirmations.
- Exports
- New Sheet id, title, and a shareable link after
SAVE_QUERY_RESULTS_TO_G_SHEET.
- New Sheet id, title, and a shareable link after
**Reminder: **Align permissions with your workspace policies. Use least privilege for service accounts and restrict automation to shared folders intended for data agents.

