list method

Future<ListGroupMembersResponse> list (
  1. String name,
  2. {String interval_endTime,
  3. String filter,
  4. String pageToken,
  5. int pageSize,
  6. String interval_startTime,
  7. String $fields}
)

Lists the monitored resources that are members of a group.

Request parameters:

name - Required. The group whose members are listed. The format is: projects/PROJECT_ID_OR_NUMBER/groups/GROUP_ID

Value must have pattern "^projects/^/+/groups/^/+$".

interval_endTime - Required. The end of the time interval.

filter - An optional list filter (https://cloud.google.com/monitoring/api/learn_more#filtering) describing the members to be returned. The filter may reference the type, labels, and metadata of monitored resources that comprise the group. For example, to return only resources representing Compute Engine VM instances, use this filter: resource.type = "gce_instance"

pageToken - If this field is not empty then it must contain the next_page_token value returned by a previous call to this method. Using this field causes the method to return additional results from the previous method call.

pageSize - A positive number that is the maximum number of results to return.

interval_startTime - Optional. The beginning of the time interval. The default value for the start time is the end time. The start time must not be later than the end time.

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

Completes with a ListGroupMembersResponse.

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<ListGroupMembersResponse> list(core.String name,
    {core.String interval_endTime,
    core.String filter,
    core.String pageToken,
    core.int pageSize,
    core.String interval_startTime,
    core.String $fields}) {
  var _url;
  var _queryParams = new core.Map<core.String, core.List<core.String>>();
  var _uploadMedia;
  var _uploadOptions;
  var _downloadOptions = commons.DownloadOptions.Metadata;
  var _body;

  if (name == null) {
    throw new core.ArgumentError("Parameter name is required.");
  }
  if (interval_endTime != null) {
    _queryParams["interval.endTime"] = [interval_endTime];
  }
  if (filter != null) {
    _queryParams["filter"] = [filter];
  }
  if (pageToken != null) {
    _queryParams["pageToken"] = [pageToken];
  }
  if (pageSize != null) {
    _queryParams["pageSize"] = ["${pageSize}"];
  }
  if (interval_startTime != null) {
    _queryParams["interval.startTime"] = [interval_startTime];
  }
  if ($fields != null) {
    _queryParams["fields"] = [$fields];
  }

  _url = 'v3/' + commons.Escaper.ecapeVariableReserved('$name') + '/members';

  var _response = _requester.request(_url, "GET",
      body: _body,
      queryParams: _queryParams,
      uploadOptions: _uploadOptions,
      uploadMedia: _uploadMedia,
      downloadOptions: _downloadOptions);
  return _response
      .then((data) => new ListGroupMembersResponse.fromJson(data));
}