Reply
Highlighted
Member
Posts: 1
Registered: ‎06-24-2018

Webhook Authorization error

[ Edited ]

I have been trying to get webhooks to work to get additional information (billing address and custom fields) about transactions.

 

I am using the code given below to test authentication.  I have verified that login and key values are present, but keep getting the message "{ "message": "Authorization has been denied for this request." }";  I have regenerated via the key via sandbox->settings->webhooks just to make sure that was not the issue.  I am able to succefully get a token and complete payment using the same login and key.  Are there other settings in the admin interface which must updated?  So far I have just created the key and the signature values.

 

<pre><code>
$login_transKey = AUTHNET_LOGIN . ':' . AUTHNET_TRANSKEY; //Login and Transaction Key of Authorize.net
$url = "https://apitest.authorize.net/rest/v1/eventtypes";

$ch = curl_init();
curl_setopt($ch, CURLOPT_URL, $url);
curl_setopt($ch, CURLOPT_HTTPHEADER, array('Content-Type: application/json'));
curl_setopt($ch, CURLOPT_HTTPAUTH, CURLAUTH_BASIC);
curl_setopt($ch, CURLOPT_USERPWD, $login_transkey);
$content = curl_exec($ch);
echo '<pre>'; print_r($content); die();
curl_close($ch);

</code></pre>

Member
Posts: 1
Registered: ‎02-08-2019

Re: Webhook Authorization error


@kumar111 wrote:

I have been trying to get webhooks to work to get additional information (billing address and custom fields) about transactions.

 

I am using the code given below to test authentication.  I have verified that login and key values are present, but keep getting the message "{ "message": "Authorization has been denied for this request." }";  I have regenerated via the key via sandbox->settings->webhooks just to make sure that was not the issue.  I am able to succefully get a token and complete payment using the same login and key.  Are there other settings in the admin interface which must updated?  So far I have just created the key and the signature values in the website.

 

<pre><code>
$login_transKey = AUTHNET_LOGIN . ':' . AUTHNET_TRANSKEY; //Login and Transaction Key of Authorize.net
$url = "https://apitest.authorize.net/rest/v1/eventtypes";

$ch = curl_init();
curl_setopt($ch, CURLOPT_URL, $url);
curl_setopt($ch, CURLOPT_HTTPHEADER, array('Content-Type: application/json'));
curl_setopt($ch, CURLOPT_HTTPAUTH, CURLAUTH_BASIC);
curl_setopt($ch, CURLOPT_USERPWD, $login_transkey);
$content = curl_exec($ch);
echo '<pre>'; print_r($content); die();
curl_close($ch);

</code></pre>


The Auth0 Authentication API Webhooks Extension is a scheduled job that allows you to use your own custom webhooks in conjunction with the Auth0 Authentication API.

Member
Posts: 1
Registered: ‎04-09-2019

Re: Webhook Authorization error

Mandrill signs webhook requests so you can (optionally) verify that requests are generated by Mandrill and not a third-party pretending to be Mandrill. If your application exposes sensitive data, you may want to be sure the requests are coming from Mandrill UPSers.