Retrieve Data from Custom Endpoint

As you said “Coupon is created in WooCommerce end”, we can confirm that custom endpoint “webhook” is working finely.

The issue is regrading to retrieve Email Address from the response. The moosend schema body is consist of JSON Object. So you have to decode the response to array first.

Try to change your code as following code. It will convert JSON Objects into PHP Array and then retrieve Email Address from the Array

$requestArr = json_decode($request, true);
$email = $requestArr["properties"]["Event"]["ContactContext"]["properties"]["EmailAddress"];