ListRecommendationsCommand

List the Amazon Redshift Advisor recommendations for one or multiple Amazon Redshift clusters in an Amazon Web Services account.

Example Syntax

Use a bare-bones client and the command you need to make an API call.

import { RedshiftClient, ListRecommendationsCommand } from "@aws-sdk/client-redshift"; // ES Modules import
// const { RedshiftClient, ListRecommendationsCommand } = require("@aws-sdk/client-redshift"); // CommonJS import
const client = new RedshiftClient(config);
const input = { // ListRecommendationsMessage
  ClusterIdentifier: "STRING_VALUE",
  NamespaceArn: "STRING_VALUE",
  MaxRecords: Number("int"),
  Marker: "STRING_VALUE",
};
const command = new ListRecommendationsCommand(input);
const response = await client.send(command);
// { // ListRecommendationsResult
//   Recommendations: [ // RecommendationList
//     { // Recommendation
//       Id: "STRING_VALUE",
//       ClusterIdentifier: "STRING_VALUE",
//       NamespaceArn: "STRING_VALUE",
//       CreatedAt: new Date("TIMESTAMP"),
//       RecommendationType: "STRING_VALUE",
//       Title: "STRING_VALUE",
//       Description: "STRING_VALUE",
//       Observation: "STRING_VALUE",
//       ImpactRanking: "HIGH" || "MEDIUM" || "LOW",
//       RecommendationText: "STRING_VALUE",
//       RecommendedActions: [ // RecommendedActionList
//         { // RecommendedAction
//           Text: "STRING_VALUE",
//           Database: "STRING_VALUE",
//           Command: "STRING_VALUE",
//           Type: "SQL" || "CLI",
//         },
//       ],
//       ReferenceLinks: [ // ReferenceLinkList
//         { // ReferenceLink
//           Text: "STRING_VALUE",
//           Link: "STRING_VALUE",
//         },
//       ],
//     },
//   ],
//   Marker: "STRING_VALUE",
// };

ListRecommendationsCommand Input

See ListRecommendationsCommandInput for more details

Parameter
Type
Description
ClusterIdentifier
string | undefined

The unique identifier of the Amazon Redshift cluster for which the list of Advisor recommendations is returned. If the neither the cluster identifier and the cluster namespace ARN parameters are specified, then recommendations for all clusters in the account are returned.

Marker
string | undefined

A value that indicates the starting point for the next set of response records in a subsequent request. If a value is returned in a response, you can retrieve the next set of records by providing this returned marker value in the Marker parameter and retrying the command. If the Marker field is empty, all response records have been retrieved for the request.

MaxRecords
number | undefined

The maximum number of response records to return in each call. If the number of remaining response records exceeds the specified MaxRecords value, a value is returned in a marker field of the response. You can retrieve the next set of records by retrying the command with the returned marker value.

NamespaceArn
string | undefined

The Amazon Redshift cluster namespace Amazon Resource Name (ARN) for which the list of Advisor recommendations is returned. If the neither the cluster identifier and the cluster namespace ARN parameters are specified, then recommendations for all clusters in the account are returned.

ListRecommendationsCommand Output

Parameter
Type
Description
$metadata
Required
ResponseMetadata
Metadata pertaining to this request.
Marker
string | undefined

A value that indicates the starting point for the next set of response records in a subsequent request. If a value is returned in a response, you can retrieve the next set of records by providing this returned marker value in the Marker parameter and retrying the command. If the Marker field is empty, all response records have been retrieved for the request.

Recommendations
Recommendation[] | undefined

The Advisor recommendations for action on the Amazon Redshift cluster.

Throws

Name
Fault
Details
ClusterNotFoundFault
client

The ClusterIdentifier parameter does not refer to an existing cluster.

UnsupportedOperationFault
client

The requested operation isn't supported.

RedshiftServiceException
Base exception class for all service exceptions from Redshift service.