Google Drive
Google Drive is a cloud storage service by Google that enables users to store, sync, share files, and collaborate online.
Categories: File Storage
Type: googleDrive/v1
Connections
Version: 1
OAuth2 Authorization Code
Properties
Name | Label | Type | Description | Required |
---|---|---|---|---|
clientId | Client Id | STRING | true | |
clientSecret | Client Secret | STRING | true |
Actions
Copy File
Name: copyFile
Copy a selected file to a different location within Google Drive.
Properties
Name | Label | Type | Description | Required |
---|---|---|---|---|
fileId | File ID | STRING | The id of the file to be copied. | true |
fileName | New File Name | STRING | The name of the new file created as a result of the copy operation. | true |
folderId | Destination Folder ID | STRING | The ID of the folder where the copied file will be stored. | true |
Example JSON Structure
{
"label" : "Copy File",
"name" : "copyFile",
"parameters" : {
"fileId" : "",
"fileName" : "",
"folderId" : ""
},
"type" : "googleDrive/v1/copyFile"
}
Output
Type: OBJECT
Properties
Name | Type | Description |
---|---|---|
id | STRING | The ID of the file. |
kind | STRING | Identifies what kind of resource this is. |
mimeType | STRING | The MIME type of the file. |
name | STRING | The name of the file. |
Output Example
{
"id" : "",
"kind" : "",
"mimeType" : "",
"name" : ""
}
Create New Folder
Name: createNewFolder
Creates a new empty folder in Google Drive.
Properties
Name | Label | Type | Description | Required |
---|---|---|---|---|
folderName | Folder Name | STRING | The name of the new folder. | true |
folderId | Parent Folder ID | STRING | ID of the folder where the new folder will be created; if no folder is selected, the folder will be created in the root folder. | false |
Example JSON Structure
{
"label" : "Create New Folder",
"name" : "createNewFolder",
"parameters" : {
"folderName" : "",
"folderId" : ""
},
"type" : "googleDrive/v1/createNewFolder"
}
Output
Sample Output:
{mimeType=plain/text, name=new-file.txt, id=1hPJ7kjhStTX90amAWSJ-V0K1-nhDlsIr}
Type: OBJECT
Properties
Name | Type | Description |
---|---|---|
id | STRING | The ID of the file. |
kind | STRING | Identifies what kind of resource this is. |
mimeType | STRING | The MIME type of the file. |
name | STRING | The name of the file. |
Output Example
{
"id" : "",
"kind" : "",
"mimeType" : "",
"name" : ""
}
Create New Text File
Name: createNewTextFile
Creates a new text file in Google Drive.
Properties
Name | Label | Type | Description | Required |
---|---|---|---|---|
fileName | File Name | STRING | The name of the new text file. | true |
text | Text | STRING | The text content to add to file. | true |
mimeType | File Type | STRING Optionsplain/text, text/csv, text/xml | Select file type. | true |
folderId | Parent Folder ID | STRING | ID of the folder where the file should be created; if no folder is selected, the file will be created in the root folder. | false |
Example JSON Structure
{
"label" : "Create New Text File",
"name" : "createNewTextFile",
"parameters" : {
"fileName" : "",
"text" : "",
"mimeType" : "",
"folderId" : ""
},
"type" : "googleDrive/v1/createNewTextFile"
}
Output
Sample Output:
{mimeType=plain/text, name=new-file.txt, id=1hPJ7kjhStTX90amAWSJ-V0K1-nhDlsIr}
Type: OBJECT
Properties
Name | Type | Description |
---|---|---|
id | STRING | The ID of the file. |
kind | STRING | Identifies what kind of resource this is. |
mimeType | STRING | The MIME type of the file. |
name | STRING | The name of the file. |
Output Example
{
"id" : "",
"kind" : "",
"mimeType" : "",
"name" : ""
}
Delete File
Name: deleteFile
Delete a selected file from Google Drive.
Properties
Name | Label | Type | Description | Required |
---|---|---|---|---|
fileId | File ID | STRING | The id of a file to delete. | true |
Example JSON Structure
{
"label" : "Delete File",
"name" : "deleteFile",
"parameters" : {
"fileId" : ""
},
"type" : "googleDrive/v1/deleteFile"
}
Output
This action does not produce any output.
Download File
Name: downloadFile
Download selected file from Google Drive.
Properties
Name | Label | Type | Description | Required |
---|---|---|---|---|
fileId | File ID | STRING | ID of the file to download. | true |
Example JSON Structure
{
"label" : "Download File",
"name" : "downloadFile",
"parameters" : {
"fileId" : ""
},
"type" : "googleDrive/v1/downloadFile"
}
Output
Type: FILE_ENTRY
Properties
Name | Type | Description |
---|---|---|
extension | STRING | |
mimeType | STRING | |
name | STRING | |
url | STRING |
Output Example
{
"extension" : "",
"mimeType" : "",
"name" : "",
"url" : ""
}
Get File
Name: getFile
Retrieve a specified file from your Google Drive.
Properties
Name | Label | Type | Description | Required |
---|---|---|---|---|
fileId | File ID | STRING | ID of the file to be retrieved. | true |
Example JSON Structure
{
"label" : "Get File",
"name" : "getFile",
"parameters" : {
"fileId" : ""
},
"type" : "googleDrive/v1/getFile"
}
Output
Type: OBJECT
Properties
Name | Type | Description |
---|---|---|
id | STRING | The ID of the file. |
kind | STRING | Identifies what kind of resource this is. |
mimeType | STRING | The MIME type of the file. |
name | STRING | The name of the file. |
Output Example
{
"id" : "",
"kind" : "",
"mimeType" : "",
"name" : ""
}
List Files
Name: listFiles
List files in a Google Drive folder.
Properties
Name | Label | Type | Description | Required |
---|---|---|---|---|
folderId | Parent Folder ID | STRING | ID of the folder from which you want to list files. If no folder is specified, the root folder will be used. | false |
Example JSON Structure
{
"label" : "List Files",
"name" : "listFiles",
"parameters" : {
"folderId" : ""
},
"type" : "googleDrive/v1/listFiles"
}
Output
Type: ARRAY
Items Type: OBJECT
Properties
Name | Type | Description |
---|---|---|
id | STRING | The ID of the file. |
kind | STRING | Identifies what kind of resource this is. |
mimeType | STRING | The MIME type of the file. |
name | STRING | The name of the file. |
Output Example
[ {
"id" : "",
"kind" : "",
"mimeType" : "",
"name" : ""
} ]
List Folders
Name: listFolders
List folders in a Google Drive folder.
Properties
Name | Label | Type | Description | Required |
---|---|---|---|---|
folderId | Parent Folder ID | STRING | ID of the Folder from which you want to list folders. If no folder is specified, the root folder will be used. | false |
Example JSON Structure
{
"label" : "List Folders",
"name" : "listFolders",
"parameters" : {
"folderId" : ""
},
"type" : "googleDrive/v1/listFolders"
}
Output
Type: ARRAY
Items Type: OBJECT
Properties
Name | Type | Description |
---|---|---|
id | STRING | The ID of the file. |
kind | STRING | Identifies what kind of resource this is. |
mimeType | STRING | The MIME type of the file. |
name | STRING | The name of the file. |
Output Example
[ {
"id" : "",
"kind" : "",
"mimeType" : "",
"name" : ""
} ]
Upload File
Name: uploadFile
Uploads a file in your Google Drive.
Properties
Name | Label | Type | Description | Required |
---|---|---|---|---|
fileEntry | File | FILE_ENTRY | The object property which contains a reference to the file to upload. | true |
folderId | Parent Folder ID | STRING | ID of the folder where the file will be uploaded; if no folder is selected, the file will be uploaded to the root folder. | false |
Example JSON Structure
{
"label" : "Upload File",
"name" : "uploadFile",
"parameters" : {
"fileEntry" : {
"extension" : "",
"mimeType" : "",
"name" : "",
"url" : ""
},
"folderId" : ""
},
"type" : "googleDrive/v1/uploadFile"
}
Output
Sample Output:
{mimeType=plain/text, name=new-file.txt, id=1hPJ7kjhStTX90amAWSJ-V0K1-nhDlsIr}
Type: OBJECT
Properties
Name | Type | Description |
---|---|---|
id | STRING | The ID of the file. |
kind | STRING | Identifies what kind of resource this is. |
mimeType | STRING | The MIME type of the file. |
name | STRING | The name of the file. |
Output Example
{
"id" : "",
"kind" : "",
"mimeType" : "",
"name" : ""
}
Triggers
New File
Name: newFile
Triggers when new file is uploaded to Google Drive.
Type: POLLING
Properties
Name | Label | Type | Description | Required |
---|---|---|---|---|
folderId | Parent Folder | STRING | true |
Output
Type: ARRAY
Items Type: OBJECT
Properties
Name | Type | Description |
---|---|---|
id | STRING | The ID of the file. |
kind | STRING | Identifies what kind of resource this is. |
mimeType | STRING | The MIME type of the file. |
name | STRING | The name of the file. |
JSON Example
{
"label" : "New File",
"name" : "newFile",
"parameters" : {
"folderId" : ""
},
"type" : "googleDrive/v1/newFile"
}
New Folder
Name: newFolder
Triggers when new folder is uploaded to Google Drive.
Type: POLLING
Properties
Name | Label | Type | Description | Required |
---|---|---|---|---|
folderId | Parent Folder | STRING | true |
Output
Type: ARRAY
Items Type: OBJECT
Properties
Name | Type | Description |
---|---|---|
id | STRING | The ID of the file. |
kind | STRING | Identifies what kind of resource this is. |
mimeType | STRING | The MIME type of the file. |
name | STRING | The name of the file. |
JSON Example
{
"label" : "New Folder",
"name" : "newFolder",
"parameters" : {
"folderId" : ""
},
"type" : "googleDrive/v1/newFolder"
}
What to do if your action is not listed here?
If this component doesn't have the action you need, you can use Custom Action to create your own. Custom Actions empower you to define HTTP requests tailored to your specific requirements, allowing for greater flexibility in integrating with external services or APIs.
To create a Custom Action, simply specify the desired HTTP method, path, and any necessary parameters. This way, you can extend the functionality of your component beyond the predefined actions, ensuring that you can meet all your integration needs effectively.
Additional instructions
Connection Setup
Turning on Drive API
Google Docs
Google Docs is a cloud-based collaborative word processing platform that allows multiple users to create, edit, and share documents in real-time.
Google Forms
Google Forms is a web-based application that allows users to create surveys, quizzes, and forms for data collection and analysis, with real-time collaboration and response tracking.