public function performAmlCheck(AmlProfile $amlProfile)
    {
        // Get payload data from amlProfile
        $amlPayload     = new Payload($amlProfile->getData());

        $result = $this->sendRequest(
            self::AML_CHECK_ENDPOINT,
            CurlRequestHandler::METHOD_POST,
            $amlPayload
        );

        // Get response data array
        $responseArr = json_decode($result['response'], true);
        // Check if there is a JSON decode error
        $this->checkJsonError();

        // Validate result
        $this->validateResult($responseArr, $result['http_code']);

        // Set and return result
        return new AmlResult($responseArr);
    }
public function performAmlCheck(AmlProfile $amlProfile)
    {
        // Get payload data from amlProfile
        $amlPayload     = new Payload($amlProfile->getData());

        $result = $this->sendRequest(
            self::AML_CHECK_ENDPOINT,
            CurlRequestHandler::METHOD_POST,
            $amlPayload
        );

        // Get response data array
        $responseArr = json_decode($result['response'], true);
        // Check if there is a JSON decode error
        $this->checkJsonError();

        // Validate result
        $this->validateResult($responseArr, $result['http_code']);

        // Set and return result
        return new AmlResult($responseArr);
    }
public function performAmlCheck ( AmlProfile $ amlProfile ) { // Get payload data from amlProfile $ amlPayload = new Payload ( $ amlProfile -> getData ( ) ) ; $ result = $ this -> sendRequest ( self :: AML_CHECK_ENDPOINT , CurlRequestHandler :: METHOD_POST , $ amlPayload ) ; // Get response data array $ responseArr = json_decode ( $ result [ 'response' ] , true ) ; // Check if there is a JSON decode error $ this -> checkJsonError ( ) ; // Validate result $ this -> validateResult ( $ responseArr , $ result [ 'http_code' ] ) ; // Set and return result return new AmlResult ( $ responseArr ) ; }
Perform AML profile check.

@param AmlProfile $amlProfile

@return AmlResult

@throws AmlException
@throws RequestException
Perform AML profile check .