Method: labels.permissions.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.
Liệt kê các quyền đối với nhãn.
Yêu cầu HTTP
GET https://drivelabels.googleapis.com/v2/{parent=labels/*}/permissions
URL sử dụng cú pháp Chuyển mã gRPC.
Tham số đường dẫn
Thông số |
parent |
string
Bắt buộc. Tên tài nguyên nhãn mẹ mà quyền đối với nhãn được liệt kê. Định dạng: labels/{label} .
|
Tham số truy vấn
Thông số |
useAdminAccess |
boolean
Đặt thành true để sử dụng thông tin đăng nhập quản trị của người dùng. Máy chủ sẽ xác minh xem người dùng có phải là quản trị viên của nhãn hay không trước khi cho phép truy cập.
|
pageSize |
integer
Số lượng quyền tối đa cần trả về trên mỗi trang. Mặc định: 50. Tối đa: 200.
|
pageToken |
string
Mã thông báo của trang cần trả về.
|
Nội dung yêu cầu
Nội dung yêu cầu phải trống.
Nội dung phản hồi
Nếu thành công, nội dung phản hồi sẽ chứa một phiên bản của ListLabelPermissionsResponse
.
Phạm vi uỷ quyền
Yêu cầu một trong các phạm vi OAuth sau:
https://www.googleapis.com/auth/drive.labels
https://www.googleapis.com/auth/drive.labels.readonly
https://www.googleapis.com/auth/drive.admin.labels
https://www.googleapis.com/auth/drive.admin.labels.readonly
Để biết thêm thông tin, hãy xem Hướng dẫn uỷ quyền.
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-08-05 UTC.
[null,null,["Cập nhật lần gần đây nhất: 2025-08-05 UTC."],[],[],null,["# Method: labels.permissions.list\n\n- [HTTP request](#body.HTTP_TEMPLATE)\n- [Path parameters](#body.PATH_PARAMETERS)\n- [Query parameters](#body.QUERY_PARAMETERS)\n- [Request body](#body.request_body)\n- [Response body](#body.response_body)\n- [Authorization scopes](#body.aspect)\n- [Try it!](#try-it)\n\nLists a label's permissions.\n\n### HTTP request\n\n`GET https://drivelabels.googleapis.com/v2/{parent=labels/*}/permissions`\n\nThe URL uses [gRPC Transcoding](https://google.aip.dev/127) syntax.\n\n### Path parameters\n\n| Parameters ||\n|----------|--------------------------------------------------------------------------------------------------------------------|\n| `parent` | `string` Required. The parent label resource name on which label permissions are listed. Format: `labels/{label}`. |\n\n### Query parameters\n\n| Parameters ||\n|------------------|---------------------------------------------------------------------------------------------------------------------------------------------------------|\n| `useAdminAccess` | `boolean` Set to `true` in order to use the user's admin credentials. The server will verify the user is an admin for the label before allowing access. |\n| `pageSize` | `integer` Maximum number of permissions to return per page. Default: 50. Max: 200. |\n| `pageToken` | `string` The token of the page to return. |\n\n### Request body\n\nThe request body must be empty.\n\n### Response body\n\nIf successful, the response body contains an instance of [ListLabelPermissionsResponse](/workspace/drive/labels/reference/rest/v2/ListLabelPermissionsResponse).\n\n### Authorization scopes\n\nRequires one of the following OAuth scopes:\n\n- `https://www.googleapis.com/auth/drive.labels`\n- `\n https://www.googleapis.com/auth/drive.labels.readonly`\n- `\n https://www.googleapis.com/auth/drive.admin.labels`\n- `\n https://www.googleapis.com/auth/drive.admin.labels.readonly`\n\nFor more information, see the [Authorization guide](/workspace/guides/configure-oauth-consent)."]]