I have setup webhook for my sandbox account of authorize.net. I am getting the webhook when any event happens. but I can't find anything in $_POST or $_GET or $_REQUEST
I have tried to read PHP input stream
$webhook = fopen('php://input' , 'rb');
while (!feof($webhook)) {
$webhookContent .= fread($webhook, 4096);
}
fclose($webhook);
But still, I could not get payload variables. Please help me identifying How authorize.Net sends payload variable!
Get the header parameters :
$headers = getallheaders();
Get the payload :
$payload = file_get_contents("php://input");
Encode payload - $
response= json_encode($payload);
Encode header parameters :
$headersresponse = json_encode($headers);
Payload will contains the parameters like responseCode,authCode,authAmount,entityName,notificationId