Assurance / Client / batch_get_control
batch_get_control¶
- Assurance.Client.batch_get_control(**kwargs)¶
Retrieves multiple controls in a single request. Use it instead of calling
GetControlfor each control. If the operation can’t return a control, it lists the control inerrorsand still succeeds.See also: AWS API Documentation
Request Syntax
response = client.batch_get_control( environmentArn='string', keys=[ { 'framework': 'string', 'frameworkVersion': 'string', 'controlId': 'string' }, ] )
- Parameters:
environmentArn (string) –
[REQUIRED]
The ARN of this governance environment.
keys (list) –
[REQUIRED]
The controls to retrieve, 1 to 100 per request. Keys must be unique within a request.
(dict) –
Identifying key for a single control in a batch request (within the environment named in the request).
framework (string) – [REQUIRED]
The name of the compliance framework.
frameworkVersion (string) – [REQUIRED]
The version of the compliance framework.
controlId (string) – [REQUIRED]
The control identifier. Optional. If omitted, the operation applies to the full framework.
- Return type:
dict
- Returns:
Response Syntax
{ 'controls': [ { 'type': 'MANAGED'|'CUSTOM', 'framework': 'string', 'controlId': 'string', 'frameworkVersion': 'string', 'groupId': 'string', 'title': 'string', 'description': 'string', 'requirements': [ { 'id': 'string', 'description': 'string' }, ], 'controlIntents': [ 'string', ], 'workflowType': 'automated-scan'|'document'|'hybrid', 'status': 'ACTIVE'|'PENDING'|'PRE_PROD', 'createdAt': datetime(2015, 1, 1), 'updatedAt': datetime(2015, 1, 1) }, ], 'errors': [ { 'key': { 'framework': 'string', 'frameworkVersion': 'string', 'controlId': 'string' }, 'code': 'string', 'message': 'string' }, ] }
Response Structure
(dict) –
controls (list) –
The controls that were successfully retrieved.
(dict) –
A leaf control within a framework version, with its full attributes including its requirements. To retrieve the attributes of the control group it belongs to, use
GetControlGroup. To retrieve the other controls in that group, useListControls.type (string) –
The type of the control.
framework (string) –
The name of the compliance framework.
controlId (string) –
The control identifier. Optional. If omitted, the operation applies to the full framework.
frameworkVersion (string) –
The version of the compliance framework.
groupId (string) –
The parent group ID (for example, “A.2” for control “A.2.2”).
title (string) –
The human-readable title of the control.
description (string) –
A description of the control.
requirements (list) –
The individual checks an assessment scores for this control. Absent when the control has none.
(dict) –
A single check within a leaf control, scored independently during an assessment. For document-based controls, the description defines what the evaluation looks for. Findings, assessment results, and remediation tasks reference the requirement by
id.id (string) –
The unique identifier of the requirement.
description (string) –
A description of the requirement.
controlIntents (list) –
The technical control intents classify how an assessment evaluates this leaf control. Leaf controls only.
(string) –
A technical control-intent identifier used to classify how a leaf control is evaluated.
workflowType (string) –
How AWS Assurance evaluates the control. Applies only to leaf controls. Valid values:
automated-scan– Evaluates the configuration of your AWS resources.document– Evaluates the evidence documents that you provide.hybrid– Evaluates both resource configuration and evidence documents.
status (string) –
The lifecycle status of the control.
createdAt (datetime) –
The time when you created the control. The response includes it only for controls in custom frameworks.
updatedAt (datetime) –
The time when the control was last modified. Returned for controls in custom frameworks only.
errors (list) –
The entries for requested controls that the operation could not return. Empty when the operation returned all of them; a request in which every control failed still succeeds.
(dict) –
A requested control that the operation could not return, along with the reason.
key (dict) –
The identifier of the control that the operation could not retrieve.
framework (string) –
The name of the compliance framework.
frameworkVersion (string) –
The version of the compliance framework.
controlId (string) –
The control identifier. Optional. If omitted, the operation applies to the full framework.
code (string) –
The error code. Known values: NOT_FOUND, ACCESS_DENIED, THROTTLED, INTERNAL_ERROR.
message (string) –
A human-readable explanation of why the operation could not return this control. Intended for display and logging; match on
codefor programmatic handling.
Exceptions
Assurance.Client.exceptions.ValidationExceptionAssurance.Client.exceptions.InternalServerExceptionAssurance.Client.exceptions.ThrottlingExceptionAssurance.Client.exceptions.AccessDeniedExceptionAssurance.Client.exceptions.ResourceNotFoundException