listTags method

Future<ListTagsResponse> listTags({
  1. required String resourceName,
  2. String? nextToken,
})

List all of the tags for a DAX cluster. You can call ListTags up to 10 times per second, per account.

May throw ClusterNotFoundFault. May throw InvalidARNFault. May throw InvalidClusterStateFault. May throw ServiceLinkedRoleNotFoundFault. May throw InvalidParameterValueException. May throw InvalidParameterCombinationException.

Parameter resourceName : The name of the DAX resource to which the tags belong.

Parameter nextToken : An optional token returned from a prior request. Use this token for pagination of results from this action. If this parameter is specified, the response includes only results beyond the token.

Implementation

Future<ListTagsResponse> listTags({
  required String resourceName,
  String? nextToken,
}) async {
  ArgumentError.checkNotNull(resourceName, 'resourceName');
  final headers = <String, String>{
    'Content-Type': 'application/x-amz-json-1.1',
    'X-Amz-Target': 'AmazonDAXV3.ListTags'
  };
  final jsonResponse = await _protocol.send(
    method: 'POST',
    requestUri: '/',
    exceptionFnMap: _exceptionFns,
    // TODO queryParams
    headers: headers,
    payload: {
      'ResourceName': resourceName,
      if (nextToken != null) 'NextToken': nextToken,
    },
  );

  return ListTagsResponse.fromJson(jsonResponse.body);
}