ListCustomerAgreementsCommand

List active customer-agreements applicable to calling identity.

Example Syntax

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

import { ArtifactClient, ListCustomerAgreementsCommand } from "@aws-sdk/client-artifact"; // ES Modules import
// const { ArtifactClient, ListCustomerAgreementsCommand } = require("@aws-sdk/client-artifact"); // CommonJS import
const client = new ArtifactClient(config);
const input = { // ListCustomerAgreementsRequest
  maxResults: Number("int"),
  nextToken: "STRING_VALUE",
};
const command = new ListCustomerAgreementsCommand(input);
const response = await client.send(command);
// { // ListCustomerAgreementsResponse
//   customerAgreements: [ // CustomerAgreementList // required
//     { // CustomerAgreementSummary
//       name: "STRING_VALUE",
//       arn: "STRING_VALUE",
//       id: "STRING_VALUE",
//       agreementArn: "STRING_VALUE",
//       awsAccountId: "STRING_VALUE",
//       organizationArn: "STRING_VALUE",
//       effectiveStart: new Date("TIMESTAMP"),
//       effectiveEnd: new Date("TIMESTAMP"),
//       state: "ACTIVE" || "CUSTOMER_TERMINATED" || "AWS_TERMINATED",
//       description: "STRING_VALUE",
//       acceptanceTerms: [ // AgreementTerms
//         "STRING_VALUE",
//       ],
//       terminateTerms: [
//         "STRING_VALUE",
//       ],
//       type: "CUSTOM" || "DEFAULT" || "MODIFIED",
//     },
//   ],
//   nextToken: "STRING_VALUE",
// };

Example Usage

 Loading code editor

ListCustomerAgreementsCommand Input

Parameter
Type
Description
maxResults
number | undefined

Maximum number of resources to return in the paginated response.

nextToken
string | undefined

Pagination token to request the next page of resources.

ListCustomerAgreementsCommand Output

Parameter
Type
Description
$metadata
Required
ResponseMetadata
Metadata pertaining to this request.
customerAgreements
Required
CustomerAgreementSummary[] | undefined

List of customer-agreement resources.

nextToken
string | undefined

Pagination token to request the next page of resources.

Throws

Name
Fault
Details
AccessDeniedException
client

User does not have sufficient access to perform this action.

InternalServerException
server

An unknown server exception has occurred.

ThrottlingException
client

Request was denied due to request throttling.

ValidationException
client

Request fails to satisfy the constraints specified by an AWS service.

ArtifactServiceException
Base exception class for all service exceptions from Artifact service.