Skip to content

get_evidence async

get_evidence(
    assessment_id: UUID,
    control_set_id: ControlSetId,
    evidence_folder_id: UUID,
    evidence_id: UUID,
    *,
    config_overrides: Optional[AsyncAuditManagerClientConfig] = None,
) -> GetEvidenceResponse

Gets information about a specified evidence item.

Parameters:

  • assessment_id (UUID) –

    The unique identifier for the assessment.

  • control_set_id (ControlSetId) –

    The unique identifier for the control set.

  • evidence_folder_id (UUID) –

    The unique identifier for the folder that the evidence is stored in.

  • evidence_id (UUID) –

    The unique identifier for the evidence.

Raises:

  • AccessDeniedException –

    Your account isn't registered with Audit Manager. Check the delegated administrator setup on the Audit Manager settings page, and try again.

  • InternalServerException –

    An internal service error occurred during the processing of your request. Try again later.

  • ResourceNotFoundException –

    The resource that's specified in the request can't be found.

  • ValidationException –

    The request has invalid or missing parameters.

  • UnknownServiceError –

    The service returned an error code this client does not model.

Source code in docs_src/capo_auditmanager/_services/async_audit_manager.py
async def get_evidence(
    self,
    assessment_id: "capo_auditmanager.types.uuid.UUID",
    control_set_id: "capo_auditmanager.types.control_set_id.ControlSetId",
    evidence_folder_id: "capo_auditmanager.types.uuid.UUID",
    evidence_id: "capo_auditmanager.types.uuid.UUID",
    *,
    config_overrides: Optional[AsyncAuditManagerClientConfig] = None,
) -> "capo_auditmanager.types.get_evidence_response.GetEvidenceResponse":
    """<p> Gets information about a specified evidence item.</p>

    Args:
        assessment_id: <p> The unique identifier for the assessment. </p>
        control_set_id: <p> The unique identifier for the control set. </p>
        evidence_folder_id: <p> The unique identifier for the folder that the evidence is stored in. </p>
        evidence_id: <p> The unique identifier for the evidence. </p>

    Raises:
        capo_auditmanager.errors.access_denied_exception.AccessDeniedException: <p> Your account isn't registered with Audit Manager. Check the delegated administrator setup on the Audit Manager settings page, and try again. </p>
        capo_auditmanager.errors.internal_server_exception.InternalServerException: <p> An internal service error occurred during the processing of your request. Try again later. </p>
        capo_auditmanager.errors.resource_not_found_exception.ResourceNotFoundException: <p> The resource that's specified in the request can't be found. </p>
        capo_auditmanager.errors.validation_exception.ValidationException: <p> The request has invalid or missing parameters. </p>
        capo_auditmanager.errors.UnknownServiceError: The service returned an error code this client does not model.
    """

    async def _handler(
        req: "AsyncOperationRequest[capo_auditmanager.types.get_evidence_request.GetEvidenceRequest]",
    ) -> AsyncOperationResponse[
        "capo_auditmanager.types.get_evidence_response.GetEvidenceResponse"
    ]:
        import capo_auditmanager._operations.bedrock_assessment_manager_lambda.get_evidence

        (
            output,
            http_response,
        ) = await capo_auditmanager._operations.bedrock_assessment_manager_lambda.get_evidence.async_get_evidence(
            req.options, req.input
        )
        return AsyncOperationResponse(output=output, response=http_response)

    interceptors_, options_ = self.operation_options(
        config_overrides, OperationLogging("GetEvidence")
    )
    input_: capo_auditmanager.types.get_evidence_request.GetEvidenceRequest = {
        "assessment_id": assessment_id,
        "control_set_id": control_set_id,
        "evidence_folder_id": evidence_folder_id,
        "evidence_id": evidence_id,
    }

    response = await aexecute_pipeline(
        AsyncOperationRequest(input=input_, options=options_),
        handler=_handler,
        interceptors=list(interceptors_),
    )
    await response.response.aclose()
    return response.output