tanaike

The Thinker

Resumable Download of File from Google Drive using Drive API with Python

Gists This is a sample script for achieving the resumable download of a file from Google Drive using Dive API with Python. There might be a case in that you want to achieve the resumable download of a file from Google Drive using Dive API with Python. For example, when a large file is downloaded, the downloading might be stopped in the middle of downloading. At that time, you might want to resume the download.

Retrieving Total File Sizes in Specific Folder of Google Drive using Google Apps Script

Gists This is a sample script for retrieving the total file sizes in the specific folder of Google Drive using Google Apps Script. There is a case where you want to retrieve the total file sizes in the specific folder of Google Drive using Google Apps Script. In this post, I would like to introduce a sample script for achieving this. Sample script Before you use this script, please enable Drive API at Advanced Google services.

Retrieving Start and End Row Numbers of Same Values in a Column on Google Spreadsheet using Google Apps Script

Gists This is a sample script for retrieving the start and end row numbers of the same values in a column on Google Spreadsheet using Google Apps Script. There is a case in that I want to retrieve the rows of the same values in a column on Google Spreadsheet using Google Apps Script. In this post, I would like to introduce a simple sample script for achieving this. Sample script function myFunction() { const sheet = SpreadsheetApp.

Using Until Expiration Time of Access Token Retrieved By googleapis for Python

Gists When Google APIs are used with googleapis for Python, the client is obtained as follows. creds = service_account.Credentials.from_service_account_file(service_account_credential_file, scopes=scopes) service = build("drive", "v3", credentials=creds) In this case, when the script is run, the access token is retrieved every time. But, the expiration time of the retrieved access token is 1 hour. Here, there might be the case that you want to use the access token until the expiration time. It is considered that effectively using the access token will lead to SDGs.

Issue of HTML form with Input tab of Type File with google.script.run

Gists Today, I discussed with Riƫl Notermans an issue with the HTML form with the input tab of type="file" with google.script.run. Through this discussion, the reason for this issue could be found. When you use the input tab of type="file" in the HTML form, and you want to send the file content with google.script.run, I thought that this post might be useful for other users. So, I posted it here.