listOutposts method

Future<ListOutpostsOutput> listOutposts({
  1. int? maxResults,
  2. String? nextToken,
})

List the Outposts for your AWS account.

May throw ValidationException. May throw AccessDeniedException. May throw InternalServerException.

Implementation

Future<ListOutpostsOutput> listOutposts({
  int? maxResults,
  String? nextToken,
}) async {
  _s.validateNumRange(
    'maxResults',
    maxResults,
    1,
    1000,
  );
  _s.validateStringLength(
    'nextToken',
    nextToken,
    1,
    1005,
  );
  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: '/outposts',
    queryParams: $query,
    exceptionFnMap: _exceptionFns,
  );
  return ListOutpostsOutput.fromJson(response);
}