Gets all versions for a specified detector.
Parameters:
Raises:
Source code in docs_src/capo_frauddetector/_services/fraud_detector.py
| def describe_detector(
self,
detector_id: "capo_frauddetector.types.identifier.identifier",
*,
config_overrides: Optional[FraudDetectorClientConfig] = None,
next_token: Optional["capo_frauddetector.types.string.string"] = None,
max_results: Optional[
"capo_frauddetector.types.detector_version_max_results.DetectorVersionMaxResults"
] = None,
) -> "capo_frauddetector.types.describe_detector_result.DescribeDetectorResult":
"""<p>Gets all versions for a specified detector.</p>
Args:
detector_id: <p>The detector ID.</p>
next_token: <p>The next token from the previous response.</p>
max_results: <p>The maximum number of results to return for the request.</p>
Raises:
capo_frauddetector.errors.access_denied_exception.AccessDeniedException: <p>An exception indicating Amazon Fraud Detector does not have the needed permissions. This can occur if you submit a request, such as <code>PutExternalModel</code>, that specifies a role that is not in your account.</p>
capo_frauddetector.errors.internal_server_exception.InternalServerException: <p>An exception indicating an internal server error.</p>
capo_frauddetector.errors.resource_not_found_exception.ResourceNotFoundException: <p>An exception indicating the specified resource was not found.</p>
capo_frauddetector.errors.throttling_exception.ThrottlingException: <p>An exception indicating a throttling error.</p>
capo_frauddetector.errors.validation_exception.ValidationException: <p>An exception indicating a specified value is not allowed.</p>
capo_frauddetector.errors.UnknownServiceError: The service returned an error code this client does not model.
"""
def _handler(
req: "OperationRequest[capo_frauddetector.types.describe_detector_request.DescribeDetectorRequest]",
) -> OperationResponse[
"capo_frauddetector.types.describe_detector_result.DescribeDetectorResult"
]:
import capo_frauddetector._operations.aws_hawks_nest_service_facade.describe_detector
output, http_response = (
capo_frauddetector._operations.aws_hawks_nest_service_facade.describe_detector.describe_detector(
req.options, req.input
)
)
return OperationResponse(output=output, response=http_response)
interceptors_, options_ = self.operation_options(
config_overrides, OperationLogging("DescribeDetector")
)
input_: capo_frauddetector.types.describe_detector_request.DescribeDetectorRequest = {
"detector_id": detector_id
}
if next_token is not None:
input_["next_token"] = next_token
if max_results is not None:
input_["max_results"] = max_results
response = execute_pipeline(
OperationRequest(input=input_, options=options_),
handler=_handler,
interceptors=list(interceptors_),
)
response.response.close()
return response.output
|