listOrganizationRecommendations method

Future<ListOrganizationRecommendationsResponse> listOrganizationRecommendations({
  1. DateTime? afterLastUpdatedAt,
  2. String? awsService,
  3. DateTime? beforeLastUpdatedAt,
  4. String? checkIdentifier,
  5. int? maxResults,
  6. String? nextToken,
  7. RecommendationPillar? pillar,
  8. RecommendationSource? source,
  9. RecommendationStatus? status,
  10. RecommendationType? type,
})

List a filterable set of Recommendations within an Organization. This API only supports prioritized recommendations and provides global priority recommendations, eliminating the need to call the API in each AWS Region.

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

Parameter afterLastUpdatedAt : After the last update of the Recommendation

Parameter awsService : The aws service associated with the Recommendation

Parameter beforeLastUpdatedAt : Before the last update of the Recommendation

Parameter checkIdentifier : The check identifier of the Recommendation

Parameter maxResults : The maximum number of results to return per page.

Parameter nextToken : The token for the next set of results. Use the value returned in the previous response in the next request to retrieve the next set of results.

Parameter pillar : The pillar of the Recommendation

Parameter source : The source of the Recommendation

Parameter status : The status of the Recommendation

Parameter type : The type of the Recommendation

Implementation

Future<ListOrganizationRecommendationsResponse>
    listOrganizationRecommendations({
  DateTime? afterLastUpdatedAt,
  String? awsService,
  DateTime? beforeLastUpdatedAt,
  String? checkIdentifier,
  int? maxResults,
  String? nextToken,
  RecommendationPillar? pillar,
  RecommendationSource? source,
  RecommendationStatus? status,
  RecommendationType? type,
}) async {
  final $query = <String, List<String>>{
    if (afterLastUpdatedAt != null)
      'afterLastUpdatedAt': [_s.iso8601ToJson(afterLastUpdatedAt).toString()],
    if (awsService != null) 'awsService': [awsService],
    if (beforeLastUpdatedAt != null)
      'beforeLastUpdatedAt': [
        _s.iso8601ToJson(beforeLastUpdatedAt).toString()
      ],
    if (checkIdentifier != null) 'checkIdentifier': [checkIdentifier],
    if (maxResults != null) 'maxResults': [maxResults.toString()],
    if (nextToken != null) 'nextToken': [nextToken],
    if (pillar != null) 'pillar': [pillar.value],
    if (source != null) 'source': [source.value],
    if (status != null) 'status': [status.value],
    if (type != null) 'type': [type.value],
  };
  final response = await _protocol.send(
    payload: null,
    method: 'GET',
    requestUri: '/v1/organization-recommendations',
    queryParams: $query,
    exceptionFnMap: _exceptionFns,
  );
  return ListOrganizationRecommendationsResponse.fromJson(response);
}