listHostedZoneAssociations method

Future<ListHostedZoneAssociationsOutput> listHostedZoneAssociations({
  1. required String resourceArn,
  2. int? maxResults,
  3. String? nextToken,
})

Lists all hosted zone associations for a Route 53 Global Resolver resource with pagination support.

May throw AccessDeniedException. May throw InternalServerException. May throw ResourceNotFoundException. May throw ThrottlingException. May throw ValidationException.

Parameter resourceArn : Amazon Resource Name (ARN) of the DNS view.

Parameter maxResults : The maximum number of results to retrieve in a single call.

Parameter nextToken : A pagination token used for large sets of results that can't be returned in a single response.

Implementation

Future<ListHostedZoneAssociationsOutput> listHostedZoneAssociations({
  required String resourceArn,
  int? maxResults,
  String? nextToken,
}) async {
  final $query = <String, List<String>>{
    if (maxResults != null) 'max_results': [maxResults.toString()],
    if (nextToken != null) 'next_token': [nextToken],
  };
  final response = await _protocol.send(
    payload: null,
    method: 'GET',
    requestUri:
        '/hosted-zone-associations/resource-arn/${resourceArn.split('/').map(Uri.encodeComponent).join('/')}',
    queryParams: $query,
    exceptionFnMap: _exceptionFns,
  );
  return ListHostedZoneAssociationsOutput.fromJson(response);
}