ControlTowerClient
Index > ControlTower > ControlTowerClient
Auto-generated documentation for ControlTower type annotations stubs module mypy-boto3-controltower.
ControlTowerClient
Type annotations and code completion for boto3.client("controltower")
.
boto3 documentation
from boto3.session import Session
from mypy_boto3_controltower.client import ControlTowerClient
def get_controltower_client() -> ControlTowerClient:
return Session().client("controltower")
Exceptions
boto3
client exceptions are generated in runtime.
This class provides code completion for boto3.client("controltower").exceptions
structure.
client = boto3.client("controltower")
try:
do_something(client)
except (
client.AccessDeniedException,
client.ClientError,
client.ConflictException,
client.InternalServerException,
client.ResourceNotFoundException,
client.ServiceQuotaExceededException,
client.ThrottlingException,
client.ValidationException,
) as e:
print(e)
from mypy_boto3_controltower.client import Exceptions
def handle_error(exc: Exceptions.AccessDeniedException) -> None:
...
Methods
can_paginate
Check if an operation can be paginated.
Type annotations and code completion for boto3.client("controltower").can_paginate
method.
boto3 documentation
close
Closes underlying endpoint connections.
Type annotations and code completion for boto3.client("controltower").close
method.
boto3 documentation
disable_control
This API call turns off a control.
Type annotations and code completion for boto3.client("controltower").disable_control
method.
boto3 documentation
def disable_control(
self,
*,
controlIdentifier: str,
targetIdentifier: str,
) -> DisableControlOutputTypeDef: # (1)
...
kwargs: DisableControlInputRequestTypeDef = { # (1)
"controlIdentifier": ...,
"targetIdentifier": ...,
}
parent.disable_control(**kwargs)
enable_control
This API call activates a control.
Type annotations and code completion for boto3.client("controltower").enable_control
method.
boto3 documentation
def enable_control(
self,
*,
controlIdentifier: str,
targetIdentifier: str,
) -> EnableControlOutputTypeDef: # (1)
...
kwargs: EnableControlInputRequestTypeDef = { # (1)
"controlIdentifier": ...,
"targetIdentifier": ...,
}
parent.enable_control(**kwargs)
generate_presigned_url
Generate a presigned url given a client, its method, and arguments.
Type annotations and code completion for boto3.client("controltower").generate_presigned_url
method.
boto3 documentation
def generate_presigned_url(
self,
ClientMethod: str,
Params: Mapping[str, Any] = ...,
ExpiresIn: int = 3600,
HttpMethod: str = ...,
) -> str:
...
get_control_operation
Returns the status of a particular EnableControl
or DisableControl
operation.
Type annotations and code completion for boto3.client("controltower").get_control_operation
method.
boto3 documentation
def get_control_operation(
self,
*,
operationIdentifier: str,
) -> GetControlOperationOutputTypeDef: # (1)
...
kwargs: GetControlOperationInputRequestTypeDef = { # (1)
"operationIdentifier": ...,
}
parent.get_control_operation(**kwargs)
list_enabled_controls
Lists the controls enabled by AWS Control Tower on the specified organizational unit and the accounts it contains.
Type annotations and code completion for boto3.client("controltower").list_enabled_controls
method.
boto3 documentation
def list_enabled_controls(
self,
*,
targetIdentifier: str,
maxResults: int = ...,
nextToken: str = ...,
) -> ListEnabledControlsOutputTypeDef: # (1)
...
kwargs: ListEnabledControlsInputRequestTypeDef = { # (1)
"targetIdentifier": ...,
}
parent.list_enabled_controls(**kwargs)
get_paginator
Type annotations and code completion for boto3.client("controltower").get_paginator
method with overloads.
client.get_paginator("list_enabled_controls")
-> ListEnabledControlsPaginator