searchTransitiveMemberships method

Future<SearchTransitiveMembershipsResponse> searchTransitiveMemberships(
  1. String parent, {
  2. int? pageSize,
  3. String? pageToken,
  4. String? $fields,
})

Search transitive memberships of a group.

Note: This feature is only available to Google Workspace Enterprise Standard, Enterprise Plus, and Enterprise for Education; and Cloud Identity Premium accounts. If the account of the group is not one of these, a 403 (PERMISSION_DENIED) HTTP status code will be returned. A transitive membership is any direct or indirect membership of a group. Actor must have view permissions to all transitive memberships.

Request parameters:

parent - Resource name of the group to search transitive memberships in. Format: groups/{group}, where group is the unique ID assigned to the Group. Value must have pattern ^groups/\[^/\]+$.

pageSize - The default page size is 200 (max 1000).

pageToken - The next_page_token value returned from a previous list request, if any.

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

Completes with a SearchTransitiveMembershipsResponse.

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<SearchTransitiveMembershipsResponse> searchTransitiveMemberships(
  core.String parent, {
  core.int? pageSize,
  core.String? pageToken,
  core.String? $fields,
}) async {
  final queryParams_ = <core.String, core.List<core.String>>{
    if (pageSize != null) 'pageSize': ['${pageSize}'],
    if (pageToken != null) 'pageToken': [pageToken],
    if ($fields != null) 'fields': [$fields],
  };

  final url_ = 'v1/' +
      core.Uri.encodeFull('$parent') +
      '/memberships:searchTransitiveMemberships';

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