ListConfigurationsCommand

Retrieves a list of configuration items as specified by the value passed to the required parameter configurationType. Optional filtering may be applied to refine search results.

Example Syntax

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

import { ApplicationDiscoveryServiceClient, ListConfigurationsCommand } from "@aws-sdk/client-application-discovery-service"; // ES Modules import
// const { ApplicationDiscoveryServiceClient, ListConfigurationsCommand } = require("@aws-sdk/client-application-discovery-service"); // CommonJS import
const client = new ApplicationDiscoveryServiceClient(config);
const input = { // ListConfigurationsRequest
  configurationType: "SERVER" || "PROCESS" || "CONNECTION" || "APPLICATION", // required
  filters: [ // Filters
    { // Filter
      name: "STRING_VALUE", // required
      values: [ // FilterValues // required
        "STRING_VALUE",
      ],
      condition: "STRING_VALUE", // required
    },
  ],
  maxResults: Number("int"),
  nextToken: "STRING_VALUE",
  orderBy: [ // OrderByList
    { // OrderByElement
      fieldName: "STRING_VALUE", // required
      sortOrder: "ASC" || "DESC",
    },
  ],
};
const command = new ListConfigurationsCommand(input);
const response = await client.send(command);
// { // ListConfigurationsResponse
//   configurations: [ // Configurations
//     { // Configuration
//       "<keys>": "STRING_VALUE",
//     },
//   ],
//   nextToken: "STRING_VALUE",
// };

ListConfigurationsCommand Input

See ListConfigurationsCommandInput for more details

Parameter
Type
Description
configurationType
Required
ConfigurationItemType | undefined

A valid configuration identified by Application Discovery Service.

filters
Filter[] | undefined

You can filter the request using various logical operators and a key-value format. For example:

{"key": "serverType", "value": "webServer"}

For a complete list of filter options and guidance about using them with this action, see Using the ListConfigurations Action  in the Amazon Web Services Application Discovery Service User Guide.

maxResults
number | undefined

The total number of items to return. The maximum value is 100.

nextToken
string | undefined

Token to retrieve the next set of results. For example, if a previous call to ListConfigurations returned 100 items, but you set ListConfigurationsRequest$maxResults to 10, you received a set of 10 results along with a token. Use that token in this query to get the next set of 10.

orderBy
OrderByElement[] | undefined

Certain filter criteria return output that can be sorted in ascending or descending order. For a list of output characteristics for each filter, see Using the ListConfigurations Action  in the Amazon Web Services Application Discovery Service User Guide.

ListConfigurationsCommand Output

Parameter
Type
Description
$metadata
Required
ResponseMetadata
Metadata pertaining to this request.
configurations
Record<string, string>[] | undefined

Returns configuration details, including the configuration ID, attribute names, and attribute values.

nextToken
string | undefined

Token to retrieve the next set of results. For example, if your call to ListConfigurations returned 100 items, but you set ListConfigurationsRequest$maxResults to 10, you received a set of 10 results along with this token. Use this token in the next query to retrieve the next set of 10.

Throws

Name
Fault
Details
AuthorizationErrorException
client

The user does not have permission to perform the action. Check the IAM policy associated with this user.

HomeRegionNotSetException
client

The home Region is not set. Set the home Region to continue.

InvalidParameterException
client

One or more parameters are not valid. Verify the parameters and try again.

InvalidParameterValueException
client

The value of one or more parameters are either invalid or out of range. Verify the parameter values and try again.

ResourceNotFoundException
client

The specified configuration ID was not located. Verify the configuration ID and try again.

ServerInternalErrorException
server

The server experienced an internal error. Try again.

ApplicationDiscoveryServiceServiceException
Base exception class for all service exceptions from ApplicationDiscoveryService service.