Method: labels.revisions.permissions.create
ラベルの権限を更新します。指定されたプリンシパルの権限が存在しない場合は、新しいラベル権限が作成されます。存在しない場合は、既存の権限が更新されます。権限はラベルリソース全体に影響します。権限は変更されず、公開する必要はありません。
HTTP リクエスト
POST https://drivelabels.googleapis.com/v2/{parent=labels/*/revisions/*}/permissions
この URL は gRPC Transcoding 構文を使用します。
パスパラメータ
パラメータ |
parent |
string
必須。ラベル権限の親ラベルリソース名が作成されます。形式: labels/{label}
|
クエリ パラメータ
パラメータ |
useAdminAccess |
boolean
ユーザーの管理者認証情報を使用するには、true に設定します。アクセスを許可する前に、サーバーがラベルの管理者であることを確認する。
|
リクエスト本文
リクエストの本文には LabelPermission
のインスタンスが含まれています。
レスポンスの本文
成功した場合、レスポンスの本文には、新しく作成された LabelPermission
のインスタンスが含まれます。
承認スコープ
次の OAuth スコープのいずれかが必要です。
https://www.googleapis.com/auth/drive.labels
https://www.googleapis.com/auth/drive.admin.labels
詳しくは、承認ガイドをご覧ください。
特に記載のない限り、このページのコンテンツはクリエイティブ・コモンズの表示 4.0 ライセンスにより使用許諾されます。コードサンプルは Apache 2.0 ライセンスにより使用許諾されます。詳しくは、Google Developers サイトのポリシーをご覧ください。Java は Oracle および関連会社の登録商標です。
最終更新日 2024-09-03 UTC。
[null,null,["最終更新日 2024-09-03 UTC。"],[[["This operation updates a Label's permissions, creating new permissions or updating existing ones for the specified principal."],["Permissions apply to the entire Label resource, are not version-controlled, and do not need publishing."],["The request requires specifying the parent Label resource name and can use admin credentials with `useAdminAccess`."],["A successful request returns the updated or newly created LabelPermission resource."],["Authorization requires specific OAuth scopes related to Drive Labels."]]],["This document outlines the process for updating a Label's permissions. It uses a `POST` request to the specified URL, including the parent Label's resource name within the path. The request requires a `LabelPermission` instance in the body. Optional `useAdminAccess` query parameter allows the use of admin credentials. Successful execution returns a newly created `LabelPermission` instance. Authorization mandates either the `https://www.googleapis.com/auth/drive.labels` or `https://www.googleapis.com/auth/drive.admin.labels` OAuth scope.\n"]]