I’m having problems with endless multiple duplicates when I set up a webhook subscription in the developer app.
I am getting endless duplicates of execution of my code in my webhook endpoint, even though it has successfully completed the task eg. create contact or create invoice.
Here’s my setup:
In the configuration I’ve set it for HubSpot to be allowed to send 5 concurrent requests (minimum of 5).
In my webhook subscription
Event: Property change: dealstage
My code checks to see if the dealstage is closedwon and then executes my code eg to create a contact in the receiving application.
HubSpot executes the code the first time successfully however the webhook log is showing a Status Failture and Request time out response. The first line of my code is sending back an http 200 ok response (I’ve tried both http_response_code(200); and header(“HTTP/1.1 200 OK”); in php). But HubSpot doesn’t seem to be recognising these response codes.
HubSpot continues it seems indefinitely to send the json data to the webhook enpoint which is creating endless duplicates in the receiving applications.
The only way for me to stop it seems to be to pause the subscription and then start it again.
Is there a ‘correct’ way to let HubSpot know that I have successfully executed the code? What am I doing wrong?