קל לארגן דפים בעזרת אוספים אפשר לשמור ולסווג תוכן על סמך ההעדפות שלך.
המסמך הזה מכיל מידע ספציפי לגבי הרשאות ואימות של Google Docs API. לפני קריאת המסמך הזה, חשוב לקרוא את המידע הכללי על אימות והרשאה ב-Google Workspace במאמר מידע על אימות והרשאה.
כדי להגדיר את רמת הגישה שמוענקת לאפליקציה, צריך לזהות ולדווח על היקפי הרשאה. היקף הרשאה הוא מחרוזת URI של OAuth 2.0 שמכילה את שם האפליקציה ב-Google Workspace, את סוג הנתונים שהיא ניגשת אליהם ואת רמת הגישה. היקפים הם הבקשות של האפליקציה לעבוד עם נתוני Google Workspace, כולל נתונים מחשבון Google של המשתמשים.
כשהאפליקציה מותקנת, המשתמש מתבקש לאמת את ההיקפים שבהם האפליקציה משתמשת. באופן כללי, כדאי לבחור את ההיקף המצומצם ביותר האפשרי ולהימנע מבקשות להיקפים שלא נדרשים לאפליקציה. משתמשים נותנים גישה בקלות רבה יותר להיקפים מוגבלים ומתוארים בבירור.
כשהדבר אפשרי, מומלץ להשתמש בהיקפי גישה לא רגישים, כי הם מעניקים היקף גישה לכל קובץ ומצמצמים את הגישה לתכונות ספציפיות שנחוצות לאפליקציה.
Docs API תומך בהיקפים הבאים:
קוד ההיקף
תיאור
שימוש
https://www.googleapis.com/auth/documents
הצגה, עריכה, יצירה ומחיקה של כל המסמכים שלכם ב-Google Docs.
הצגה, עריכה, יצירה ומחיקה רק של הקבצים הספציפיים ב-Google Drive שבהם נעשה שימוש באפליקציה הזו.
מומלץ לא רגיש
https://www.googleapis.com/auth/drive
הצגה, עריכה, יצירה ומחיקה של כל הקבצים שלכם ב-Google Drive.
מוצר שהצפייה בו הוגבלה
https://www.googleapis.com/auth/drive.readonly
הצגה והורדה של כל הקבצים שלכם ב-Google Drive.
מוצר שהצפייה בו הוגבלה
בעמודה Usage בטבלה מצוין רמת הרגישות של כל היקף, בהתאם להגדרות הבאות:
לא רגיש: היקפי הגישה האלה מספקים את היקף הרשאת הגישה הקטן ביותר, ונדרש רק אימות בסיסי של האפליקציה. מידע נוסף על הדרישה הזו זמין במאמר שליחת האפליקציה לאימות.
רגישים: ההיקפים האלה מספקים גישה לנתוני משתמשים ספציפיים ב-Google שהמשתמש העניק לאפליקציה הרשאה לגשת אליהם. כדי לקבל גישה להיקפים האלה, תצטרכו לעבור אימות נוסף של האפליקציה. מידע על הדרישה הזו זמין בקטע דרישות לגבי היקפים רגישים ומוכרים.
אם האפליקציה שלכם זקוקה לגישה לממשקי Google API אחרים, תוכלו להוסיף גם את ההיקפים האלה. למידע נוסף על היקפי ההרשאות של Google API, תוכלו לקרוא את המאמר שימוש ב-OAuth 2.0 כדי לגשת ל-Google APIs.
[[["התוכן קל להבנה","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"]],["עדכון אחרון: 2025-08-01 (שעון UTC)."],[],[],null,["# Choose Google Docs API scopes\n\nThis document contains Google Docs API-specific authorization and\nauthentication information. Before reading this document, be sure to read the\nGoogle Workspace's general authentication and authorization information at\n[Learn about authentication and authorization](/workspace/guides/auth-overview).\n\nConfigure OAuth 2.0 for authorization\n-------------------------------------\n\n[Configure the OAuth consent screen and choose scopes](/workspace/guides/configure-oauth-consent)\nto define what information is displayed to users and app reviewers, and register\nyour app so that you can publish it later.\n\nDocs API scopes\n---------------\n\nTo define the level of access granted to your app, you need to identify and\ndeclare *authorization scopes*. An authorization scope is an OAuth 2.0 URI string\nthat contains the Google Workspace app name, what kind of data it accesses, and\nthe level of access. Scopes are your app's requests to work with Google Workspace data, including\nusers' Google Account data.\n\n\nWhen your app is installed, a user is asked to validate the scopes used\nby the app. Generally, you should choose the most narrowly focused scope\npossible and avoid requesting scopes that your app doesn't require. Users more\nreadily grant access to limited, clearly described scopes.\n\nWhen possible, we recommend using non-sensitive scopes as it grants per-file\naccess scope and narrows access to specific features needed by an app.\n| If your public application uses scopes that permit access to certain user data, it must complete a verification process. If you see **unverified\n| app** on the screen when testing your application, you must submit a verification request to remove it. Find out more about [unverified apps](https://support.google.com/cloud/answer/7454865) and get answers to [frequently asked questions about app verification](https://support.google.com/cloud/answer/9110914) in the Help Center.\n\nThe Docs API supports the following scopes:\n\n| Scope code | Description | Usage |\n|------------------------------------------------------|-------------------------------------------------------------------------------------------|---------------------------|\n| `https://www.googleapis.com/auth/documents` | See, edit, create, and delete all your Google Docs documents. | Sensitive |\n| `https://www.googleapis.com/auth/documents.readonly` | See all your Google Docs documents. | Sensitive |\n| `https://www.googleapis.com/auth/drive.file` | See, edit, create, and delete only the specific Google Drive files you use with this app. | Recommended Non-sensitive |\n| `https://www.googleapis.com/auth/drive` | See, edit, create, and delete all of your Google Drive files. | Restricted |\n| `https://www.googleapis.com/auth/drive.readonly` | See and download all your Google Drive files. | Restricted |\n\nThe Usage column in the table indicates the sensitivity of each scope, according\nto the following definitions:\n\n- **Non-sensitive** : These scopes provide the smallest scope of authorization\n access and only requires basic app verification. For information on this\n requirement, see [Submitting your app for\n verification](https://support.google.com/cloud/answer/13461325).\n\n- **Sensitive** : These scopes provide access to specific Google User Data\n that's authorized by the user for your app. It requires you to go through\n additional app verification. For information on this requirement, see\n [Sensitive and Restricted Scope\n Requirements](https://support.google.com/cloud/answer/13464321#ss-rs-requirements).\n\n- **Restricted** : These scopes provide wide access to Google User Data and\n require you to go through a restricted scope verification process. For\n information on this requirement, see [Google API Services User Data\n Policy](/terms/api-services-user-data-policy) and [Additional Requirements\n for Specific API\n Scopes](/terms/api-services-user-data-policy#additional_requirements_for_specific_api_scopes).\n If you store restricted scope data on servers (or transmit), then you must\n go through a security assessment.\n\nIf your app requires access to any other Google APIs, you can add those scopes\nas well. For more information about Google API scopes, see [Using OAuth 2.0 to\nAccess Google APIs](/identity/protocols/oauth2).\n\nFor more information about specific OAuth 2.0 scopes, see [OAuth 2.0 Scopes for\nGoogle APIs](/identity/protocols/oauth2/scopes).\n\nRelated topics\n--------------\n\n- [Choose Google Drive API scopes](/workspace/drive/api/guides/api-specific-auth)\n- [OAuth App Verification Help Center](https://support.google.com/cloud/answer/13463073)\n- [OAuth App Verification FAQs](https://support.google.com/cloud/answer/13463817)"]]