list_recommendations
¶
list_recommendations(
*,
config_overrides: Optional[TrustedAdvisorClientConfig] = None,
next_token: Optional[str] = None,
max_results: Optional[int] = None,
type: Optional[RecommendationType] = None,
status: Optional[RecommendationStatus] = None,
pillar: Optional[RecommendationPillar] = None,
aws_service: Optional[RecommendationAwsService] = None,
source: Optional[RecommendationSource] = None,
check_identifier: Optional[CheckIdentifier] = None,
after_last_updated_at: Optional[datetime] = None,
before_last_updated_at: Optional[datetime] = None,
language: Optional[RecommendationLanguage] = None,
) -> ListRecommendationsResponse
List a filterable set of Recommendations. This API provides global recommendations, eliminating the need to call the API in each AWS Region.
Parameters:
-
next_token(Optional[str], default:None) –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.
-
max_results(Optional[int], default:None) –The maximum number of results to return per page.
-
type(Optional[RecommendationType], default:None) –The type of the Recommendation
-
status(Optional[RecommendationStatus], default:None) –The status of the Recommendation
-
pillar(Optional[RecommendationPillar], default:None) –The pillar of the Recommendation
-
aws_service(Optional[RecommendationAwsService], default:None) –The aws service associated with the Recommendation
-
source(Optional[RecommendationSource], default:None) –The source of the Recommendation
-
check_identifier(Optional[CheckIdentifier], default:None) –The check identifier of the Recommendation
-
after_last_updated_at(Optional[datetime], default:None) –After the last update of the Recommendation
-
before_last_updated_at(Optional[datetime], default:None) –Before the last update of the Recommendation
-
language(Optional[RecommendationLanguage], default:None) –The ISO 639-1 code for the language that you want your recommendations to appear in.
Raises:
-
AccessDeniedException–Exception that access has been denied due to insufficient access
-
InternalServerException–Exception to notify that an unexpected internal error occurred during processing of the request
-
ThrottlingException–Exception to notify that requests are being throttled
-
ValidationException–Exception that the request failed to satisfy service constraints
-
UnknownServiceError–The service returned an error code this client does not model.
Examples:
List all Recommendations
>>> client.list_recommendations()
Filter and return a max of one Recommendation that is a part of AWS IAM
>>> client.list_recommendations(aws_service='iam', max_results=100)
Use the "nextToken" returned from a previous request to fetch the next page of filtered Recommendations
Source code in docs_src/capo_trustedadvisor/_services/trusted_advisor.py
1014 1015 1016 1017 1018 1019 1020 1021 1022 1023 1024 1025 1026 1027 1028 1029 1030 1031 1032 1033 1034 1035 1036 1037 1038 1039 1040 1041 1042 1043 1044 1045 1046 1047 1048 1049 1050 1051 1052 1053 1054 1055 1056 1057 1058 1059 1060 1061 1062 1063 1064 1065 1066 1067 1068 1069 1070 1071 1072 1073 1074 1075 1076 1077 1078 1079 1080 1081 1082 1083 1084 1085 1086 1087 1088 1089 1090 1091 1092 1093 1094 1095 1096 1097 1098 1099 1100 1101 1102 1103 1104 1105 1106 1107 1108 1109 1110 1111 1112 1113 1114 1115 1116 1117 1118 1119 1120 1121 1122 1123 1124 1125 | |