getLabel method

Future<GoogleAppsDriveLabelsV2LabelLimits> getLabel({
  1. String? name,
  2. String? $fields,
})

Get the constraints on the structure of a Label; such as, the maximum number of Fields allowed and maximum length of the label title.

Request parameters:

name - Required. Label revision resource name Must be: "limits/label"

$fields - Selector specifying which fields to include in a partial response.

Completes with a GoogleAppsDriveLabelsV2LabelLimits.

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<GoogleAppsDriveLabelsV2LabelLimits> getLabel({
  core.String? name,
  core.String? $fields,
}) async {
  final queryParams_ = <core.String, core.List<core.String>>{
    if (name != null) 'name': [name],
    if ($fields != null) 'fields': [$fields],
  };

  const url_ = 'v2/limits/label';

  final response_ = await _requester.request(
    url_,
    'GET',
    queryParams: queryParams_,
  );
  return GoogleAppsDriveLabelsV2LabelLimits.fromJson(
      response_ as core.Map<core.String, core.dynamic>);
}