|
| 1 | +// smithy-typescript generated code |
| 2 | +import { getEndpointPlugin } from "@smithy/middleware-endpoint"; |
| 3 | +import { getSerdePlugin } from "@smithy/middleware-serde"; |
| 4 | +import { Command as $Command } from "@smithy/smithy-client"; |
| 5 | +import { MetadataBearer as __MetadataBearer } from "@smithy/types"; |
| 6 | + |
| 7 | +import { commonParams } from "../endpoint/EndpointParameters"; |
| 8 | +import { |
| 9 | + GetCertificateSigningRequestInput, |
| 10 | + GetCertificateSigningRequestOutput, |
| 11 | + GetCertificateSigningRequestOutputFilterSensitiveLog, |
| 12 | +} from "../models/models_0"; |
| 13 | +import { |
| 14 | + PaymentCryptographyClientResolvedConfig, |
| 15 | + ServiceInputTypes, |
| 16 | + ServiceOutputTypes, |
| 17 | +} from "../PaymentCryptographyClient"; |
| 18 | +import { |
| 19 | + de_GetCertificateSigningRequestCommand, |
| 20 | + se_GetCertificateSigningRequestCommand, |
| 21 | +} from "../protocols/Aws_json1_0"; |
| 22 | + |
| 23 | +/** |
| 24 | + * @public |
| 25 | + */ |
| 26 | +export type { __MetadataBearer }; |
| 27 | +export { $Command }; |
| 28 | +/** |
| 29 | + * @public |
| 30 | + * |
| 31 | + * The input for {@link GetCertificateSigningRequestCommand}. |
| 32 | + */ |
| 33 | +export interface GetCertificateSigningRequestCommandInput extends GetCertificateSigningRequestInput {} |
| 34 | +/** |
| 35 | + * @public |
| 36 | + * |
| 37 | + * The output of {@link GetCertificateSigningRequestCommand}. |
| 38 | + */ |
| 39 | +export interface GetCertificateSigningRequestCommandOutput |
| 40 | + extends GetCertificateSigningRequestOutput, |
| 41 | + __MetadataBearer {} |
| 42 | + |
| 43 | +/** |
| 44 | + * Used to retrieve the public key for a keypair. |
| 45 | + * @example |
| 46 | + * Use a bare-bones client and the command you need to make an API call. |
| 47 | + * ```javascript |
| 48 | + * import { PaymentCryptographyClient, GetCertificateSigningRequestCommand } from "@aws-sdk/client-payment-cryptography"; // ES Modules import |
| 49 | + * // const { PaymentCryptographyClient, GetCertificateSigningRequestCommand } = require("@aws-sdk/client-payment-cryptography"); // CommonJS import |
| 50 | + * const client = new PaymentCryptographyClient(config); |
| 51 | + * const input = { // GetCertificateSigningRequestInput |
| 52 | + * KeyIdentifier: "STRING_VALUE", // required |
| 53 | + * SigningAlgorithm: "STRING_VALUE", // required |
| 54 | + * CertificateSubject: { // CertificateSubjectType |
| 55 | + * CommonName: "STRING_VALUE", // required |
| 56 | + * OrganizationUnit: "STRING_VALUE", |
| 57 | + * Organization: "STRING_VALUE", |
| 58 | + * City: "STRING_VALUE", |
| 59 | + * Country: "STRING_VALUE", |
| 60 | + * StateOrProvince: "STRING_VALUE", |
| 61 | + * EmailAddress: "STRING_VALUE", |
| 62 | + * }, |
| 63 | + * }; |
| 64 | + * const command = new GetCertificateSigningRequestCommand(input); |
| 65 | + * const response = await client.send(command); |
| 66 | + * // { // GetCertificateSigningRequestOutput |
| 67 | + * // CertificateSigningRequest: "STRING_VALUE", // required |
| 68 | + * // }; |
| 69 | + * |
| 70 | + * ``` |
| 71 | + * |
| 72 | + * @param GetCertificateSigningRequestCommandInput - {@link GetCertificateSigningRequestCommandInput} |
| 73 | + * @returns {@link GetCertificateSigningRequestCommandOutput} |
| 74 | + * @see {@link GetCertificateSigningRequestCommandInput} for command's `input` shape. |
| 75 | + * @see {@link GetCertificateSigningRequestCommandOutput} for command's `response` shape. |
| 76 | + * @see {@link PaymentCryptographyClientResolvedConfig | config} for PaymentCryptographyClient's `config` shape. |
| 77 | + * |
| 78 | + * @throws {@link AccessDeniedException} (client fault) |
| 79 | + * <p>You do not have sufficient access to perform this action.</p> <p>This exception is thrown when the caller lacks the necessary IAM permissions to perform the requested operation. Verify that your IAM policy includes the required permissions for the specific Amazon Web Services Payment Cryptography action you're attempting.</p> |
| 80 | + * |
| 81 | + * @throws {@link InternalServerException} (server fault) |
| 82 | + * <p>The request processing has failed because of an unknown error, exception, or failure.</p> <p>This indicates a server-side error within the Amazon Web Services Payment Cryptography service. If this error persists, contact support for assistance.</p> |
| 83 | + * |
| 84 | + * @throws {@link ResourceNotFoundException} (client fault) |
| 85 | + * <p>The request was denied due to resource not found.</p> <p>The specified key, alias, or other resource does not exist in your account or region. Verify that the resource identifier is correct and that the resource exists in the expected region.</p> |
| 86 | + * |
| 87 | + * @throws {@link ServiceUnavailableException} (server fault) |
| 88 | + * <p>The service cannot complete the request.</p> <p>The Amazon Web Services Payment Cryptography service is temporarily unavailable. This is typically a temporary condition - retry your request after a brief delay.</p> |
| 89 | + * |
| 90 | + * @throws {@link ThrottlingException} (client fault) |
| 91 | + * <p>The request was denied due to request throttling.</p> <p>You have exceeded the rate limits for Amazon Web Services Payment Cryptography API calls. Implement exponential backoff and retry logic in your application to handle throttling gracefully.</p> |
| 92 | + * |
| 93 | + * @throws {@link ValidationException} (client fault) |
| 94 | + * <p>The request was denied due to an invalid request error.</p> <p>One or more parameters in your request are invalid. Check the parameter values, formats, and constraints specified in the API documentation.</p> |
| 95 | + * |
| 96 | + * @throws {@link PaymentCryptographyServiceException} |
| 97 | + * <p>Base exception class for all service exceptions from PaymentCryptography service.</p> |
| 98 | + * |
| 99 | + * |
| 100 | + * @public |
| 101 | + */ |
| 102 | +export class GetCertificateSigningRequestCommand extends $Command |
| 103 | + .classBuilder< |
| 104 | + GetCertificateSigningRequestCommandInput, |
| 105 | + GetCertificateSigningRequestCommandOutput, |
| 106 | + PaymentCryptographyClientResolvedConfig, |
| 107 | + ServiceInputTypes, |
| 108 | + ServiceOutputTypes |
| 109 | + >() |
| 110 | + .ep(commonParams) |
| 111 | + .m(function (this: any, Command: any, cs: any, config: PaymentCryptographyClientResolvedConfig, o: any) { |
| 112 | + return [ |
| 113 | + getSerdePlugin(config, this.serialize, this.deserialize), |
| 114 | + getEndpointPlugin(config, Command.getEndpointParameterInstructions()), |
| 115 | + ]; |
| 116 | + }) |
| 117 | + .s("PaymentCryptographyControlPlane", "GetCertificateSigningRequest", {}) |
| 118 | + .n("PaymentCryptographyClient", "GetCertificateSigningRequestCommand") |
| 119 | + .f(void 0, GetCertificateSigningRequestOutputFilterSensitiveLog) |
| 120 | + .ser(se_GetCertificateSigningRequestCommand) |
| 121 | + .de(de_GetCertificateSigningRequestCommand) |
| 122 | + .build() { |
| 123 | + /** @internal type navigation helper, not in runtime. */ |
| 124 | + protected declare static __types: { |
| 125 | + api: { |
| 126 | + input: GetCertificateSigningRequestInput; |
| 127 | + output: GetCertificateSigningRequestOutput; |
| 128 | + }; |
| 129 | + sdk: { |
| 130 | + input: GetCertificateSigningRequestCommandInput; |
| 131 | + output: GetCertificateSigningRequestCommandOutput; |
| 132 | + }; |
| 133 | + }; |
| 134 | +} |
0 commit comments