[Apps Script - Google Drive v2] The driveId parameter must be specified if and only if corpora is set to drive
@vinay-google がすでに取り組んでいます。
2022年7月5日 から。
評価
この issue はまだ評価されていません。
説明
Summary
Getting an error when executing Google Drive (v2) Files.list even if corpora is set to 'drive' and driveId is supplied.
Expected Behavior
Google Drive API v2 Files.list method via Apps Script successfully retrieves files/folders under a Shared Drive when using corpora="drive" and supplying the driveId.
Sample URL:
Description:
Actual Behavior
Google Drive API v2 Files.list method via Apps Script fails with the following error:
Error in Apps Script logs:
Failed with error API call to drive.files.list failed with error: The driveId parameter must be specified if and only if corpora is set to drive.
Steps to Reproduce the Problem
- Create an Apps Script Project (setup OAuth)
- Add Google Drive (v2) library (v3 is not available)
- Copy and execute this function:
function getRetentionFolders() {
const queryFolder = "trashed=false and mimeType='application/vnd.google-apps.folder'";
var results = Drive.Files.list({
corpora: "drive",
id: <driveId of shared drive>,
q: queryFolder,
includeItemsFromAllDrives: true,
supportsAllDrives: true,
fields: 'items(kind,id,title,mimeType,createdDate,modifiedDate,parents,driveId)'
});
}
- 主要言語
- JavaScript
- スター
- 5.2k
- フォーク
- 2k
- PR マージ指標
- 30日以内にマージされた PR はありません
コントリビューションガイド
はじめの一歩
- issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
- 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
- リポジトリをフォークし、ブランチを切って変更します。
- issue 番号を参照したプルリクエストを送ります。
googleworkspace/apps-script-samples のほかの issue
-
Alvin Litana Mirasol オープン
難易度 5/5 1週間以上 初心者へのやさしさ 1/100
googleworkspace/apps-script-samples#659 · コメント 1 件 · リアクション 1 件 ·
-
Password reset オープン
難易度 5/5 1週間以上 初心者へのやさしさ 15/100
googleworkspace/apps-script-samples#654 · リアクション 2 件 ·
-
cod gs オープン
難易度 5/5 1週間以上 初心者へのやさしさ 10/100
googleworkspace/apps-script-samples#651 · リアクション 1 件 ·
-
tespogrome オープン
難易度 5/5 1週間以上 初心者へのやさしさ 1/100
googleworkspace/apps-script-samples#624 · リアクション 1 件 ·
-
googleworkspace/apps-script-samples#616 · 担当者 1 名 ·
googleworkspace/apps-script-samples の issue をすべて見る
似ている issue
-
Bug
難易度 2/5 1〜3時間 初心者へのやさしさ 70/100
Automattic/safe-publish#594 ·
-
難易度 2/5 1〜3時間 初心者へのやさしさ 75/100
dream-num/dsh-univer-office#104 ·
-
comp/dashboard invalid P3
難易度 2/5 1〜3時間 初心者へのやさしさ 70/100
NousResearch/hermes-agent#121143 ·
-
難易度 2/5 1〜3時間 初心者へのやさしさ 75/100
avniproject/avni-webapp#1811 ·
-
area/auroraboot area/webui bug
難易度 2/5 1〜3時間 初心者へのやさしさ 75/100