אם תספקו את הפרמטר alt=media של כתובת האתר, התגובה תכלול את תוכן הקובץ בגוף התגובה. הורדת תוכן באמצעות alt=media תתבצע רק אם הקובץ מאוחסן ב-Drive. כדי להוריד את Google Docs, Sheets ו-Slides, צריך להשתמש ב-files.export במקום זאת. לקבלת מידע נוסף, ראה הורדה ו ייצוא קבצים.
בקשת HTTP
GET https://www.googleapis.com/drive/v3/files/{fileId}
האם המשתמש מודע לסיכון של הורדת תוכנות זדוניות ידועות או קבצים פוגעניים אחרים. האפשרות הזו רלוונטית רק כאשר הפרמטר alt מוגדר לערך media והמשתמש הוא הבעלים של הקובץ או מארגן של האחסון השיתופי שבו הקובץ נמצא.
supportsAllDrives
boolean
האם האפליקציה ששלחה את הבקשה תומכת גם בתיקייה 'האחסון שלי' וגם בתיקיות אחסון שיתופי.
supportsTeamDrives (deprecated)
boolean
הוצא משימוש: במקומו צריך להשתמש ברכיב supportsAllDrives.
includePermissionsForView
string
מציינת אילו הרשאות תצוגה נוספות לכלול בתשובה. רק 'פורסם' נתמך.
includeLabels
string
רשימה מופרדת בפסיקים של מזהים של תוויות שיש לכלול בחלק labelInfo של התשובה.
גוף הבקשה
גוף הבקשה חייב להיות ריק.
גוף התשובה
אם הפעולה בוצעה ללא שגיאות, גוף התגובה יכלול מופע של File.
[[["התוכן קל להבנה","easyToUnderstand","thumb-up"],["התוכן עזר לי לפתור בעיה","solvedMyProblem","thumb-up"],["סיבה אחרת","otherUp","thumb-up"]],[["חסרים לי מידע או פרטים","missingTheInformationINeed","thumb-down"],["התוכן מורכב מדי או עם יותר מדי שלבים","tooComplicatedTooManySteps","thumb-down"],["התוכן לא עדכני","outOfDate","thumb-down"],["בעיה בתרגום","translationIssue","thumb-down"],["בעיה בדוגמאות/בקוד","samplesCodeIssue","thumb-down"],["סיבה אחרת","otherDown","thumb-down"]],["עדכון אחרון: 2024-09-04 (שעון UTC)."],[[["Retrieves a file's metadata or content using its ID, with the option to download the content using `alt=media` if stored in Google Drive."],["Accepts various query parameters such as `acknowledgeAbuse`, `supportsAllDrives`, and `includePermissionsForView` to customize the response."],["Requires authorization with one of the specified OAuth scopes, such as `https://www.googleapis.com/auth/drive` or `https://www.googleapis.com/auth/drive.readonly`."],["Returns a [File](/drive/api/reference/rest/v3/files#File) object in the response body upon successful execution."],["Uses `GET` request with the endpoint `https://www.googleapis.com/drive/v3/files/{fileId}`, where `{fileId}` is replaced with the actual file ID."]]],["This describes retrieving file metadata or content from Google Drive using a `GET` request to `https://www.googleapis.com/drive/v3/files/{fileId}`. The `fileId` is required as a path parameter. Content can be downloaded by setting `alt=media` as a query parameter. Additional query parameters like `acknowledgeAbuse`, `supportsAllDrives`, and `includeLabels` allow for more specific requests. The request body must be empty. The response body, if successful, is a `File` instance. Several authorization scopes are required.\n"]]