IoT / Client / start_audit_mitigation_actions_task
start_audit_mitigation_actions_task#
- IoT.Client.start_audit_mitigation_actions_task(**kwargs)#
- Starts a task that applies a set of mitigation actions to the specified target. - Requires permission to access the StartAuditMitigationActionsTask action. - See also: AWS API Documentation - Request Syntax- response = client.start_audit_mitigation_actions_task( taskId='string', target={ 'auditTaskId': 'string', 'findingIds': [ 'string', ], 'auditCheckToReasonCodeFilter': { 'string': [ 'string', ] } }, auditCheckToActionsMapping={ 'string': [ 'string', ] }, clientRequestToken='string' ) - Parameters:
- taskId (string) – - [REQUIRED] - A unique identifier for the task. You can use this identifier to check the status of the task or to cancel it. 
- target (dict) – - [REQUIRED] - Specifies the audit findings to which the mitigation actions are applied. You can apply them to a type of audit check, to all findings from an audit, or to a specific set of findings. - auditTaskId (string) – - If the task will apply a mitigation action to findings from a specific audit, this value uniquely identifies the audit. 
- findingIds (list) – - If the task will apply a mitigation action to one or more listed findings, this value uniquely identifies those findings. - (string) – 
 
- auditCheckToReasonCodeFilter (dict) – - Specifies a filter in the form of an audit check and set of reason codes that identify the findings from the audit to which the audit mitigation actions task apply. - (string) – - An audit check name. Checks must be enabled for your account. (Use - DescribeAccountAuditConfigurationto see the list of all checks, including those that are enabled or use- UpdateAccountAuditConfigurationto select which checks are enabled.)- (list) – - (string) – 
 
 
 
 
- auditCheckToActionsMapping (dict) – - [REQUIRED] - For an audit check, specifies which mitigation actions to apply. Those actions must be defined in your Amazon Web Services accounts. - (string) – - An audit check name. Checks must be enabled for your account. (Use - DescribeAccountAuditConfigurationto see the list of all checks, including those that are enabled or use- UpdateAccountAuditConfigurationto select which checks are enabled.)- (list) – - (string) – 
 
 
 
- clientRequestToken (string) – - [REQUIRED] - Each audit mitigation task must have a unique client request token. If you try to start a new task with the same token as a task that already exists, an exception occurs. If you omit this value, a unique client request token is generated automatically. - This field is autopopulated if not provided. 
 
- Return type:
- dict 
- Returns:
- Response Syntax- { 'taskId': 'string' } - Response Structure- (dict) – - taskId (string) – - The unique identifier for the audit mitigation task. This matches the - taskIdthat you specified in the request.
 
 
 - Exceptions- IoT.Client.exceptions.InvalidRequestException
- IoT.Client.exceptions.TaskAlreadyExistsException
- IoT.Client.exceptions.LimitExceededException
- IoT.Client.exceptions.ThrottlingException
- IoT.Client.exceptions.InternalFailureException