Is there a way to trigger a HTTP post when a contact clicks on an email button?


#1

Hi, I’m relatively new to hubspot. The developer that used to work on the hubspot integration at my company no longer works here, and myself and 1 other developer are trying to figure this stuff out. The owner here wants to know in real time when a contact clicks on a button in an email. Is there a way to add a http post to an email button click? We have forms that send us information this way when a contact clicks an email button which takes them to a form to fill out, but in some cases we want to cut out the middle man.


#2

Hi @st93ct9u,

While it might be possible to make a POST request from an email by including some sort of <form> element, it’s not generally recommended (see this Stack Overflow post). Email clicks are already tracked in HubSpot (see below).


#3

I appreciate the response, but I’m not trying to track clicks. I’m trying to get a real time notification of someone clicking a button in an email, and respond accordingly. Is there a way to do that using the hubspot framework? In the workflows there are triggers/web hooks. I want to do that in an email. Is this possible?


#4

Hi @st93ct9u,

If the notification must be instant, then using HubSpot’s existing tracking probably isn’t ideal. Email stats (i.e. clicks) are updated within 5 minutes of interaction, so creating a workflow that enrolls contacts that click a certain link in an email could be a good solution here.


#5

That’s exactly what we want to do. But I do not know how to create a workflow for an email click which was basically the original question.


#6

Hi @st93ct9u,

You can create a workflow that enrolls contacts that click a certain link like this: