Skip to content

Google Drive

Search, list and read every file as text, and create and copy files.

A Google Drive connection gives a playbook's functions the Google Drive API, from a document Auto ships. You sign in to Google and allow it, and the connection reads your Drive as you: every file's details, sharing and text, Docs, Sheets and Slides exported as text, PDFs and Word documents read page by page. It writes only the files it creates or copies itself, unless you later allow it to change the files you already have.

On Auto Cloud, available once Google's review of Auto completes; on a self-hosted runtime, with your own Google Cloud project, now.


What a playbook can do with Google Drive

  • Search and list files, and read a file's details and sharing.
  • Read a file's content as text: a Google Docs, Sheets or Slides file exported as text, and a text file, PDF or Word document of up to 20 MiB, a PDF of up to 500 pages, read page by page.
  • Create an empty file, and copy a file, which the connection may then change.
  • With a later consent that adds "edit": change and delete the files you already have.

A file it creates holds no content, since Drive takes a file's content at an upload address the connection has no path for; a copy of a template, filled through a Google Docs or Google Sheets connection, is the way to produce a document. It reads no text in an image, and no scanned PDF.

The tools, as the connection lists them

Tools that read: drive.files.list, drive.files.get, drive.permissions.list and drive.files.export.

Tools that act: drive.files.create and drive.files.copy.


An example workflow

Reviewing supplier contracts the way legal asks. An event trigger starts the workflow when your agent records a new contract's file id, or a schedule trigger lists the "Contracts, incoming" folder each morning. A lookup function reads the file's text, a PDF or a Word document, through drive.files.get. A reasoning function reads it with the team's checklist in its prompt: the clauses that must be present, the ones that must not, the dates and amounts to pull out, and writes a review in the team's template. A second lookup function reads the template's text; an interaction function copies the template with drive.files.copy into the "Reviews" folder, and a Google Docs connection fills it. An interaction function then asks the lawyer on duty, through a Slack connection, whether the review is right, and waits. Every contract's text and every review are in the run's history in Studio, where the legal team, and nobody else, has access to the playbook.


How to connect Google Drive

  • Sign in to Google and allow every Google Drive file to be read, and the files Auto creates to be changed. The consent screen shows the permissions listed below.

Then:

  1. Ask your agent to connect Google Drive to Auto, or open Settings, Agents, Connections in Auto Studio and choose Google Drive. On Auto Cloud, Studio lists Google Drive once Google's review of Auto completes.
  2. On the Studio page, check the service and its access, choose which playbooks may use the connection, and approve it.
  3. Have your agent check one small read through the connection before a function depends on it.

What it needs

  • A Google account, personal or Workspace, whose Drive the playbook reads. A Workspace administrator may restrict which apps can read Drive.
  • Your agent connected to Auto and signed in as you, with permission to change your organization, if your agent adds the connection.
  • On a self-hosted runtime, a Google Cloud project of your own with the Drive API enabled and an OAuth client registered for the runtime, as Let people add connections sets out; Google requires its own verification of a project that asks a restricted scope before people outside your organization can allow it.

Permissions Auto asks for

  • See and download every file of the person's Google Drive.
  • See, change, create and delete only the Google Drive files opened or created through this connection.

A later consent can add: Change and delete files you already have.

  • See, change, create and delete every file of the person's Google Drive.

Good to know

A file's text is read in a process of its own, within the call's 30 seconds and a bounded memory, and a file that would take more is left unread with a line that says so. The text is kept in the run's history, where people with access to the playbook can read it, unless the connection is added with content recording off. Auto's use of Drive data follows Google's Limited Use requirements, as the Privacy Policy states.


Follow our work on Auto.

Updates on business playbooks and how we use them.