list method

Future<ListSupportEventSubscriptionsResponse> list(
  1. String parent, {
  2. String? filter,
  3. int? pageSize,
  4. String? pageToken,
  5. bool? showDeleted,
  6. String? $fields,
})

Lists support event subscriptions.

EXAMPLES: cURL: shell parent="organizations/123456789" curl \ --header "Authorization: Bearer $(gcloud auth print-access-token)" \ "https://cloudsupport.googleapis.com/v2/$parent/supportEventSubscriptions" Python: python import googleapiclient.discovery api_version = "v2" supportApiService = googleapiclient.discovery.build( serviceName="cloudsupport", version=api_version, discoveryServiceUrl=f"https://cloudsupport.googleapis.com/$discovery/rest?version={api_version}", ) request = supportApiService.supportEventSubscriptions().list( parent="organizations/123456789" ) print(request.execute())

Request parameters:

parent - Required. The fully qualified name of the Cloud resource to list support event subscriptions under. Format: organizations/{organization_id} Value must have pattern ^organizations/\[^/\]+$.

filter - Optional. Filter expression based on AIP-160. Supported fields:

  • pub_sub_topic - state Examples: - pub_sub_topic="projects/example-project/topics/example-topic" - state=WORKING - pub_sub_topic="projects/example-project/topics/example-topic" AND state=WORKING

pageSize - Optional. The maximum number of support event subscriptions to return.

pageToken - Optional. A token identifying the page of results to return. If unspecified, the first page is retrieved. When paginating, all other parameters provided to ListSupportEventSubscriptions must match the call that provided the page token.

showDeleted - Optional. Whether to show deleted subscriptions. By default, deleted subscriptions are not returned.

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

Completes with a ListSupportEventSubscriptionsResponse.

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<ListSupportEventSubscriptionsResponse> list(
  core.String parent, {
  core.String? filter,
  core.int? pageSize,
  core.String? pageToken,
  core.bool? showDeleted,
  core.String? $fields,
}) async {
  final queryParams_ = <core.String, core.List<core.String>>{
    'filter': ?filter == null ? null : [filter],
    'pageSize': ?pageSize == null ? null : ['${pageSize}'],
    'pageToken': ?pageToken == null ? null : [pageToken],
    'showDeleted': ?showDeleted == null ? null : ['${showDeleted}'],
    'fields': ?$fields == null ? null : [$fields],
  };

  final url_ =
      'v2/' + core.Uri.encodeFull('$parent') + '/supportEventSubscriptions';

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