APIs & Integrations

viral33
Member

Call API on click of CTA button

SOLVE

I create one email template. In that email template i place one CTA button. now i send email to my contacts. once any contact click on CTA button from email I want to update that contact detail.so i think for update of detail from click of CTA button in mail i need to call API. Can you please help me to call API on that CTA button ?

How can i make it possible ?

0 Upvotes
1 Accepted solution
IsaacTakushi
Solution
HubSpot Employee
HubSpot Employee

Call API on click of CTA button

SOLVE

Thanks for clarifying your goal, @viral33.

That said, it is not possible to set up this kind of logic with internal HubSpot emails. There are two main issues:

  1. API calls cannot be triggered by a user clicking a CTA in an internal email.
  2. When users open and click links in internal emails, they act as contacts, so it's not possible to check the values of a different contact.

Unfortunately, the default HubSpot tools do not support the use case you described.

The closest thing I can think of is to use workflow logic to sort and rotate contacts to different owners. See the Rotate objects to multiple owners section of this article.

Isaac Takushi

Associate Certification Manager

View solution in original post

0 Upvotes
3 Replies 3
IsaacTakushi
Solution
HubSpot Employee
HubSpot Employee

Call API on click of CTA button

SOLVE

Thanks for clarifying your goal, @viral33.

That said, it is not possible to set up this kind of logic with internal HubSpot emails. There are two main issues:

  1. API calls cannot be triggered by a user clicking a CTA in an internal email.
  2. When users open and click links in internal emails, they act as contacts, so it's not possible to check the values of a different contact.

Unfortunately, the default HubSpot tools do not support the use case you described.

The closest thing I can think of is to use workflow logic to sort and rotate contacts to different owners. See the Rotate objects to multiple owners section of this article.

Isaac Takushi

Associate Certification Manager
0 Upvotes
IsaacTakushi
HubSpot Employee
HubSpot Employee

Call API on click of CTA button

SOLVE

Welcome, @viral33.

What kind of information do you wish to update on the contact?

It is not possible to make an API request directly from a CTA click, so I will need to learn more about your goal to advise on workarounds.

Isaac Takushi

Associate Certification Manager
0 Upvotes
viral33
Member

Call API on click of CTA button

SOLVE

The objective is to assign a job to an available internal user based on who clicks the “accept CTA” first in the internal email sent.

  1. I send an internal email to all internal users with contact Y details.
  2. If internal user X clicks on the CTA in the email then we need to check if contact Y property A is == Q or W.
  3. If A == Q or W then we send an internal mail to X saying job already assigned
  4. Else set contact Y property A to Q and contact Y property B to X (the internal users email address)
  5. Send internal email to X with full job details for Y
0 Upvotes