Helper/Hook.php
public function verifyWebhook()
    {
        $payload     = $this->request->getContent();
        $hmac_header = $this->request->getHeader(self::HMAC_HEADER);

        if (!$this->verifyWebhookSecret($payload, $hmac_header) && !$this->verifyWebhookApi($payload, $hmac_header)) {
            throw new WebapiException(__('Precondition Failed'), 6001, 412);
        }
    }
public function verifyWebhook()
    {
        $payload     = $this->request->getContent();
        $hmac_header = $this->request->getHeader(self::HMAC_HEADER);

        if (!$this->verifyWebhookSecret($payload, $hmac_header) && !$this->verifyWebhookApi($payload, $hmac_header)) {
            throw new WebapiException(__('Precondition Failed'), 6001, 412);
        }
    }
public function verifyWebhook ( ) { $ payload = $ this -> request -> getContent ( ) ; $ hmac_header = $ this -> request -> getHeader ( self :: HMAC_HEADER ) ; if ( ! $ this -> verifyWebhookSecret ( $ payload , $ hmac_header ) && ! $ this -> verifyWebhookApi ( $ payload , $ hmac_header ) ) { throw new WebapiException ( __ ( 'Precondition Failed' ) , 6001 , 412 ) ; } }
Verifying Hook Request. If signing secret is not defined or fails fallback to api call.

@throws WebapiException
@throws \Magento\Framework\Exception\LocalizedException
Verifying Hook Request . If signing secret is not defined or fails fallback to api call .