Google Drive Download

Description

The Google Drive Download component allows you to download files from Google Drive. It can do the following:

Periodically retrieve and process files saved in a specific folder or with a specific file name in Google Drive with Gravio

  • Download sales data and processing logs such as CSV placed in specific folders with dated file names from Google Drive and process them with Gravio.
  • Folder names can also be multi-level folders.
  • Upload audio data saved by mobile devices to Google Drive, and Gravio periodically downloads the files and converts them to text using the OpenAIAudio component.
  • Similarly, image files can be retrieved and sent to the company.
googledrivedownload1
Output payloadDescription
cv.PayloadIf payload is specified in the output property, it is the downloaded file. If a file name is specified, the output payload of the previous component is output as is. (Pass-through)

Component Properties

Property NameDescription
Outputpayload or filename
Output folder pathIf "input property" is a file name, the folder path to save it
Output file nameIf "input property" is a file name, the file name to save
How to specifySearch by file name, file path and file name, folder ID and file name, or file ID
Download only the most recent oneIf multiple files are saved with the same file name and multiple dates, download only one new file or all of them
Target of retrievalIf a file ID other than the file ID is specified in the "Specify method property", specify the Drive file name with a full match or partial match
Folder IDWhen folder ID is specified in "Specify method property", it specifies the folder ID to be downloaded.
Drive folder pathWhen folder path is specified in "Specify method property", it specifies the Drive folder path for downloading.
Drive file nameIf a file name is specified in "Specify method property", the name of the Drive file to be downloaded.
File IDIf a file ID is specified in the "Specify method property," the file ID to be downloaded
Get files modified after this timeSpecify the modification date and time of the file to be downloaded
TimeoutHTTP request response timeout value
OAuth2 Client IDSpecify the Client ID for API 2.0 from GCP ※1
OAuth2 Client SecretSpecify Client Secret from GCP ※1
OAuth2 Redirect URLSpecify Redirect URL from GCP ※1
OAuth2 Access TokenPress the Get Token button to retrieve the token. You can also update the token by pressing the Update Token button ※1 ※2

※1 See Google Drive OAuth2 Setup for an example of OAuth2 configuration in GCP.

Component Variables

Component VariablesDescription
cv.FileIDFile ID
cv.ReadLengthBytes of data to be read
cv.FilenameIf the "Output" property is a file name, the name of the downloaded file

How to obtain OAuth2 access token

※2 Press the Get OAuth2 access token button to display the Get OAuth 2.0 access token panel. Press the Open Browser button to obtain the token. Once the token is obtained, press the Set button to automatically set it to the OAuth2 access token property.

oauth2-4en

In Gravio Studio for Windows, press the Open Browser button in the same way to obtain the token, but an error screen will appear. In this state, copy the URL from the address bar and press the Get button with that URL as the pace in the panel. Press the Set button to automatically set the token to the OAuth2 access token property.

oauth-gswin-1en

Pressing the Open Browser button will automatically authenticate the user in the browser. If necessary, please follow the on-screen instructions for the login process, etc.

oauth-gswin-2en

When the authentication is completed, an error message "This page is unreachable" will be displayed.

oauth-gswin-4en

Paste the copied URL into the panel and press the Get button, and the OAuth2 access token will be "obtained". Press the Set button to close the panel.