|
| 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 { ListAppAssessmentResourceDriftsRequest, ListAppAssessmentResourceDriftsResponse } from "../models/models_0"; |
| 9 | +import { |
| 10 | + de_ListAppAssessmentResourceDriftsCommand, |
| 11 | + se_ListAppAssessmentResourceDriftsCommand, |
| 12 | +} from "../protocols/Aws_restJson1"; |
| 13 | +import { ResiliencehubClientResolvedConfig, ServiceInputTypes, ServiceOutputTypes } from "../ResiliencehubClient"; |
| 14 | + |
| 15 | +/** |
| 16 | + * @public |
| 17 | + */ |
| 18 | +export { __MetadataBearer, $Command }; |
| 19 | +/** |
| 20 | + * @public |
| 21 | + * |
| 22 | + * The input for {@link ListAppAssessmentResourceDriftsCommand}. |
| 23 | + */ |
| 24 | +export interface ListAppAssessmentResourceDriftsCommandInput extends ListAppAssessmentResourceDriftsRequest {} |
| 25 | +/** |
| 26 | + * @public |
| 27 | + * |
| 28 | + * The output of {@link ListAppAssessmentResourceDriftsCommand}. |
| 29 | + */ |
| 30 | +export interface ListAppAssessmentResourceDriftsCommandOutput |
| 31 | + extends ListAppAssessmentResourceDriftsResponse, |
| 32 | + __MetadataBearer {} |
| 33 | + |
| 34 | +/** |
| 35 | + * <p>Indicates the list of resource drifts that were detected while running an assessment.</p> |
| 36 | + * @example |
| 37 | + * Use a bare-bones client and the command you need to make an API call. |
| 38 | + * ```javascript |
| 39 | + * import { ResiliencehubClient, ListAppAssessmentResourceDriftsCommand } from "@aws-sdk/client-resiliencehub"; // ES Modules import |
| 40 | + * // const { ResiliencehubClient, ListAppAssessmentResourceDriftsCommand } = require("@aws-sdk/client-resiliencehub"); // CommonJS import |
| 41 | + * const client = new ResiliencehubClient(config); |
| 42 | + * const input = { // ListAppAssessmentResourceDriftsRequest |
| 43 | + * assessmentArn: "STRING_VALUE", // required |
| 44 | + * nextToken: "STRING_VALUE", |
| 45 | + * maxResults: Number("int"), |
| 46 | + * }; |
| 47 | + * const command = new ListAppAssessmentResourceDriftsCommand(input); |
| 48 | + * const response = await client.send(command); |
| 49 | + * // { // ListAppAssessmentResourceDriftsResponse |
| 50 | + * // resourceDrifts: [ // ResourceDriftList // required |
| 51 | + * // { // ResourceDrift |
| 52 | + * // appArn: "STRING_VALUE", |
| 53 | + * // appVersion: "STRING_VALUE", |
| 54 | + * // referenceId: "STRING_VALUE", |
| 55 | + * // resourceIdentifier: { // ResourceIdentifier |
| 56 | + * // logicalResourceId: { // LogicalResourceId |
| 57 | + * // identifier: "STRING_VALUE", // required |
| 58 | + * // logicalStackName: "STRING_VALUE", |
| 59 | + * // resourceGroupName: "STRING_VALUE", |
| 60 | + * // terraformSourceName: "STRING_VALUE", |
| 61 | + * // eksSourceName: "STRING_VALUE", |
| 62 | + * // }, |
| 63 | + * // resourceType: "STRING_VALUE", |
| 64 | + * // }, |
| 65 | + * // diffType: "STRING_VALUE", |
| 66 | + * // }, |
| 67 | + * // ], |
| 68 | + * // nextToken: "STRING_VALUE", |
| 69 | + * // }; |
| 70 | + * |
| 71 | + * ``` |
| 72 | + * |
| 73 | + * @param ListAppAssessmentResourceDriftsCommandInput - {@link ListAppAssessmentResourceDriftsCommandInput} |
| 74 | + * @returns {@link ListAppAssessmentResourceDriftsCommandOutput} |
| 75 | + * @see {@link ListAppAssessmentResourceDriftsCommandInput} for command's `input` shape. |
| 76 | + * @see {@link ListAppAssessmentResourceDriftsCommandOutput} for command's `response` shape. |
| 77 | + * @see {@link ResiliencehubClientResolvedConfig | config} for ResiliencehubClient's `config` shape. |
| 78 | + * |
| 79 | + * @throws {@link AccessDeniedException} (client fault) |
| 80 | + * <p>You don't have permissions to perform the requested operation. The user or role that is |
| 81 | + * making the request must have at least one IAM permissions policy attached that grants the |
| 82 | + * required permissions.</p> |
| 83 | + * |
| 84 | + * @throws {@link InternalServerException} (server fault) |
| 85 | + * <p>This exception occurs when there is an internal failure in the Resilience Hub |
| 86 | + * service.</p> |
| 87 | + * |
| 88 | + * @throws {@link ThrottlingException} (client fault) |
| 89 | + * <p>This exception occurs when you have exceeded the limit on the number of requests per second.</p> |
| 90 | + * |
| 91 | + * @throws {@link ValidationException} (client fault) |
| 92 | + * <p>This exception occurs when a request is not valid.</p> |
| 93 | + * |
| 94 | + * @throws {@link ResiliencehubServiceException} |
| 95 | + * <p>Base exception class for all service exceptions from Resiliencehub service.</p> |
| 96 | + * |
| 97 | + * @public |
| 98 | + */ |
| 99 | +export class ListAppAssessmentResourceDriftsCommand extends $Command |
| 100 | + .classBuilder< |
| 101 | + ListAppAssessmentResourceDriftsCommandInput, |
| 102 | + ListAppAssessmentResourceDriftsCommandOutput, |
| 103 | + ResiliencehubClientResolvedConfig, |
| 104 | + ServiceInputTypes, |
| 105 | + ServiceOutputTypes |
| 106 | + >() |
| 107 | + .ep({ |
| 108 | + ...commonParams, |
| 109 | + }) |
| 110 | + .m(function (this: any, Command: any, cs: any, config: ResiliencehubClientResolvedConfig, o: any) { |
| 111 | + return [ |
| 112 | + getSerdePlugin(config, this.serialize, this.deserialize), |
| 113 | + getEndpointPlugin(config, Command.getEndpointParameterInstructions()), |
| 114 | + ]; |
| 115 | + }) |
| 116 | + .s("AwsResilienceHub", "ListAppAssessmentResourceDrifts", {}) |
| 117 | + .n("ResiliencehubClient", "ListAppAssessmentResourceDriftsCommand") |
| 118 | + .f(void 0, void 0) |
| 119 | + .ser(se_ListAppAssessmentResourceDriftsCommand) |
| 120 | + .de(de_ListAppAssessmentResourceDriftsCommand) |
| 121 | + .build() {} |
0 commit comments