Acl: list
Sử dụng bộ sưu tập để sắp xếp ngăn nắp các trang
Lưu và phân loại nội dung dựa trên lựa chọn ưu tiên của bạn.
Trả về các quy tắc trong danh sách kiểm soát quyền truy cập cho lịch.
Thử ngay.
Yêu cầu
Yêu cầu HTTP
GET https://www.googleapis.com/calendar/v3/calendars/calendarId/acl
Thông số
Tên thông số |
Giá trị |
Mô tả |
Tham số đường dẫn |
calendarId |
string |
Giá trị nhận dạng lịch. Để truy xuất mã lịch, hãy gọi phương thức calendarList.list. Nếu bạn muốn truy cập vào lịch chính của người dùng hiện đã đăng nhập, hãy sử dụng từ khoá "primary ".
|
Thông số truy vấn không bắt buộc |
maxResults |
integer |
Số mục nhập tối đa được trả về trên một trang kết quả. Theo mặc định, giá trị này là 100 mục nhập. Kích thước trang không được lớn hơn 250 mục nhập. Không bắt buộc.
|
pageToken |
string |
Mã thông báo chỉ định trang kết quả cần trả về. Không bắt buộc.
|
showDeleted |
boolean |
Liệu có đưa các ACL đã xoá vào kết quả hay không. Các ACL đã xoá được biểu thị bằng role bằng "none ". Các ACL đã xoá sẽ luôn được đưa vào nếu bạn cung cấp syncToken . Không bắt buộc. Giá trị mặc định là False.
|
syncToken |
string |
Mã thông báo lấy được từ trường nextSyncToken được trả về trên trang kết quả cuối cùng của yêu cầu danh sách trước đó. Điều này khiến kết quả của yêu cầu danh sách này chỉ chứa các mục đã thay đổi kể từ đó. Tất cả các mục đã xoá kể từ yêu cầu danh sách trước đó sẽ luôn nằm trong tập hợp kết quả và bạn không được đặt showDeleted thành False. Nếu syncToken hết hạn, máy chủ sẽ phản hồi bằng mã phản hồi 410 GONE và ứng dụng sẽ xoá bộ nhớ và thực hiện đồng bộ hoá đầy đủ mà không có syncToken nào. Tìm hiểu thêm về tính năng đồng bộ hoá gia tăng. Không bắt buộc. Chế độ mặc định là trả về tất cả mục nhập.
|
Ủy quyền
Yêu cầu này yêu cầu uỷ quyền với ít nhất một trong các phạm vi sau:
Phạm vi |
https://www.googleapis.com/auth/calendar |
https://www.googleapis.com/auth/calendar.acls |
https://www.googleapis.com/auth/calendar.acls.readonly |
Để biết thêm thông tin, hãy xem trang xác thực và uỷ quyền.
Nội dung yêu cầu
Không cung cấp nội dung yêu cầu bằng phương thức này.
Phản hồi
Nếu thành công, phương thức này sẽ trả về một nội dung phản hồi có cấu trúc sau:
{
"kind": "calendar#acl",
"etag": etag,
"nextPageToken": string,
"nextSyncToken": string,
"items": [
acl Resource
]
}
Tên tài sản |
Giá trị |
Mô tả |
Ghi chú |
kind |
string |
Loại của bộ sưu tập ("calendar#acl "). |
|
etag |
etag |
ETag của bộ sưu tập. |
|
nextPageToken |
string |
Mã thông báo dùng để truy cập vào trang tiếp theo của kết quả này. Bỏ qua nếu không có kết quả nào khác, trong trường hợp này, nextSyncToken sẽ được cung cấp. |
|
items[] |
list |
Danh sách quy tắc trong danh sách kiểm soát quyền truy cập. |
|
nextSyncToken |
string |
Mã thông báo được dùng tại một thời điểm sau đó để chỉ truy xuất các mục đã thay đổi kể từ khi kết quả này được trả về. Bỏ qua nếu có thêm kết quả, trong trường hợp này, nextPageToken sẽ được cung cấp. |
|
Hãy dùng thử!
Sử dụng Trình khám phá API bên dưới để gọi phương thức này trên dữ liệu trực tiếp và xem phản hồi.
Trừ phi có lưu ý khác, nội dung của trang này được cấp phép theo Giấy phép ghi nhận tác giả 4.0 của Creative Commons và các mẫu mã lập trình được cấp phép theo Giấy phép Apache 2.0. Để biết thông tin chi tiết, vui lòng tham khảo Chính sách trang web của Google Developers. Java là nhãn hiệu đã đăng ký của Oracle và/hoặc các đơn vị liên kết với Oracle.
Cập nhật lần gần đây nhất: 2025-07-25 UTC.
[null,null,["Cập nhật lần gần đây nhất: 2025-07-25 UTC."],[],[],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."]]