listQueueLimitAssociations method

Future<ListQueueLimitAssociationsResponse> listQueueLimitAssociations({
  1. required String farmId,
  2. String? limitId,
  3. int? maxResults,
  4. String? nextToken,
  5. String? queueId,
})

Gets a list of the associations between queues and limits defined in a farm.

May throw AccessDeniedException. May throw InternalServerErrorException. May throw ResourceNotFoundException. May throw ThrottlingException.

Parameter farmId : The unique identifier of the farm that contains the limits and associations.

Parameter limitId : Specifies that the operation should return only the queue limit associations for the specified limit. If you specify both the queueId and the limitId, only the specified limit is returned if it exists.

Parameter maxResults : The maximum number of associations to return in each page of results.

Parameter nextToken : The token for the next set of results, or null to start from the beginning.

Parameter queueId : Specifies that the operation should return only the queue limit associations for the specified queue. If you specify both the queueId and the limitId, only the specified limit is returned if it exists.

Implementation

Future<ListQueueLimitAssociationsResponse> listQueueLimitAssociations({
  required String farmId,
  String? limitId,
  int? maxResults,
  String? nextToken,
  String? queueId,
}) async {
  _s.validateNumRange(
    'maxResults',
    maxResults,
    1,
    100,
  );
  final $query = <String, List<String>>{
    if (limitId != null) 'limitId': [limitId],
    if (maxResults != null) 'maxResults': [maxResults.toString()],
    if (nextToken != null) 'nextToken': [nextToken],
    if (queueId != null) 'queueId': [queueId],
  };
  final response = await _protocol.send(
    payload: null,
    method: 'GET',
    requestUri:
        '/2023-10-12/farms/${Uri.encodeComponent(farmId)}/queue-limit-associations',
    queryParams: $query,
    exceptionFnMap: _exceptionFns,
  );
  return ListQueueLimitAssociationsResponse.fromJson(response);
}