Describes the details of a DDoS attack.
Parameters:
-
attack_id
(AttackId)
–
The unique identifier (ID) for the attack.
Raises:
-
AccessDeniedException
–
Exception that indicates the specified AttackId does not exist, or the requester does not have the appropriate permissions to access the AttackId.
-
InternalErrorException
–
Exception that indicates that a problem occurred with the service infrastructure. You can retry the request.
-
UnknownServiceError
–
The service returned an error code this client does not model.
Source code in docs_src/capo_shield/_services/async_shield.py
| async def describe_attack(
self,
attack_id: "capo_shield.types.attack_id.AttackId",
*,
config_overrides: Optional[AsyncShieldClientConfig] = None,
) -> "capo_shield.types.describe_attack_response.DescribeAttackResponse":
"""<p>Describes the details of a DDoS attack. </p>
Args:
attack_id: <p>The unique identifier (ID) for the attack.</p>
Raises:
capo_shield.errors.access_denied_exception.AccessDeniedException: <p>Exception that indicates the specified <code>AttackId</code> does not exist, or the requester does not have the appropriate permissions to access the <code>AttackId</code>.</p>
capo_shield.errors.internal_error_exception.InternalErrorException: <p>Exception that indicates that a problem occurred with the service infrastructure. You can retry the request.</p>
capo_shield.errors.UnknownServiceError: The service returned an error code this client does not model.
"""
async def _handler(
req: "AsyncOperationRequest[capo_shield.types.describe_attack_request.DescribeAttackRequest]",
) -> AsyncOperationResponse[
"capo_shield.types.describe_attack_response.DescribeAttackResponse"
]:
import capo_shield._operations.aws_shield_20160616.describe_attack
(
output,
http_response,
) = await capo_shield._operations.aws_shield_20160616.describe_attack.async_describe_attack(
req.options, req.input
)
return AsyncOperationResponse(output=output, response=http_response)
interceptors_, options_ = self.operation_options(
config_overrides, OperationLogging("DescribeAttack")
)
input_: capo_shield.types.describe_attack_request.DescribeAttackRequest = {
"attack_id": attack_id
}
response = await aexecute_pipeline(
AsyncOperationRequest(input=input_, options=options_),
handler=_handler,
interceptors=list(interceptors_),
)
await response.response.aclose()
return response.output
|