getSettings method

Future<Settings> getSettings({
  1. String? customerId,
  2. String? $fields,
})

Returns customer-level settings.

Request parameters:

customerId - Optional. The unique identifier of the Google Workspace organization account of the customer the alert settings are associated with. Inferred from the caller identity if not provided.

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

Completes with a Settings.

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<Settings> getSettings({
  core.String? customerId,
  core.String? $fields,
}) async {
  final _queryParams = <core.String, core.List<core.String>>{
    if (customerId != null) 'customerId': [customerId],
    if ($fields != null) 'fields': [$fields],
  };

  const _url = 'v1beta1/settings';

  final _response = await _requester.request(
    _url,
    'GET',
    queryParams: _queryParams,
  );
  return Settings.fromJson(_response as core.Map<core.String, core.dynamic>);
}