listLinkRoutingRules method

Future<ListLinkRoutingRulesResponse> listLinkRoutingRules({
  1. required String gatewayId,
  2. required String linkId,
  3. int? maxResults,
  4. String? nextToken,
})

Lists the routing rules for a link.

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

Parameter gatewayId : The unique identifier of the gateway.

Parameter linkId : The unique identifier of the link.

Parameter maxResults : The maximum number of results that are returned per call. You can use nextToken to obtain further pages of results.

This is only an upper limit. The actual number of results returned per call might be fewer than the specified maximum.

Parameter nextToken : If nextToken is returned, there are more results available. The value of nextToken is a unique pagination token for each page. Make the call again using the returned token to retrieve the next page. Keep all other arguments unchanged. Each pagination token expires after 24 hours. Using an expired pagination token will return an HTTP 400 InvalidToken error.

Implementation

Future<ListLinkRoutingRulesResponse> listLinkRoutingRules({
  required String gatewayId,
  required String linkId,
  int? maxResults,
  String? nextToken,
}) async {
  final $query = <String, List<String>>{
    if (maxResults != null) 'maxResults': [maxResults.toString()],
    if (nextToken != null) 'nextToken': [nextToken],
  };
  final response = await _protocol.send(
    payload: null,
    method: 'GET',
    requestUri:
        '/responder-gateway/${Uri.encodeComponent(gatewayId)}/link/${Uri.encodeComponent(linkId)}/routing-rules',
    queryParams: $query,
    exceptionFnMap: _exceptionFns,
  );
  return ListLinkRoutingRulesResponse.fromJson(response);
}