Googledrive

Learn how to use Googledrive with Composio

Overview

Enum

GOOGLEDRIVE

Description

Connect to Google Drive!

Authentication Details

client_id
stringRequired
client_secret
stringRequired
oauth_redirect_uri
stringDefaults to https://backend.composio.dev/api/v1/auth-apps/add
scopes
stringDefaults to https://www.googleapis.com/auth/drive,https://www.googleapis.com/auth/userinfo.email
token
stringRequired

Actions

Modifies sharing permissions for an existing google drive file, granting a specified role to a user, group, domain, or 'anyone'.

Action Parameters

domain
string
email_address
string
file_id
stringRequired
role
stringRequired
type
stringRequired

Action Response

data
object
error
successful
boolean
Duplicates an existing file in google drive, identified by its `file id`.

Action Parameters

file_id
stringRequired
new_title
string

Action Response

data
object
error
successful
boolean
Creates a new file in google drive from provided text content (up to 10mb), supporting various formats including automatic conversion to google workspace types.

Action Parameters

file_name
stringRequired
mime_type
stringDefaults to text/plain
parent_id
string
text_content
stringRequired

Action Response

data
object
error
successful
boolean
Creates a new folder in google drive, optionally within a parent folder specified by its id or name; if a parent name is provided but not found, the action will fail.

Action Parameters

folder_name
stringRequired
parent_id
string

Action Response

data
object
error
successful
boolean
Permanently deletes a google drive file or folder by its id, bypassing the trash; the item cannot be recovered.

Action Parameters

file_id
stringRequired

Action Response

data
object
error
successful
boolean
Downloads a file from google drive by its id, optionally exporting google workspace documents (docs, sheets, slides) to a specified `mime type`; for other file types, `mime type` must be omitted.

Action Parameters

file_id
stringRequired
mime_type
string

Action Response

data
object
error
successful
boolean
Updates an existing google drive file by overwriting its entire content with new text (max 10mb).

Action Parameters

content
stringRequired
file_id
stringRequired
mime_type
stringDefaults to text/plain

Action Response

data
object
error
successful
boolean
Searches for files and folders in google drive using various criteria; `modified after` timestamp must be in utc rfc3339 format.

Action Parameters

folder_id
string
full_text_contains
string
full_text_not_contains
string
include_items_from_all_drives
booleanDefaults to True
mime_type
string
modified_after
string
name_contains
string
name_exact
string
name_not_contains
string
page_size
integerDefaults to 5
page_token
string
starred
boolean
supports_all_drives
booleanDefaults to True

Action Response

data
object
error
successful
boolean
Finds folders in google drive by applying all specified search criteria using 'and' logic.

Action Parameters

full_text_contains
string
full_text_not_contains
string
modified_after
string
name_contains
string
name_exact
string
name_not_contains
string
starred
boolean

Action Response

data
object
error
successful
boolean
Deprecated: exports google workspace files (max 10mb) to a specified format using `mime type`, or downloads other file types; use `googledrive download file` instead.

Action Parameters

file_id
stringRequired
mime_type
string

Action Response

data
object
error
successful
boolean
Uploads a file (max 5mb) to google drive, moving it to a specified folder if a valid folder id is provided, otherwise uploads to root.

Action Parameters

file_to_upload
objectRequired
folder_to_upload_to
string

Action Response

data
object
error
successful
boolean