listApplications method

Future<ListApplicationsResponse> listApplications({
  1. int? maxResults,
  2. String? nextToken,
  3. List<ApplicationState>? states,
})

Lists applications based on a set of parameters.

May throw InternalServerException. May throw ValidationException.

Parameter maxResults : The maximum number of applications that can be listed.

Parameter nextToken : The token for the next set of application results.

Parameter states : An optional filter for application states. Note that if this filter contains multiple states, the resulting list will be grouped by the state.

Implementation

Future<ListApplicationsResponse> listApplications({
  int? maxResults,
  String? nextToken,
  List<ApplicationState>? states,
}) async {
  final $query = <String, List<String>>{
    if (maxResults != null) 'maxResults': [maxResults.toString()],
    if (nextToken != null) 'nextToken': [nextToken],
    if (states != null) 'states': states.map((e) => e.value).toList(),
  };
  final response = await _protocol.send(
    payload: null,
    method: 'GET',
    requestUri: '/applications',
    queryParams: $query,
    exceptionFnMap: _exceptionFns,
  );
  return ListApplicationsResponse.fromJson(response);
}