Acl: list
透過集合功能整理內容
你可以依據偏好儲存及分類內容。
傳回日曆存取控制清單中的規則。立即試用。
要求
HTTP 要求
GET https://www.googleapis.com/calendar/v3/calendars/calendarId/acl
參數
參數名稱 |
值 |
說明 |
路徑參數 |
calendarId |
string |
日曆 ID。如要擷取日曆 ID,請呼叫 calendarList.list 方法。如要存取目前登入使用者的主日曆,請使用「primary 」關鍵字。
|
選用查詢參數 |
maxResults |
integer |
一個結果頁面中傳回的項目數量上限。預設值為 100 個項目。頁面大小不得超過 250 個項目。選用。
|
pageToken |
string |
符記,可指定要傳回的結果頁面。選用。
|
showDeleted |
boolean |
是否要在結果中納入已刪除的 ACL。已刪除的 ACL 會以 role 表示,且等於「none 」。如果提供 syncToken ,系統一律會納入已刪除的 ACL。(非必要) 預設值為 False。
|
syncToken |
string |
從先前列出要求的最後一個結果頁面傳回的 nextSyncToken 欄位取得的符記。這會讓這項清單要求的結果只包含自該日期起變更的項目。自上次清單要求刪除的所有項目一律會列入結果集,且不得將 showDeleted 設為 False。 如果 syncToken 到期,伺服器會傳回 410 GONE 回應代碼,用戶端應清除儲存空間,並在沒有任何 syncToken 的情況下執行完整同步作業。 進一步瞭解增量同步處理。 選用。預設會傳回所有項目。
|
授權
這項要求需要至少具備下列其中一個範圍的授權:
範圍 |
https://www.googleapis.com/auth/calendar |
https://www.googleapis.com/auth/calendar.acls |
https://www.googleapis.com/auth/calendar.acls.readonly |
詳情請參閱「驗證與授權」頁面。
要求主體
請勿透過此方法提供要求主體。
回應
如果成功的話,這個方法會傳回回應內文,其結構如下:
{
"kind": "calendar#acl",
"etag": etag,
"nextPageToken": string,
"nextSyncToken": string,
"items": [
acl Resource
]
}
屬性名稱 |
值 |
說明 |
附註 |
kind |
string |
珍藏內容的類型 (「calendar#acl 」)。 |
|
etag |
etag |
集合的 ETag。 |
|
nextPageToken |
string |
用於存取此結果下一頁的符記。如果沒有其他結果,則會省略,並提供 nextSyncToken 。 |
|
items[] |
list |
存取控制清單上的規則清單。 |
|
nextSyncToken |
string |
權杖會在稍後用於擷取自這項結果傳回以來變更的項目。如果還有其他結果,則會省略,並提供 nextPageToken 。 |
|
試試看!
您可以使用下方的 API Explorer,針對即時資料呼叫這個方法,然後查看回應。
除非另有註明,否則本頁面中的內容是採用創用 CC 姓名標示 4.0 授權,程式碼範例則為阿帕契 2.0 授權。詳情請參閱《Google Developers 網站政策》。Java 是 Oracle 和/或其關聯企業的註冊商標。
上次更新時間:2025-07-25 (世界標準時間)。
[null,null,["上次更新時間:2025-07-25 (世界標準時間)。"],[],[],null,["# Acl: list\n\n| **Note:** Requires [authorization](#auth).\n\nReturns the rules in the access control list for the calendar.\n[Try it now](#try-it).\n\nRequest\n-------\n\n### HTTP request\n\n```\nGET https://www.googleapis.com/calendar/v3/calendars/calendarId/acl\n```\n\n### Parameters\n\n| Parameter name | Value | Description |\n|----------------|-----------|-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|\n| **Path parameters** |||\n| `calendarId` | `string` | Calendar identifier. To retrieve calendar IDs call the [calendarList.list](/workspace/calendar/api/v3/reference/calendarList/list) method. If you want to access the primary calendar of the currently logged in user, use the \"`primary`\" keyword. |\n| **Optional query parameters** |||\n| `maxResults` | `integer` | Maximum number of entries returned on one result page. By default the value is 100 entries. The page size can never be larger than 250 entries. Optional. |\n| `pageToken` | `string` | Token specifying which result page to return. Optional. |\n| `showDeleted` | `boolean` | Whether to include deleted ACLs in the result. Deleted ACLs are represented by `role` equal to \"`none`\". Deleted ACLs will always be included if `syncToken` is provided. Optional. The default is False. |\n| `syncToken` | `string` | Token obtained from the `nextSyncToken` field returned on the last page of results from the previous list request. It makes the result of this list request contain only entries that have changed since then. All entries deleted since the previous list request will always be in the result set and it is not allowed to set `showDeleted` to False. If the `syncToken` expires, the server will respond with a 410 GONE response code and the client should clear its storage and perform a full synchronization without any `syncToken`. [Learn more](/workspace/calendar/api/guides/sync) about incremental synchronization. Optional. The default is to return all entries. |\n\n### Authorization\n\nThis request requires authorization with at least one of the following scopes:\n\n| Scope |\n|----------------------------------------------------------|\n| `https://www.googleapis.com/auth/calendar` |\n| `https://www.googleapis.com/auth/calendar.acls` |\n| `https://www.googleapis.com/auth/calendar.acls.readonly` |\n\nFor more information, see the [authentication and authorization](/workspace/guides/configure-oauth-consent) page.\n\n### Request body\n\nDo not supply a request body with this method.\n\nResponse\n--------\n\nIf successful, this method returns a response body with the following structure:\n\n```objective-c\n{\n \"kind\": \"calendar#acl\",\n \"etag\": etag,\n \"nextPageToken\": string,\n \"nextSyncToken\": string,\n \"items\": [\n acl Resource\n ]\n}\n```\n\n| Property name | Value | Description | Notes |\n|-----------------|----------|---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|-------|\n| `kind` | `string` | Type of the collection (\"`calendar#acl`\"). | |\n| `etag` | `etag` | ETag of the collection. | |\n| `nextPageToken` | `string` | Token used to access the next page of this result. Omitted if no further results are available, in which case `nextSyncToken` is provided. | |\n| `items[]` | `list` | List of rules on the access control list. | |\n| `nextSyncToken` | `string` | Token used at a later point in time to retrieve only the entries that have changed since this result was returned. Omitted if further results are available, in which case `nextPageToken` is provided. | |\n\nTry it!\n-------\n\n\nUse the APIs Explorer below to call this method on live data and see the response."]]