skip to Main Content

Php – Codeignitor League OAuth2: Message: invalid_client – xero

I'm trying to intergrate with Xero via their API SDK (https://github.com/XeroAPI/xero-php-oauth2) I have installed via composer and am using Codignitor 3 for the framework. I keep getting this error: An uncaught Exception was encountered Type: LeagueOAuth2ClientProviderExceptionIdentityProviderException Message: invalid_client Filename: /var/www/vhosts/xxxx.co.uk/vendor/league/oauth2-client/src/Provider/GenericProvider.php…

VIEW QUESTION

How to Validate a Xero webhook payload with HMACSHA256 in PHP Laravel

I need to validate Xero webhook in PHP. Here's My Code $payload = file_get_contents("php://input"); $webhookKey = '-----Webhook Key-----'; $computedSignatureKey = base64_encode(hash_hmac('sha256', $payload, $webhookKey, true)); if ($computedSignatureKey === $_SERVER['HTTP_X_XERO_SIGNATURE']) { return response(200); } return response(401); suppose the xero signature is =…

VIEW QUESTION
Back To Top
Search