ListAliases - AWS Payment Cryptography Control Plane

ListAliases

Lists the aliases for all keys in the caller's AWS account and AWS Region. You can filter the list of aliases. For more information, see Using aliases in the AWS Payment Cryptography User Guide.

This is a paginated operation, which means that each response might contain only a subset of all the aliases. When the response contains only a subset of aliases, it includes a NextToken value. Use this value in a subsequent ListAliases request to get more aliases. When you receive a response with no NextToken (or an empty or null value), that means there are no more aliases to get.

Cross-account use: This operation can't be used across different AWS accounts.

Related operations:

Request Syntax

{ "MaxResults": number, "NextToken": "string" }

Request Parameters

The request accepts the following data in JSON format.

MaxResults

Use this parameter to specify the maximum number of items to return. When this value is present, AWS Payment Cryptography does not return more than the specified number of items, but it might return fewer.

This value is optional. If you include a value, it must be between 1 and 100, inclusive. If you do not include a value, it defaults to 50.

Type: Integer

Valid Range: Minimum value of 1. Maximum value of 100.

Required: No

NextToken

Use this parameter in a subsequent request after you receive a response with truncated results. Set it to the value of NextToken from the truncated response you just received.

Type: String

Length Constraints: Minimum length of 1. Maximum length of 8192.

Required: No

Response Syntax

{ "Aliases": [ { "AliasName": "string", "KeyArn": "string" } ], "NextToken": "string" }

Response Elements

If the action is successful, the service sends back an HTTP 200 response.

The following data is returned in JSON format by the service.

Aliases

The list of aliases. Each alias describes the KeyArn contained within.

Type: Array of Alias objects

NextToken

The token for the next set of results, or an empty or null value if there are no more results.

Type: String

Length Constraints: Minimum length of 1. Maximum length of 8192.

Errors

AccessDeniedException

You do not have sufficient access to perform this action.

HTTP Status Code: 400

InternalServerException

The request processing has failed because of an unknown error, exception, or failure.

HTTP Status Code: 500

ResourceNotFoundException

The request was denied due to an invalid resource error.

HTTP Status Code: 400

ServiceUnavailableException

The service cannot complete the request.

HTTP Status Code: 500

ThrottlingException

The request was denied due to request throttling.

HTTP Status Code: 400

ValidationException

The request was denied due to an invalid request error.

HTTP Status Code: 400

See Also

For more information about using this API in one of the language-specific AWS SDKs, see the following: