delete method
Deletes a Label's permission.
Permissions affect the Label resource as a whole, are not revisioned, and do not require publishing.
Request parameters:
name
- Required. Label Permission resource name.
Value must have pattern ^labels/\[^/\]+/permissions/\[^/\]+$
.
useAdminAccess
- 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.
$fields
- Selector specifying which fields to include in a partial
response.
Completes with a GoogleProtobufEmpty.
Completes with a commons.ApiRequestError if the API endpoint returned an error.
If the used http.Client
completes with an error when making a REST call,
this method will complete with the same error.
Implementation
async.Future<GoogleProtobufEmpty> delete(
core.String name, {
core.bool? useAdminAccess,
core.String? $fields,
}) async {
final queryParams_ = <core.String, core.List<core.String>>{
if (useAdminAccess != null) 'useAdminAccess': ['${useAdminAccess}'],
if ($fields != null) 'fields': [$fields],
};
final url_ = 'v2/' + core.Uri.encodeFull('$name');
final response_ = await _requester.request(
url_,
'DELETE',
queryParams: queryParams_,
);
return GoogleProtobufEmpty.fromJson(
response_ as core.Map<core.String, core.dynamic>);
}