CostOptimizationHub / Paginator / ListRecommendations
ListRecommendations#
- class CostOptimizationHub.Paginator.ListRecommendations#
- paginator = client.get_paginator('list_recommendations') - paginate(**kwargs)#
- Creates an iterator that will paginate through responses from - CostOptimizationHub.Client.list_recommendations().- See also: AWS API Documentation - Request Syntax- response_iterator = paginator.paginate( filter={ 'restartNeeded': True|False, 'rollbackPossible': True|False, 'implementationEfforts': [ 'VeryLow'|'Low'|'Medium'|'High'|'VeryHigh', ], 'accountIds': [ 'string', ], 'regions': [ 'string', ], 'resourceTypes': [ 'Ec2Instance'|'LambdaFunction'|'EbsVolume'|'EcsService'|'Ec2AutoScalingGroup'|'Ec2InstanceSavingsPlans'|'ComputeSavingsPlans'|'SageMakerSavingsPlans'|'Ec2ReservedInstances'|'RdsReservedInstances'|'OpenSearchReservedInstances'|'RedshiftReservedInstances'|'ElastiCacheReservedInstances'|'RdsDbInstanceStorage'|'RdsDbInstance', ], 'actionTypes': [ 'Rightsize'|'Stop'|'Upgrade'|'PurchaseSavingsPlans'|'PurchaseReservedInstances'|'MigrateToGraviton'|'Delete', ], 'tags': [ { 'key': 'string', 'value': 'string' }, ], 'resourceIds': [ 'string', ], 'resourceArns': [ 'string', ], 'recommendationIds': [ 'string', ] }, orderBy={ 'dimension': 'string', 'order': 'Asc'|'Desc' }, includeAllRecommendations=True|False, PaginationConfig={ 'MaxItems': 123, 'PageSize': 123, 'StartingToken': 'string' } ) - Parameters:
- filter (dict) – - The constraints that you want all returned recommendations to match. - restartNeeded (boolean) – - Whether or not implementing the recommendation requires a restart. 
- rollbackPossible (boolean) – - Whether or not implementing the recommendation can be rolled back. 
- implementationEfforts (list) – - The effort required to implement the recommendation. - (string) – 
 
- accountIds (list) – - The account that the recommendation is for. - (string) – 
 
- regions (list) – - The Amazon Web Services Region of the resource. - (string) – 
 
- resourceTypes (list) – - The resource type of the recommendation. - (string) – 
 
- actionTypes (list) – - The type of action you can take by adopting the recommendation. - (string) – 
 
- tags (list) – - A list of tags assigned to the recommendation. - (dict) – - The tag structure that contains a tag key and value. - key (string) – - The key that’s associated with the tag. 
- value (string) – - The value that’s associated with the tag. 
 
 
- resourceIds (list) – - The resource ID of the recommendation. - (string) – 
 
- resourceArns (list) – - The Amazon Resource Name (ARN) of the recommendation. - (string) – 
 
- recommendationIds (list) – - The IDs for the recommendations. - (string) – 
 
 
- orderBy (dict) – - The ordering of recommendations by a dimension. - dimension (string) – - Sorts by dimension values. 
- order (string) – - The order that’s used to sort the data. 
 
- includeAllRecommendations (boolean) – List of all recommendations for a resource, or a single recommendation if de-duped by - resourceId.
- PaginationConfig (dict) – - A dictionary that provides parameters to control pagination. - MaxItems (integer) – - The total number of items to return. If the total number of items available is more than the value specified in max-items then a - NextTokenwill be provided in the output that you can use to resume pagination.
- PageSize (integer) – - The size of each page. 
- StartingToken (string) – - A token to specify where to start paginating. This is the - NextTokenfrom a previous response.
 
 
- Return type:
- dict 
- Returns:
- Response Syntax- { 'items': [ { 'recommendationId': 'string', 'accountId': 'string', 'region': 'string', 'resourceId': 'string', 'resourceArn': 'string', 'currentResourceType': 'string', 'recommendedResourceType': 'string', 'estimatedMonthlySavings': 123.0, 'estimatedSavingsPercentage': 123.0, 'estimatedMonthlyCost': 123.0, 'currencyCode': 'string', 'implementationEffort': 'string', 'restartNeeded': True|False, 'actionType': 'string', 'rollbackPossible': True|False, 'currentResourceSummary': 'string', 'recommendedResourceSummary': 'string', 'lastRefreshTimestamp': datetime(2015, 1, 1), 'recommendationLookbackPeriodInDays': 123, 'source': 'ComputeOptimizer'|'CostExplorer', 'tags': [ { 'key': 'string', 'value': 'string' }, ] }, ], 'NextToken': 'string' } - Response Structure- (dict) – - items (list) – - List of all savings recommendations. - (dict) – - Describes a recommendation. - recommendationId (string) – - The ID for the recommendation. 
- accountId (string) – - The account that the recommendation is for. 
- region (string) – - The Amazon Web Services Region of the resource. 
- resourceId (string) – - The resource ID for the recommendation. 
- resourceArn (string) – - The Amazon Resource Name (ARN) for the recommendation. 
- currentResourceType (string) – - The current resource type. 
- recommendedResourceType (string) – - The recommended resource type. 
- estimatedMonthlySavings (float) – - The estimated monthly savings amount for the recommendation. 
- estimatedSavingsPercentage (float) – - The estimated savings percentage relative to the total cost over the cost calculation lookback period. 
- estimatedMonthlyCost (float) – - The estimated monthly cost of the current resource. For Reserved Instances and Savings Plans, it refers to the cost for eligible usage. 
- currencyCode (string) – - The currency code used for the recommendation. 
- implementationEffort (string) – - The effort required to implement the recommendation. 
- restartNeeded (boolean) – - Whether or not implementing the recommendation requires a restart. 
- actionType (string) – - The type of tasks that can be carried out by this action. 
- rollbackPossible (boolean) – - Whether or not implementing the recommendation can be rolled back. 
- currentResourceSummary (string) – - Describes the current resource. 
- recommendedResourceSummary (string) – - Describes the recommended resource. 
- lastRefreshTimestamp (datetime) – - The time when the recommendation was last generated. 
- recommendationLookbackPeriodInDays (integer) – - The lookback period that’s used to generate the recommendation. 
- source (string) – - The source of the recommendation. 
- tags (list) – - A list of tags assigned to the recommendation. - (dict) – - The tag structure that contains a tag key and value. - key (string) – - The key that’s associated with the tag. 
- value (string) – - The value that’s associated with the tag. 
 
 
 
 
- NextToken (string) – - A token to resume pagination.