Connect Google Drive to your Wiro AI agent
Find, read and upload files in shared Google Drive folders.
Check the Expenses tab of the Saltgrass Yoga Q3 budget and list the lines over plan, with how far over each one is.
Four lines are over plan, $2,140 in all:
- Instructor fees: $14,900 against $13,800, $1,100 over
- Cleaning and supplies: $1,450 against $1,000, $450 over
- Marketing: $1,860 against $1,500, $360 over
- Utilities: $1,230 against $1,000, $230 over
Rent, software and insurance match the plan, and retail stock came in $320 under.
Google Drive actions
Your agent picks the right ones for each request
Overview
What Google Drive does for your agent
Reaches your Drive through a service account from your own Google Cloud project, so the agent sees only the folders shared with that account's email and picked when you connect. Inside them it searches files, reads Docs, Sheets and Slides, writes rows and cells, creates Docs and Sheets, uploads files from public links, and renames, moves, trashes or shares files. A service account has no Drive storage of its own, so new files and uploads belong in a shared drive, not a personal My Drive.
Use cases
What your Wiro agent can do with Google Drive
- 01
Log every new lead from Chat into a Google Sheet
When a visitor leaves their name, email and what they need in Chat, the agent appends a row to your leads sheet with the date and a one-line summary. Set Append rows to a Google Sheet to Allow for Chat on the Connectors tab, so each lead is logged without waiting for an approval.
- 02
Answer team questions from your own Google Docs
Ask what the refund policy says about digital goods, or which supplier terms changed this year. The agent searches the shared folders by file name and text, reads the matching Docs, Sheets or Slides, and answers with the file name and link so you can check the source.
- 03
A weekly report saved as a Google Doc in the team folder
To automate Google Drive reporting, a Scheduled Task reads your leads or orders sheet every Monday, writes the week's summary as a Google Doc with headings, lists and tables, saves it in a folder of your shared drive, shares it with your team's group and posts the link in Chat.
- 04
Find files that anyone with the link can open
Once a month a Scheduled Task lists the files in your chosen folders that are open to anyone with the link, with their owner and last change, and posts them in Chat. Tell the agent which links to close and it removes them, after your approval in Chat.
- 05
Check a budget sheet against plan
Ask the agent to read the Expenses tab of your budget sheet and list the lines that are over plan and by how much. It reads any tab and cell range, compares the plan columns with the actual ones, and answers with a short table.
- 06
Collect campaign assets in one folder for an agency
Give the agent public links to this month's banners and videos, up to 50 MB each. It uploads them into the campaign folder of your shared drive, turns the brief into a Google Doc, and shares the folder with the agency's address as a commenter, each step after your approval in Chat.
How it works
How Google Drive works with Wiro
- 01
Connect Google Drive
Deploy an agent, open its Connectors tab, choose Google Drive and paste what the Connect dialog asks for.
- 02
Choose what each action may do
Set each Google Drive action to Allow, Ask or Block, in Chat and in Scheduled Tasks. By default, read-only actions run, and the rest ask first in Chat.
- 03
Ask in Chat or schedule it
Ask your agent for Google Drive work in Chat, or put it on a Scheduled Task that runs on its own.
- Where it runsInside your agent. Its requests go straight from the agent to Google Drive.
- Where its data goes
www.googleapis.comsheets.googleapis.comdocs.googleapis.comand 1 more - How it signs inPaste a key. It is stored encrypted and never shown again.
- AccountsAfter connecting, pick the Google Drive folders the agent may work with. It cannot reach any other.
What it can do
Actions your Wiro agent can take in Google Drive
By default, read-only actions run, and the rest ask first in Chat and run in Scheduled Tasks. Each agent can set any action to Allow, Ask or Block.
Read-only 9 actions
Looks things up in Google Drive and changes nothing.
| Action | What it does | Chat | Scheduled Tasks |
|---|---|---|---|
| List Google Drive folders | Lists folders. | Allow | Allow |
| List Google Drive files | Lists the files in a folder, newest change first (full-text matches by relevance): id, name, kind, type, size, times and link. | Allow | Allow |
| Get a Google Drive file | Returns a file's details: name, kind, type, size, folder, owner, times, description, links, the formats a Google Doc, Sheet or Slides file exports to, and who it is shared with. | Allow | Allow |
| Read a Google Drive file as text | Returns the text of a file, in pages of about 25 KB: a Google Doc as Markdown (or plain text or HTML), a Google Sheet's first sheet as CSV, a Slides file as plain text, and text files as they are, up to 4 MB. | Allow | Allow |
| Download a Google Drive file | Hands a stored file (an image, a video, a PDF, an Office file or any other upload) to the host as a file, with its details, for the host to save or pass on. | Allow | Allow |
| Export a Google Doc, Sheet, Slides file or Drawing | Exports a Google Doc, Sheet, Slides file or Drawing and hands the copy to the host as a file: a Doc as pdf, docx or txt; a Sheet as pdf, xlsx or csv; a Slides file as pdf, pptx, txt or png; a Drawing as pdf or png. | Allow | Allow |
| Get a Google Sheet's sheets | Returns a Google Sheet's title, locale, time zone, link and its sheets (tabs) with their ids, names and sizes. | Allow | Allow |
| Read a Google Sheet range | Reads the cells of a range, row by row (trailing empty cells left out): as shown, as raw values, or with formulas. | Allow | Allow |
| Read other Google Drive data | Reads what the actions above do not cover, straight from the Google Drive API. | Allow | Allow |
Create and send 6 actions
Creates or sends something new in Google Drive, such as a post, a message or an email.
| Action | What it does | Chat | Scheduled Tasks |
|---|---|---|---|
| Upload a file to Google Drive | Uploads a file into a folder: from a public https URL (images, videos, PDFs and any other file, up to 50 MB) or from text given here (CSV, Markdown, JSON, HTML or plain text). | Ask | Allow |
| Create a Google Doc | Creates a Google Doc in a folder, empty or with text: Markdown, plain text or HTML. | Ask | Allow |
| Create a Google Sheet | Creates a Google Sheet in a folder, empty or filled with rows (or CSV text). | Ask | Allow |
| Share a Google Drive file | Gives a person, a group, a whole domain or anyone with the link access to a file or folder, as reader, commenter or writer (Editor; Content manager in a shared drive). | Ask | Allow |
| Append rows to a Google Sheet | Adds rows after the last row of the table in a range. | Ask | Allow |
| Add text to a Google Doc | Inserts plain text at the end or the start of a Google Doc. | Ask | Allow |
Change and delete 6 actions
Changes or deletes what is already in Google Drive.
| Action | What it does | Chat | Scheduled Tasks |
|---|---|---|---|
| Rename, move or trash a Google Drive file | Changes a file's name, description or star, moves it to another folder, or moves it to the trash and back. | Ask | Allow |
| Replace a Google Drive file's content | Replaces the content of an existing file and keeps its id, name and links: from a public https URL (up to 50 MB) or from text given here. | Ask | Allow |
| Remove a sharing from a Google Drive file | Removes one sharing from a file or folder by its permission id. | Ask | Allow |
| Write cells in a Google Sheet | Overwrites the cells of a range with rows, starting at its top-left cell. | Ask | Allow |
| Clear cells in a Google Sheet | Clears the values of a range (formatting stays). | Ask | Allow |
| Make other Google Drive changes | Sends any other change straight to the Google Drive API. | Ask | Allow |
How to connect
Connect Google Drive to Wiro
Open the agent's Connectors tab, choose Google Drive and paste what it asks for. Values are stored encrypted and never shown again.
What the Connect dialog asks for
| Field | About |
|---|---|
| Service Account JSONRequired |
|
Troubleshooting
Troubleshooting Google Drive
What to check when Google Drive stops working for your agent.
- An invalid or expired key If Google Drive refuses the key, for example after it was deleted or expired, the agent's Google Drive actions fail. Create a new key in Google Drive, then open the agent's Connectors tab, choose Google Drive and paste it in place of the old one.
- Limits set by Google Drive Google Drive limits how much an account can do, such as how many requests it takes in a minute. An action over a limit fails until the limit resets: wait and ask again, or check your Google Drive plan.
For developers
Connect Google Drive from your own product
Every call is a POST to the Wiro API with your project's API key. On a sign-in, your customers see your own app's name.
- 01
Read the connector
Detail answers without a session: what the connector needs and the tools it gives an agent.
POST /AgentConnector/Detail { "slug": "google-drive" }Response { "result": true, "errors": [], "agentconnectors": [ { "slug": "google-drive", "title": "Google Drive", "category": "productivity", "authtype": "fields", "credentialfields": [ { "name": "serviceaccountjson", "label": "Service Account JSON", "required": true, "secret": true, "format": "json" } ], "accountpickers": [ { "key": "folders", "label": "Google Drive folders", "multiple": true } ], "tools": [ { "name": "list_folders", "readonly": true }, { "name": "list_files", "readonly": true } ] } ] } - 02
Connect with the values
Send what the person typed in your form. A value you leave out keeps what the connection holds; an empty one clears it.
POST /UserAgent/ConnectorConnect { "useragentguid": "YOUR_AGENT_GUID", "slug": "google-drive", "values": { "serviceaccountjson": "{ ...the whole JSON file... }" } }Response { "result": true, "errors": [], "status": "connected", "applied": 1, "restart": "scheduled" } - 03
Read the status
connected, pending (a sign-in not finished), reauth (sign in again) or error. Values and tokens never come back.
POST /UserAgent/ConnectorList { "useragentguid": "YOUR_AGENT_GUID" }Response { "result": true, "errors": [], "useragentconnectors": [ { "slug": "google-drive", "title": "Google Drive", "authtype": "fields", "status": "connected", "accounts": {}, "savedvariables": [ "serviceaccountjson" ], "lasterror": null } ] } - 04
List the accounts
After connecting, list what the agent may use. It cannot reach anything else.
POST /UserAgent/ConnectorAccounts { "useragentguid": "YOUR_AGENT_GUID", "slug": "google-drive" }Response { "result": true, "errors": [], "pickers": [ { "key": "folders", "label": "Google Drive folders", "multiple": true, "candidates": [ { "id": "1234567890", "name": "Example account" } ], "selected": [] } ] } - 05
Save the accounts
Every id is checked against a fresh list, then the agent uses them, with no restart for most changes.
POST /UserAgent/ConnectorSetAccounts { "useragentguid": "YOUR_AGENT_GUID", "slug": "google-drive", "accounts": { "folders": [ "1234567890" ] } }Response { "result": true, "errors": [], "restart": "scheduled" } - 06
Disconnect
Revokes a sign-in where the vendor allows it, deletes what the connection holds and removes the connector from the running agent.
POST /UserAgent/ConnectorDisconnect { "useragentguid": "YOUR_AGENT_GUID", "slug": "google-drive" }Response { "result": true, "errors": [], "removed": true, "revoked": false, "restart": "scheduled" }
Questions
Google Drive and Wiro FAQ
What can a Google Drive AI agent do with my files?
Inside the folders you pick, it finds files by name, text, type or change date and reads Google Docs, Sheets and Slides and plain text files; for images, videos and PDFs it gives their details and links. It can create Docs and Sheets, upload files from a public link, add rows or write cells in a sheet, add text to a Doc, rename, move or trash files, and share or unshare them.
How do I connect Google Drive to an AI agent?
It connects with a service account from your own Google Cloud project, not a Google sign-in. Create the service account, add a JSON key and upload that file when you choose Google Drive on the agent's Connectors tab, or ask the agent in Chat to add Google Drive. Enable the Google Drive API for the project, share each folder with the service account's email as Editor (Content manager in a shared drive), then pick the folders the agent may use.
Which Google Drive folders can the agent see?
Only what you share with the service account. After connecting, you pick which of those folders the agent may work with, subfolders included, and it cannot reach any other part of your Drive. To take a folder back, remove the service account from that folder's sharing, or from the shared drive's members.
What do I need to set up in Google Cloud for Google Drive?
A Google Cloud project with the Google Drive API turned on, plus the Google Sheets API and the Google Docs API if the agent should read or write sheet cells or add text to Docs. For uploads and new files, use a folder in a shared drive: a service account has no Drive storage of its own, so Google can refuse files it would own in a personal My Drive folder.
Does the agent need approval to change files in Google Drive?
Reading runs without asking. Uploading, creating Docs and Sheets, writing or clearing cells, renaming, moving or trashing files, and sharing them ask for your approval in Chat by default; in Scheduled Tasks they run unless you set them to Ask or Block. Each Google Drive action has two settings, one for Chat and one for Scheduled Tasks, and each can be Allow, Ask or Block.
Where is the service account JSON for Google Drive kept?
The JSON key is encrypted when you upload it, and the AI model never sees its contents. To revoke it, open IAM & Admin, then Service accounts in Google Cloud console, and delete the key under Keys, or disable the service account. Then disconnect Google Drive on the agent's Connectors tab.
What does the Google Drive MCP connector cost?
Nothing extra on any agent plan, and it runs inside your agent, with requests going straight to Google. The agent's calls count against your Google Cloud project's own API quotas, and files it adds take up space in the shared drive they go into. Each upload from a link can be up to 50 MB, and an export of a Google file up to 10 MB.
Access
Revoke Google Drive access
In Google Cloud console, open IAM & Admin → Service accounts, open the service account and delete the key under Keys (or disable or delete the service account). To take back one folder, remove the service account from the folder's sharing or from the shared drive's members. Then disconnect it here.
Related connectors
More productivity connectors for your Wiro agent
Put Google Drive to work with Wiro
Deploy an agent and connect Google Drive from its Connectors tab. Every agent plan includes it: Starter $5, Pro $30 and Max $100 a month.