- Navigation GuideYou are on a Command (operation) page with structural examples. Use the navigation breadcrumb if you would like to return to the Client landing page.
BatchUpdateMemberEc2DeepInspectionStatusCommand
Activates or deactivates Amazon Inspector deep inspection for the provided member accounts in your organization. You must be the delegated administrator of an organization in Amazon Inspector to use this API.
Example Syntax
Use a bare-bones client and the command you need to make an API call.
import { Inspector2Client, BatchUpdateMemberEc2DeepInspectionStatusCommand } from "@aws-sdk/client-inspector2"; // ES Modules import
// const { Inspector2Client, BatchUpdateMemberEc2DeepInspectionStatusCommand } = require("@aws-sdk/client-inspector2"); // CommonJS import
const client = new Inspector2Client(config);
const input = { // BatchUpdateMemberEc2DeepInspectionStatusRequest
accountIds: [ // MemberAccountEc2DeepInspectionStatusList // required
{ // MemberAccountEc2DeepInspectionStatus
accountId: "STRING_VALUE", // required
activateDeepInspection: true || false, // required
},
],
};
const command = new BatchUpdateMemberEc2DeepInspectionStatusCommand(input);
const response = await client.send(command);
// { // BatchUpdateMemberEc2DeepInspectionStatusResponse
// accountIds: [ // MemberAccountEc2DeepInspectionStatusStateList
// { // MemberAccountEc2DeepInspectionStatusState
// accountId: "STRING_VALUE", // required
// status: "STRING_VALUE",
// errorMessage: "STRING_VALUE",
// },
// ],
// failedAccountIds: [ // FailedMemberAccountEc2DeepInspectionStatusStateList
// { // FailedMemberAccountEc2DeepInspectionStatusState
// accountId: "STRING_VALUE", // required
// ec2ScanStatus: "STRING_VALUE",
// errorMessage: "STRING_VALUE",
// },
// ],
// };
BatchUpdateMemberEc2DeepInspectionStatusCommand Input
Parameter | Type | Description |
---|
Parameter | Type | Description |
---|---|---|
accountIds Required | MemberAccountEc2DeepInspectionStatus[] | undefined | The unique identifiers for the Amazon Web Services accounts to change Amazon Inspector deep inspection status for. |
BatchUpdateMemberEc2DeepInspectionStatusCommand Output
Parameter | Type | Description |
---|
Parameter | Type | Description |
---|---|---|
$metadata Required | ResponseMetadata | Metadata pertaining to this request. |
accountIds | MemberAccountEc2DeepInspectionStatusState[] | undefined | An array of objects that provide details for each of the accounts that Amazon Inspector deep inspection status was successfully changed for. |
failedAccountIds | FailedMemberAccountEc2DeepInspectionStatusState[] | undefined | An array of objects that provide details for each of the accounts that Amazon Inspector deep inspection status could not be successfully changed for. |
Throws
Name | Fault | Details |
---|
Name | Fault | Details |
---|---|---|
AccessDeniedException | client | You do not have sufficient access to perform this action. For |
InternalServerException | server | The request has failed due to an internal failure of the Amazon Inspector service. |
ThrottlingException | client | The limit on the number of requests per second was exceeded. |
ValidationException | client | The request has failed validation due to missing required fields or having invalid inputs. |
Inspector2ServiceException | Base exception class for all service exceptions from Inspector2 service. |