Google Cloud כולל ממשק לניהול זהויות והרשאות גישה (IAM), שמאפשר לתת גישה למשאבים ספציפיים ב-Google Cloud רק לחלק מהמשתמשים. בעזרת IAM תוכלו לשמור על עקרון האבטחה של הרשאות מינימליות, וכך לתת למי שצריך גישה למשאבים השונים רק את רמת הגישה הדרושה.
באמצעות כללי המדיניות ב-IAM תוכלו לקבוע למי (משתמשים) יהיו הרשאות גישה (תפקידים) למשאבים מסוימים. התפקידים שאתם מקצים למשתמשים באמצעות כללי המדיניות קובעים אילו הרשאות יהיו להם.
בדף הזה מוסבר אילו תפקידים של IAM זמינים בממשקי Cloud Billing API. לדוגמה, תוכלו להשתמש ב-IAM כדי להעניק בחשבון לחיוב ב-Cloud תפקידים כמו 'ניהול עלויות בחשבון לחיוב' או 'צפייה בחשבון לחיוב'. למידע מפורט על IAM והמאפיינים שלו, תוכלו לעיין במסמכי העזרה של IAM. תוכלו לקרוא בהם גם איך מנהלים את הגישה לפרויקטים, לתיקיות ולארגונים ואיך מנהלים את הגישה למשאבים אחרים.
הרשאות ותפקידים
כדי שמשתמש יוכל לראות במסוף Google Cloud את פרטי החשבון לחיוב ב-Cloud, או כדי ששיטת Cloud Billing API תחזיר את פרטי החשבון לחיוב ב-Cloud, למשתמש או למבצע הקריאה החוזרת (caller) צריכות להיות ההרשאות הנדרשות.
ההרשאות הנדרשות ל-Cloud Billing Catalog API
אין צורך בהרשאות כדי להשתמש ב-Cloud Billing Catalog API (רשימות השירותים והמק"טים). כל הנתונים ב-API הזה ציבוריים.
ההרשאות הנדרשות ל-Cloud Billing Budget API
בטבלה הבאה מפורטות כל ההרשאות שנדרשות לצורך קריאה לכל אחת מהשיטות (method) ב-Cloud Billing Budget API, יחד עם תפקידי IAM לחיוב ב-Cloud שכוללים את ההרשאות האלה.
שיטת ה-API | ההרשאה הנדרשת | תפקידי IAM שכוללים את הרשאה |
---|---|---|
GetBudget |
כדי להציג את פרטי התקציב, למבצע הקריאה החוזרת (caller) צריכה להיות ההרשאה billing.budgets.get בחשבון לחיוב ב-Cloud של התקציב.
|
אדמין של חשבון לחיוב, ניהול עלויות בחשבון לחיוב או צפייה בחשבון לחיוב |
ListBudgets |
כדי להחזיר רשימה של תקציבים שהוחלו על חשבון לחיוב ב-Cloud, למבצע הקריאה החוזרת צריכה להיות ההרשאה billing.budgets.list בחשבון לחיוב ב-Cloud. |
אדמין של חשבון לחיוב, ניהול עלויות בחשבון לחיוב או צפייה בחשבון לחיוב |
CreateBudget |
כדי ליצור תקציב חדש, למבצע הקריאה החוזרת צריכה להיות ההרשאה billing.budgets.create בחשבון לחיוב ב-Cloud של התקציב. |
אדמין של חשבון לחיוב או ניהול עלויות בחשבון לחיוב |
UpdateBudget |
כדי לעדכן תקציב קיים, למבצע הקריאה החוזרת צריכה להיות ההרשאה billing.budgets.update בחשבון לחיוב ב-Cloud של התקציב.
|
אדמין של חשבון לחיוב או ניהול עלויות בחשבון לחיוב |
DeleteBudget |
כדי למחוק תקציב קיים, למבצע הקריאה החוזרת צריכה להיות ההרשאה billing.budgets.delete בחשבון לחיוב ב-Cloud של התקציב.
|
אדמין של חשבון לחיוב או ניהול עלויות בחשבון לחיוב |
ההרשאות הנדרשות ל-Cloud Billing Account API
בטבלה הבאה מפורטות כל ההרשאות שנדרשות להפעלת כל אחת מהשיטות (method) ב-Cloud Billing Account API, יחד עם תפקידי IAM לחיוב ב-Cloud שכוללים את ההרשאות האלה.
שיטת ה-API | ההרשאות הנדרשות | תפקידי IAM שכוללים את הרשאה |
---|---|---|
billingAccounts.create |
השיטה הזו משמשת ליצירת חשבונות משניים חדשים לחיוב ב-Cloud למבצע הקריאה החוזרת צריכה להיות ההרשאה billing.accounts.update בחשבון המשני של חשבון ההורה לחיוב ב-Cloud.
|
אדמין של חשבון לחיוב |
billingAccounts.get |
billing.accounts.get בחשבון לחיוב ב-Cloud. |
אדמין של חשבון לחיוב, ניהול עלויות בחשבון לחיוב, צפייה בחשבון לחיוב או משתמש בחשבון לחיוב |
billingAccounts.list |
אין. השיטה הזו מחזירה את כל החשבונות שמבצע הקריאה החוזרת (caller) רשאי לגשת אליהם. | אדמין של חשבון לחיוב, ניהול עלויות בחשבון לחיוב, צפייה בחשבון לחיוב או משתמש בחשבונות לחיוב ב-Cloud או ניהול החיוב בפרויקטים. |
billingAccounts.getIamPolicy |
billing.accounts.getIamPolicy בחשבון לחיוב ב-Cloud. |
אדמין של חשבון לחיוב, ניהול עלויות בחשבון לחיוב, צפייה בחשבון לחיוב או משתמש בחשבון לחיוב |
billingAccounts.setIamPolicy |
billing.accounts.setIamPolicy בחשבון לחיוב ב-Cloud. |
אדמין של חשבון לחיוב |
billingAccounts.testIamPermissions |
אין. השיטה הזו משמשת לקביעת ההרשאות שיש למבצע קריאה חוזרת בחשבון לחיוב ב-Cloud. | לא רלוונטי |
billingAccounts.patch |
billing.accounts.update בחשבון לחיוב ב-Cloud. |
אדמין של חשבון לחיוב |
billingAccounts.projects.list |
billing.resourceAssociations.list בחשבון לחיוב ב-Cloud.
|
אדמין של חשבון לחיוב, ניהול עלויות בחשבון לחיוב או צפייה בחשבון לחיוב |
projects.getBillingInfo |
resourcemanager.projects.get בפרויקט.מידע נוסף זמין במאמר בקרת גישה לפרויקטים. |
בעלי הפרויקט, עריכה בפרויקט או צפייה בפרויקט |
projects.updateBillingInfo |
billing.resourceAssociations.create בחשבון לחיוב ב-Cloud וגם resourcemanager.projects.createBillingAssignment בפרויקט. |
אדמין של חשבון לחיוב או משתמש בחשבון לחיוב, וגם ניהול החיוב בפרויקט |
תפקידים
המשתמשים לא מקבלים הרשאות בצורה ישירה. כדי להעניק למשתמשים הרשאות, צריך להקצות להם תפקידים שמוגדרת להם הרשאה אחת או יותר.
אפשר להקצות תפקיד אחד או יותר באותו משאב.
בטבלה הבאה מפורטים: 1) התפקידים הרגילים ב-IAM שתוכלו להעניק כדי לתת גישה לממשקי Cloud Billing API; 2) התיאור של התפקידים; ו-3) ההרשאות שמוגדרות להם. חלק מהתפקידים כוללים הרשאות גם לשירותים אחרים של Google Cloud.
Role | Permissions |
---|---|
Billing Account Administrator( Provides access to see and manage all aspects of billing accounts. Lowest-level resources where you can grant this role:
|
billing.accounts.close billing.accounts.get billing. billing.accounts.getIamPolicy billing. billing.accounts.getPricing billing. billing. billing.accounts.list billing.accounts.move billing. billing. billing.accounts.reopen billing.accounts.setIamPolicy billing.accounts.update billing. billing. billing.
billing.
billing.
billing.
billing.billingAccountSkus.*
billing.budgets.*
billing.credits.list billing. billing. billing.resourceAssociations.*
billing.subscriptions.*
cloudasset. cloudnotifications. cloudsupport.properties.get cloudsupport.techCases.*
commerceoffercatalog.*
compute.commitments.*
consumerprocurement.accounts.*
consumerprocurement. consumerprocurement. consumerprocurement. consumerprocurement. consumerprocurement.events.*
consumerprocurement.
consumerprocurement.orders.*
dataprocessing.datasources.get dataprocessing. dataprocessing. dataprocessing. logging.logEntries.list logging.logServiceIndexes.list logging.logServices.list logging.logs.list logging.privateLogEntries.list recommender. recommender. recommender. recommender.
recommender.
recommender. recommender. recommender. recommender. recommender. recommender. recommender. recommender. recommender. recommender. recommender. recommender. recommender.costInsights.*
recommender. recommender.
recommender.
recommender.
recommender.
recommender.
resourcemanager. resourcemanager. resourcemanager.projects.get resourcemanager.projects.list |
Billing Account Costs Manager( Manage budgets for a billing account, and view, analyze, and export cost information of a billing account. Lowest-level resources where you can grant this role:
|
billing.accounts.get billing.accounts.getIamPolicy billing. billing. billing.accounts.list billing. billing.budgets.*
billing. recommender.costInsights.*
|
Billing Account Creator( Provides access to create billing accounts. Lowest-level resources where you can grant this role:
|
billing.accounts.create resourcemanager. |
Project Billing Manager( When granted in conjunction with the Billing Account User role, provides access to assign a project's billing account or disable its billing. Lowest-level resources where you can grant this role:
|
resourcemanager. resourcemanager. |
Billing Account User( When granted in conjunction with the Project Owner role or Project Billing Manager role, provides access to associate projects with billing accounts. Lowest-level resources where you can grant this role:
|
billing.accounts.get billing.accounts.getIamPolicy billing.accounts.list billing. billing.credits.list billing. |
Billing Account Viewer( View billing account cost and pricing information, transactions, and billing and commitment recommendations. Lowest-level resources where you can grant this role:
|
billing.accounts.get billing. billing.accounts.getIamPolicy billing. billing.accounts.getPricing billing. billing. billing.accounts.list billing.
billing.
billing.
billing.
billing.billingAccountSkus.*
billing.budgets.get billing.budgets.list billing.credits.list billing. billing. billing. billing.subscriptions.get billing.subscriptions.list commerceoffercatalog.*
consumerprocurement. consumerprocurement. consumerprocurement. consumerprocurement. consumerprocurement. consumerprocurement. consumerprocurement.orders.get consumerprocurement. dataprocessing.datasources.get dataprocessing. dataprocessing. dataprocessing. recommender. recommender. recommender.costInsights.get recommender.costInsights.list recommender. recommender. recommender. recommender. recommender. recommender. recommender. |
נושאים קשורים
- איך מנהלים את הגישה לפרויקטים, לתיקיות ולארגונים (במסמכי העזרה של IAM)
- איך מנהלים את הגישה למשאבים אחרים (במסמכי העזרה של IAM)
- יצירת תפקידים בהתאמה אישית לחיוב ב-Cloud