listNetworks method
Retrieves a paginated list of all Wickr networks associated with your Amazon Web Services account. You can sort the results by network ID or name.
May throw BadRequestError.
May throw ForbiddenError.
May throw InternalServerError.
May throw RateLimitError.
May throw UnauthorizedError.
May throw ValidationError.
Parameter maxResults :
The maximum number of networks to return in a single page. Valid range is
1-100. Default is 10.
Parameter nextToken :
The token for retrieving the next page of results. This is returned from a
previous request when there are more results available.
Parameter sortDirection :
The direction to sort results. Valid values are 'ASC' (ascending) or
'DESC' (descending). Default is 'DESC'.
Parameter sortFields :
The field to sort networks by. Accepted values are 'networkId' and
'networkName'. Default is 'networkId'.
Implementation
Future<ListNetworksResponse> listNetworks({
int? maxResults,
String? nextToken,
SortDirection? sortDirection,
String? sortFields,
}) async {
final $query = <String, List<String>>{
if (maxResults != null) 'maxResults': [maxResults.toString()],
if (nextToken != null) 'nextToken': [nextToken],
if (sortDirection != null) 'sortDirection': [sortDirection.value],
if (sortFields != null) 'sortFields': [sortFields],
};
final response = await _protocol.send(
payload: null,
method: 'GET',
requestUri: '/networks',
queryParams: $query,
exceptionFnMap: _exceptionFns,
);
return ListNetworksResponse.fromJson(response);
}