ListProfileResourceAssociationsCommand

Lists all the resource associations for the specified Route 53 Profile.

Example Syntax

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

import { Route53ProfilesClient, ListProfileResourceAssociationsCommand } from "@aws-sdk/client-route53profiles"; // ES Modules import
// const { Route53ProfilesClient, ListProfileResourceAssociationsCommand } = require("@aws-sdk/client-route53profiles"); // CommonJS import
const client = new Route53ProfilesClient(config);
const input = { // ListProfileResourceAssociationsRequest
  ProfileId: "STRING_VALUE", // required
  ResourceType: "STRING_VALUE",
  MaxResults: Number("int"),
  NextToken: "STRING_VALUE",
};
const command = new ListProfileResourceAssociationsCommand(input);
const response = await client.send(command);
// { // ListProfileResourceAssociationsResponse
//   ProfileResourceAssociations: [ // ProfileResourceAssociations
//     { // ProfileResourceAssociation
//       Id: "STRING_VALUE",
//       Name: "STRING_VALUE",
//       OwnerId: "STRING_VALUE",
//       ProfileId: "STRING_VALUE",
//       ResourceArn: "STRING_VALUE",
//       ResourceType: "STRING_VALUE",
//       ResourceProperties: "STRING_VALUE",
//       Status: "COMPLETE" || "DELETING" || "UPDATING" || "CREATING" || "DELETED" || "FAILED",
//       StatusMessage: "STRING_VALUE",
//       CreationTime: new Date("TIMESTAMP"),
//       ModificationTime: new Date("TIMESTAMP"),
//     },
//   ],
//   NextToken: "STRING_VALUE",
// };

ListProfileResourceAssociationsCommand Input

Parameter
Type
Description
ProfileId
Required
string | undefined

The ID of the Profile.

MaxResults
number | undefined

The maximum number of objects that you want to return for this request. If more objects are available, in the response, a NextToken value, which you can use in a subsequent call to get the next batch of objects, is provided.

If you don't specify a value for MaxResults, up to 100 objects are returned.

NextToken
string | undefined

For the first call to this list request, omit this value.

When you request a list of objects, at most the number of objects specified by MaxResults is returned. If more objects are available for retrieval, a NextToken value is returned in the response. To retrieve the next batch of objects, use the token that was returned for the prior request in your next request.

ResourceType
string | undefined

ID of a resource if you want information on only one type.

ListProfileResourceAssociationsCommand Output

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

If more than MaxResults resource associations match the specified criteria, you can submit another ListProfileResourceAssociations request to get the next group of results. In the next request, specify the value of NextToken from the previous response.

ProfileResourceAssociations
ProfileResourceAssociation[] | undefined

Information about the profile resource association that you specified in a GetProfileResourceAssociation request.

Throws

Name
Fault
Details
AccessDeniedException
client

The current account doesn't have the IAM permissions required to perform the specified operation.

InternalServiceErrorException
client

An internal server error occured. Retry your request.

InvalidNextTokenException
client

The NextToken you provided isn;t valid.

InvalidParameterException
client

One or more parameters in this request are not valid.

ResourceNotFoundException
client

The resource you are associating is not found.

ThrottlingException
client

The request was throttled. Try again in a few minutes.

ValidationException
client

You have provided an invalid command.

Route53ProfilesServiceException
Base exception class for all service exceptions from Route53Profiles service.